Fix broken Set Feature/Clear Feature chapter 9 request (incorrect status stage clearing).
authorDean Camera <dean@fourwalledcubicle.com>
Sun, 10 May 2009 05:23:35 +0000 (05:23 +0000)
committerDean Camera <dean@fourwalledcubicle.com>
Sun, 10 May 2009 05:23:35 +0000 (05:23 +0000)
Commit for the 090510 release.

Demos/Device/CDC/Descriptors.c
LUFA/Drivers/USB/LowLevel/DevChapter9.c

index 70c885f..c147546 100644 (file)
@@ -51,7 +51,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor =
        .SubClass               = 0x00,\r
        .Protocol               = 0x00,\r
                                \r
-       .Endpoint0Size          = 8,//FIXED_CONTROL_ENDPOINT_SIZE,\r
+       .Endpoint0Size          = FIXED_CONTROL_ENDPOINT_SIZE,\r
                \r
        .VendorID               = 0x03EB,\r
        .ProductID              = 0x2044,\r
index f02bb56..6ecadb0 100644 (file)
@@ -118,8 +118,6 @@ static void USB_Device_SetAddress(void)
 {\r
        Endpoint_ClearSETUP();\r
        \r
-       while (!(Endpoint_IsINReady()));\r
-       \r
        Endpoint_ClearIN();\r
        \r
        while (!(Endpoint_IsINReady()));\r
@@ -299,7 +297,7 @@ static void USB_Device_ClearSetFeature(void)
                                        }\r
                                        else\r
                                        {\r
-                                               Endpoint_StallTransaction();                                            \r
+                                               Endpoint_StallTransaction();\r
                                        }\r
                                }\r
                        }\r
@@ -313,9 +311,6 @@ static void USB_Device_ClearSetFeature(void)
        Endpoint_ClearSETUP();\r
 \r
        Endpoint_ClearIN();\r
-\r
-       while (!(Endpoint_IsOUTReceived()));\r
-       Endpoint_ClearOUT();\r
 }\r
 \r
 #endif\r