aboutsummaryrefslogtreecommitdiffstats
path: root/Demos/Host/ClassDriver/MouseHost/MouseHost.c
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2009-09-17 13:12:21 +0000
committerDean Camera <dean@fourwalledcubicle.com>2009-09-17 13:12:21 +0000
commit7c6b2019a302fb064665c1a69e559678c299e9bb (patch)
treef9348ddac5fe0b45fa687df5941d391e91715326 /Demos/Host/ClassDriver/MouseHost/MouseHost.c
parenteaa914a4e445c25ffdbee7be7caf85165540c98a (diff)
downloadlufa-7c6b2019a302fb064665c1a69e559678c299e9bb.tar.gz
lufa-7c6b2019a302fb064665c1a69e559678c299e9bb.tar.bz2
lufa-7c6b2019a302fb064665c1a69e559678c299e9bb.zip
Fix Mass Storage Host Class driver GetMaxLUN command - incorrect function return codes used in comparison to check for success.
Add HID Host Class driver functions to set the report protocol, add more class driver documentation.
Diffstat (limited to 'Demos/Host/ClassDriver/MouseHost/MouseHost.c')
-rw-r--r--Demos/Host/ClassDriver/MouseHost/MouseHost.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/Demos/Host/ClassDriver/MouseHost/MouseHost.c b/Demos/Host/ClassDriver/MouseHost/MouseHost.c
index 844fa334c..5b9b4431e 100644
--- a/Demos/Host/ClassDriver/MouseHost/MouseHost.c
+++ b/Demos/Host/ClassDriver/MouseHost/MouseHost.c
@@ -98,6 +98,14 @@ int main(void)
USB_HostState = HOST_STATE_WaitForDeviceRemoval;
break;
}
+
+ if (USB_HID_Host_SetBootProtocol(&Mouse_HID_Interface) != 0)
+ {
+ printf("Could not Set Boot Protocol Mode.\r\n");
+ LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
+ USB_HostState = HOST_STATE_WaitForDeviceRemoval;
+ break;
+ }
printf("Mouse Enumerated.\r\n");
USB_HostState = HOST_STATE_Configured;