diff options
author | IBNobody <ibnobody@gmail.com> | 2016-06-11 13:28:27 -0500 |
---|---|---|
committer | IBNobody <ibnobody@gmail.com> | 2016-06-11 13:28:27 -0500 |
commit | 50621a2e6a7d03add0c202e5b2698338c7fbbf5b (patch) | |
tree | d6f002712c22e8cf4523e04a9da889c7ec379d6b /keyboard/infinity/main.cpp | |
parent | 26277dbdf40ba7247981361c956ea44c92bf76ea (diff) | |
parent | d9e4dad0a828a8a904f44dda090a4d6d08fe2948 (diff) |
Merge remote-tracking branch 'remotes/jackhumbert/master'
Diffstat (limited to 'keyboard/infinity/main.cpp')
-rw-r--r-- | keyboard/infinity/main.cpp | 44 |
1 files changed, 0 insertions, 44 deletions
diff --git a/keyboard/infinity/main.cpp b/keyboard/infinity/main.cpp deleted file mode 100644 index 847668a1de..0000000000 --- a/keyboard/infinity/main.cpp +++ /dev/null @@ -1,44 +0,0 @@ -#include "MK20D5.h" -#include "wait.h" -#include "gpio_api.h" -#include "PinNames.h" -#include "matrix.h" -#include "timer.h" - -#include "action.h" -#include "keycode.h" -#include "host.h" -#include "host_driver.h" -#include "mbed_driver.h" - - -int main() { - gpio_t led; - gpio_init_out(&led, PTA19); - - uint16_t t = 0; - - host_set_driver(&mbed_driver); - keyboard_init(); - - while(1) { - keyboard_task(); - - bool matrix_on = false; - matrix_scan(); - for (int i = 0; i < MATRIX_ROWS; i++) { - if (matrix_get_row(i)) { - matrix_on = true; - break; - } - } - if (matrix_on) - gpio_write(&led, 1); - else { - if (timer_elapsed(t) > 500) { - gpio_write(&led, !gpio_read(&led)); - t = timer_read(); - } - } - } -} |