- /* Select the Keyboard Report Endpoint */\r
- Endpoint_SelectEndpoint(KEYBOARD_IN_EPNUM);\r
-\r
- /* Check if Keyboard Endpoint Ready for Read/Write */\r
- if (Endpoint_IsReadWriteAllowed())\r
- {\r
- /* Write Keyboard Report Data */\r
- Endpoint_Write_Stream_LE(&KeyboardReportData, sizeof(KeyboardReportData));\r
-\r
- /* Finalize the stream transfer to send the last packet */\r
- Endpoint_ClearIN();\r
-\r
- /* Clear the report data afterwards */\r
- memset(&KeyboardReportData, 0, sizeof(KeyboardReportData));\r
- }\r
-\r
- /* Select the Keyboard LED Report Endpoint */\r
- Endpoint_SelectEndpoint(KEYBOARD_OUT_EPNUM);\r
-\r
- /* Check if Keyboard LED Endpoint Ready for Read/Write */\r
- if (Endpoint_IsReadWriteAllowed())\r
- { \r
- /* Read in the LED report from the host */\r
- uint8_t LEDStatus = Endpoint_Read_Byte();\r
- uint8_t LEDMask = LEDS_LED2;\r
- \r
- if (LEDStatus & 0x01) // NUM Lock\r
- LEDMask |= LEDS_LED1;\r
- \r
- if (LEDStatus & 0x02) // CAPS Lock\r
- LEDMask |= LEDS_LED3;\r
+ /* Write Keyboard Report Data */\r
+ Endpoint_Write_Stream_LE(&KeyboardReportData, sizeof(KeyboardReportData));\r
+\r
+ /* Finalize the stream transfer to send the last packet */\r
+ Endpoint_ClearIN();\r
+\r
+ /* Clear the report data afterwards */\r
+ memset(&KeyboardReportData, 0, sizeof(KeyboardReportData));\r
+ }\r
+\r
+ /* Select the Keyboard LED Report Endpoint */\r
+ Endpoint_SelectEndpoint(KEYBOARD_OUT_EPNUM);\r
+\r
+ /* Check if Keyboard LED Endpoint Ready for Read/Write */\r
+ if (Endpoint_IsReadWriteAllowed())\r
+ { \r
+ /* Read in the LED report from the host */\r
+ uint8_t LEDStatus = Endpoint_Read_Byte();\r
+ uint8_t LEDMask = LEDS_LED2;\r
+ \r
+ if (LEDStatus & 0x01) // NUM Lock\r
+ LEDMask |= LEDS_LED1;\r
+ \r
+ if (LEDStatus & 0x02) // CAPS Lock\r
+ LEDMask |= LEDS_LED3;\r