From e0985b995009d71b80d214a66944e76f4e41aadb Mon Sep 17 00:00:00 2001 From: Dean Camera Date: Mon, 11 May 2009 07:52:13 +0000 Subject: Fixed bug in RNDISEthernet and DualCDC demos not using the correct USB_ControlRequest structure for control request data. Fixed documentation showing incorrect USB mode support on the supported AVRs list. --- Demos/Device/DualCDC/DualCDC.c | 10 +--------- Demos/Device/RNDISEthernet/RNDISEthernet.c | 11 +---------- LUFA/ChangeLog.txt | 5 +++++ LUFA/MainPage.txt | 4 ++-- LUFA/MigrationInformation.txt | 5 ++++- 5 files changed, 13 insertions(+), 22 deletions(-) diff --git a/Demos/Device/DualCDC/DualCDC.c b/Demos/Device/DualCDC/DualCDC.c index 4185a76bd..9750ea23e 100644 --- a/Demos/Device/DualCDC/DualCDC.c +++ b/Demos/Device/DualCDC/DualCDC.c @@ -186,16 +186,8 @@ EVENT_HANDLER(USB_ConfigurationChanged) */ EVENT_HANDLER(USB_UnhandledControlPacket) { - uint8_t* LineCodingData; - - /* Discard the unused wValue parameter */ - Endpoint_Discard_Word(); - - /* wIndex indicates the interface being controlled */ - uint16_t wIndex = Endpoint_Read_Word_LE(); - /* Determine which interface's Line Coding data is being set from the wIndex parameter */ - LineCodingData = (wIndex == 0) ? (uint8_t*)&LineCoding1 : (uint8_t*)&LineCoding2; + uint8_t* LineCodingData = (USB_ControlRequest.wIndex == 0) ? (uint8_t*)&LineCoding1 : (uint8_t*)&LineCoding2; /* Process CDC specific control requests */ switch (USB_ControlRequest.bRequest) diff --git a/Demos/Device/RNDISEthernet/RNDISEthernet.c b/Demos/Device/RNDISEthernet/RNDISEthernet.c index 8338cdd00..96fef3992 100644 --- a/Demos/Device/RNDISEthernet/RNDISEthernet.c +++ b/Demos/Device/RNDISEthernet/RNDISEthernet.c @@ -140,15 +140,6 @@ EVENT_HANDLER(USB_ConfigurationChanged) */ EVENT_HANDLER(USB_UnhandledControlPacket) { - /* Discard the unused wValue parameter */ - Endpoint_Discard_Word(); - - /* Discard the unused wIndex parameter */ - Endpoint_Discard_Word(); - - /* Read in the wLength parameter */ - uint16_t wLength = Endpoint_Read_Word_LE(); - /* Process RNDIS class commands */ switch (USB_ControlRequest.bRequest) { @@ -159,7 +150,7 @@ EVENT_HANDLER(USB_UnhandledControlPacket) Endpoint_ClearSETUP(); /* Read in the RNDIS message into the message buffer */ - Endpoint_Read_Control_Stream_LE(RNDISMessageBuffer, wLength); + Endpoint_Read_Control_Stream_LE(RNDISMessageBuffer, USB_ControlRequest.wLength); /* Finalize the stream transfer to clear the last packet from the host */ Endpoint_ClearIN(); diff --git a/LUFA/ChangeLog.txt b/LUFA/ChangeLog.txt index bca8d9fb9..c71b088e3 100644 --- a/LUFA/ChangeLog.txt +++ b/LUFA/ChangeLog.txt @@ -8,6 +8,11 @@ * * \section Sec_ChangeLogXXXXXX Version XXXXXX * + * - Fixed bug in RNDISEthernet and DualCDC demos not using the correct USB_ControlRequest structure for control request data + * - Fixed documentation showing incorrect USB mode support on the supported AVRs list + * + * \section Sec_ChangeLog090510 Version 090510 + * * - Added new GenericHIDHost demo * - Corrections to the KeyboardHost and MouseHost demos' pipe handling to freeze and unfreeze the data pipes at the point of use * - KeyboardHost, MouseHost and GenericHIDHost demos now save and restore the currently selected pipe inside the pipe ISR diff --git a/LUFA/MainPage.txt b/LUFA/MainPage.txt index 9dc8a18d4..8ee8f95d9 100644 --- a/LUFA/MainPage.txt +++ b/LUFA/MainPage.txt @@ -15,10 +15,10 @@ * microcontrollers, released under the MIT license. * * Currently supported AVR models: - * - AT90USB1286 (USB Host and Device) + * - AT90USB1286 (USB Device Only) * - AT90USB1287 (USB Host and Device) * - AT90USB646 (USB Device Only) - * - AT90USB647 (USB Device Only) + * - AT90USB647 (USB Host and Device) * - AT90USB162 (USB Device Only) * - AT90USB82 (USB Device Only) * - ATMEGA16U4 (USB Device Only) diff --git a/LUFA/MigrationInformation.txt b/LUFA/MigrationInformation.txt index 6439419f3..891c5b273 100644 --- a/LUFA/MigrationInformation.txt +++ b/LUFA/MigrationInformation.txt @@ -10,7 +10,10 @@ * to the next version released. It does not indicate all new additions to the library in each version change, only * areas relevant to making older projects compatible with the API changes of each new release. * - * \section Sec_MigrationXXXXXX Migrating from 090401 to XXXXXX + * \section Sec_MigrationXXXXXX Migrating from 090510 to XXXXXX + * + * + * \section Sec_Migration090510 Migrating from 090401 to 090510 * * All * - The ButtLoadTag.h header has been removed, as it was never used for its intended purpose. Projects should either remove all -- cgit v1.2.3