]> git.donarmstrong.com Git - kiibohd-controller.git/commitdiff
USB Macro Output sequences now working!
authorJacob Alexander <haata@kiibohd.com>
Mon, 27 Oct 2014 07:26:17 +0000 (00:26 -0700)
committerJacob Alexander <haata@kiibohd.com>
Mon, 27 Oct 2014 07:26:17 +0000 (00:26 -0700)
- Tested both with Boot and NKRO modes

Output/pjrcUSB/output_com.c
Output/pjrcUSB/output_com.h

index 21e2f0b8d481a49e1b6f50274ca01ace88de4e0f..a0ce24d65d9aade54af9ae264b20122971d2871f 100644 (file)
@@ -401,6 +401,17 @@ void Output_usbCodeSend_capability( uint8_t state, uint8_t stateType, uint8_t *a
 
                        USBKeys_Changed |= USBKeyChangeState_TertiaryKeys;
                }
+               // Received 0x00
+               // This is a special USB Code that internally indicates a "break"
+               // It is used to send "nothing" in order to break up sequences of USB Codes
+               else if ( key == 0x00 )
+               {
+                       USBKeys_Changed |= USBKeyChangeState_All;
+
+                       // Also flush out buffers just in case
+                       Output_flushBuffers();
+                       break;
+               }
                // Invalid key
                else
                {
index a1658f73e2d6786565e3af3b3868a13bd874d68a..1daaf027ae75ee2c5af4d5c647019dab08b61d27 100644 (file)
@@ -53,6 +53,7 @@ typedef enum USBKeyChangeState {
        USBKeyChangeState_TertiaryKeys  = 0x08,
        USBKeyChangeState_System        = 0x10,
        USBKeyChangeState_Consumer      = 0x20,
+       USBKeyChangeState_All           = 0x3F,
 } USBKeyChangeState;