From 37ced39ae2ecfc945c21526faffb2449577bbeb7 Mon Sep 17 00:00:00 2001 From: tmk Date: Fri, 26 Nov 2010 01:56:21 +0900 Subject: add build option USB_12KRO. --- usb_keyboard.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'usb_keyboard.c') diff --git a/usb_keyboard.c b/usb_keyboard.c index 7f32a9083e..3e13ae4e36 100644 --- a/usb_keyboard.c +++ b/usb_keyboard.c @@ -64,6 +64,7 @@ int8_t usb_keyboard_send_report(usb_keyboard_report_t *report) UEINTX = 0x3A; SREG = intr_state; +#ifdef USB_12KRO if (!usb_configured()) return -1; intr_state = SREG; cli(); @@ -82,17 +83,18 @@ int8_t usb_keyboard_send_report(usb_keyboard_report_t *report) cli(); UENUM = KEYBOARD_ENDPOINT2; } - UEDATX = 0; + UEDATX = report->mods; UEDATX = 0; for (i = 6; i < 12; i++) { UEDATX = report->keys[i]; } UEINTX = 0x3A; SREG = intr_state; +#endif usb_keyboard_idle_count = 0; - report->is_sent =true; - usb_keyboard_print_report(report); + report->is_sent =true; + usb_keyboard_print_report(report); return 0; } -- cgit v1.2.3