X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=Output%2FpjrcUSB%2Favr%2Fusb_keyboard_serial.c;fp=Output%2FpjrcUSB%2Favr%2Fusb_keyboard_serial.c;h=f96ac0e6cb159f1262a4680e2a81cc0692f12a82;hb=733a9f26b63f14621873ace4049fbe763c8262db;hp=ee34c780aa9fe7ec12db65aa70717ec0f128af46;hpb=d405af04355b0d31c3774e85c80b9b86ef885be1;p=kiibohd-controller.git diff --git a/Output/pjrcUSB/avr/usb_keyboard_serial.c b/Output/pjrcUSB/avr/usb_keyboard_serial.c index ee34c78..f96ac0e 100644 --- a/Output/pjrcUSB/avr/usb_keyboard_serial.c +++ b/Output/pjrcUSB/avr/usb_keyboard_serial.c @@ -24,6 +24,7 @@ // Local Includes #include "usb_keyboard_serial.h" +#include // ----- Variables ----- @@ -54,6 +55,9 @@ void usb_keyboard_toHost() // Modifiers UEDATX = USBKeys_Modifiers; + // LED Report spacer + USBKeys_LEDs = 0; + // Normal Keys for ( i = 0; i < 6; i++) { @@ -111,13 +115,14 @@ int8_t usb_keyboard_send() cli(); // If not using Boot protocol, send NKRO - UENUM = USBKeys_Protocol ? KEYBOARD_NKRO_ENDPOINT : KEYBOARD_ENDPOINT; + UENUM = KEYBOARD_ENDPOINT; + //UENUM = USBKeys_Protocol ? KEYBOARD_NKRO_ENDPOINT : KEYBOARD_ENDPOINT; } while ( !( UEINTX & (1 << RWAL) ) ); // Send normal keyboard interrupt packet(s) - switch ( USBKeys_Protocol ) - { - } + //switch ( USBKeys_Protocol ) + //{ + //} usb_keyboard_toHost(); USBKeys_Idle_Count = 0; @@ -618,6 +623,7 @@ ISR( USB_GEN_vect ) // From hasu's code, this section looks like it could fix the Mac SET_IDLE problem // Send normal keyboard interrupt packet(s) //usb_keyboard_toHost(); + print("IDLE"); } } } @@ -775,7 +781,8 @@ ISR(USB_COM_vect) // XXX TODO Is this even used? If so, when? -Jacob // Send normal keyboard interrupt packet(s) - //usb_keyboard_toHost(); + usb_keyboard_toHost(); + //print("GET REPORT"); usb_send_in(); return; @@ -794,7 +801,6 @@ ISR(USB_COM_vect) usb_send_in(); return; } - USBKeys_Protocol = bRequest; } if ( bmRequestType == 0x21 ) {