diff options
| author | tmk <hasu@tmk-kbd.com> | 2015-01-03 12:02:48 +0900 |
|---|---|---|
| committer | tmk <hasu@tmk-kbd.com> | 2015-01-03 12:09:41 +0900 |
| commit | 06527bde4f873ffc6eb8e359fb3b150e880b89ba (patch) | |
| tree | 347b6886dc485091ff5ffcf211ab87b3c9ceda43 /protocol/pjrc | |
| parent | 22d99f26af757c0bedb31ba3f63d793e4b2d4ca3 (diff) | |
| download | qmk_firmware-06527bde4f873ffc6eb8e359fb3b150e880b89ba.tar.gz qmk_firmware-06527bde4f873ffc6eb8e359fb3b150e880b89ba.zip | |
bluefruit, pjrc: Update protocols for new API
Diffstat (limited to 'protocol/pjrc')
| -rw-r--r-- | protocol/pjrc/main.c | 3 | ||||
| -rw-r--r-- | protocol/pjrc/usb_keyboard.c | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/protocol/pjrc/main.c b/protocol/pjrc/main.c index 1ef87f865..4f87a1736 100644 --- a/protocol/pjrc/main.c +++ b/protocol/pjrc/main.c | |||
| @@ -24,6 +24,7 @@ | |||
| 24 | #include <stdbool.h> | 24 | #include <stdbool.h> |
| 25 | #include <avr/io.h> | 25 | #include <avr/io.h> |
| 26 | #include <avr/interrupt.h> | 26 | #include <avr/interrupt.h> |
| 27 | #include <avr/wdt.h> | ||
| 27 | #include <util/delay.h> | 28 | #include <util/delay.h> |
| 28 | #include "keyboard.h" | 29 | #include "keyboard.h" |
| 29 | #include "usb.h" | 30 | #include "usb.h" |
| @@ -60,7 +61,7 @@ int main(void) | |||
| 60 | #endif | 61 | #endif |
| 61 | while (1) { | 62 | while (1) { |
| 62 | while (suspend) { | 63 | while (suspend) { |
| 63 | suspend_power_down(); | 64 | suspend_power_down(WDTO_120MS); |
| 64 | if (remote_wakeup && suspend_wakeup_condition()) { | 65 | if (remote_wakeup && suspend_wakeup_condition()) { |
| 65 | usb_remote_wakeup(); | 66 | usb_remote_wakeup(); |
| 66 | } | 67 | } |
diff --git a/protocol/pjrc/usb_keyboard.c b/protocol/pjrc/usb_keyboard.c index 758a4edc6..4b87b5d7b 100644 --- a/protocol/pjrc/usb_keyboard.c +++ b/protocol/pjrc/usb_keyboard.c | |||
| @@ -74,7 +74,7 @@ void usb_keyboard_print_report(report_keyboard_t *report) | |||
| 74 | { | 74 | { |
| 75 | if (!debug_keyboard) return; | 75 | if (!debug_keyboard) return; |
| 76 | print("keys: "); | 76 | print("keys: "); |
| 77 | for (int i = 0; i < REPORT_KEYS; i++) { phex(report->keys[i]); print(" "); } | 77 | for (int i = 0; i < KEYBOARD_REPORT_KEYS; i++) { phex(report->keys[i]); print(" "); } |
| 78 | print(" mods: "); phex(report->mods); print("\n"); | 78 | print(" mods: "); phex(report->mods); print("\n"); |
| 79 | } | 79 | } |
| 80 | 80 | ||
