Minor documentation improvements. Remove AS4 project generator script as it is buggy...
[pub/USBasp.git] / Demos / Host / ClassDriver / MouseHostWithParser / MouseHostWithParser.c
index 46105f3..9426aec 100644 (file)
@@ -1,13 +1,13 @@
 /*
              LUFA Library
 /*
              LUFA Library
-     Copyright (C) Dean Camera, 2011.
+     Copyright (C) Dean Camera, 2012.
 
   dean [at] fourwalledcubicle [dot] com
            www.lufa-lib.org
 */
 
 /*
 
   dean [at] fourwalledcubicle [dot] com
            www.lufa-lib.org
 */
 
 /*
-  Copyright 2011  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
 
   Permission to use, copy, modify, distribute, and sell this
   software and its documentation for any purpose is hereby granted
 
   Permission to use, copy, modify, distribute, and sell this
   software and its documentation for any purpose is hereby granted
@@ -47,14 +47,17 @@ USB_ClassInfo_HID_Host_t Mouse_HID_Interface =
        {
                .Config =
                        {
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
-
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                                .HIDInterfaceProtocol   = HID_CSCP_NonBootProtocol,
                                .HIDInterfaceProtocol   = HID_CSCP_NonBootProtocol,
-
                                .HIDParserData          = &HIDReportInfo
                        },
        };
                                .HIDParserData          = &HIDReportInfo
                        },
        };
@@ -68,9 +71,9 @@ int main(void)
        SetupHardware();
 
        puts_P(PSTR(ESC_FG_CYAN "Mouse Host Demo running.\r\n" ESC_FG_WHITE));
        SetupHardware();
 
        puts_P(PSTR(ESC_FG_CYAN "Mouse Host Demo running.\r\n" ESC_FG_WHITE));
-       sei();
 
        LEDs_SetAllLEDs(LEDMASK_USB_NOTREADY);
 
        LEDs_SetAllLEDs(LEDMASK_USB_NOTREADY);
+       GlobalInterruptEnable();
 
        for (;;)
        {
 
        for (;;)
        {