Added better module summaries.
[pub/USBasp.git] / Demos / Host / LowLevel / GenericHIDHost / GenericHIDHost.c
index 5bb89af..a1b62ac 100644 (file)
@@ -164,10 +164,10 @@ void ReadNextReport(void)
 \r
 /** Writes a report to the attached device.\r
  *\r
 \r
 /** Writes a report to the attached device.\r
  *\r
- *  \param ReportOUTData  Buffer containing the report to send to the device\r
- *  \param ReportIndex  Index of the report in the device (zero if the device does not use multiple reports)\r
- *  \param ReportType  Type of report to send, either HID_REPORTTYPE_OUTPUT or HID_REPORTTYPE_FEATURE\r
- *  \param ReportLength  Length of the report to send\r
+ *  \param[in] ReportOUTData  Buffer containing the report to send to the device\r
+ *  \param[in] ReportIndex  Index of the report in the device (zero if the device does not use multiple reports)\r
+ *  \param[in] ReportType  Type of report to send, either HID_REPORTTYPE_OUTPUT or HID_REPORTTYPE_FEATURE\r
+ *  \param[in] ReportLength  Length of the report to send\r
  */\r
 void WriteNextReport(uint8_t* ReportOUTData, uint8_t ReportIndex, uint8_t ReportType, uint16_t ReportLength)\r
 {\r
  */\r
 void WriteNextReport(uint8_t* ReportOUTData, uint8_t ReportIndex, uint8_t ReportType, uint16_t ReportLength)\r
 {\r
@@ -249,7 +249,7 @@ void HID_Host_Task(void)
                                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);\r
 \r
                                /* Wait until USB device disconnected */\r
                                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);\r
 \r
                                /* Wait until USB device disconnected */\r
-                               while (USB_IsConnected);\r
+                               USB_HostState = HOST_STATE_WaitForDeviceRemoval;\r
                                break;\r
                        }\r
 \r
                                break;\r
                        }\r
 \r
@@ -263,7 +263,7 @@ void HID_Host_Task(void)
                                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);\r
                                \r
                                /* Wait until USB device disconnected */\r
                                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);\r
                                \r
                                /* Wait until USB device disconnected */\r
-                               while (USB_IsConnected);\r
+                               USB_HostState = HOST_STATE_WaitForDeviceRemoval;\r
                                break;\r
                        }\r
                        \r
                                break;\r
                        }\r
                        \r