diff --git a/Demos/Device/RNDISEthernet/RNDISEthernet.c b/Demos/Device/RNDISEthernet/RNDISEthernet.c index 78c77c8eb7..d573a769bc 100644 --- a/Demos/Device/RNDISEthernet/RNDISEthernet.c +++ b/Demos/Device/RNDISEthernet/RNDISEthernet.c @@ -284,7 +284,7 @@ TASK(RNDIS_Task) Endpoint_Read_Stream_LE(&RNDISPacketHeader, sizeof(RNDIS_PACKET_MSG_t)); /* Stall the request if the data is too large */ - if (RNDISPacketHeader.MessageLength > ETHERNET_FRAME_SIZE_MAX) + if (RNDISPacketHeader.DataLength > ETHERNET_FRAME_SIZE_MAX) { Endpoint_StallTransaction(); return; diff --git a/Demos/Host/GenericHIDHost/GenericHIDHost.c b/Demos/Host/GenericHIDHost/GenericHIDHost.c index 778b8f6f84..605fc6f678 100644 --- a/Demos/Host/GenericHIDHost/GenericHIDHost.c +++ b/Demos/Host/GenericHIDHost/GenericHIDHost.c @@ -221,10 +221,10 @@ void ReadNextReport(void) * \param ReportOUTData Buffer containing the report to send to the device * \param ReportLength Length of the report to send */ -void WriteNextReport(uint8_t ReportOUTData, uint16_t ReportLength) +void WriteNextReport(uint8_t* ReportOUTData, uint16_t ReportLength) { /* Select and unfreeze HID data OUT pipe */ - Pipe_SelectPipe(HID_DATA_IN_PIPE); + Pipe_SelectPipe(HID_DATA_OUT_PIPE); /* Not all HID devices have an OUT endpoint (some require OUT reports to be sent over the * control endpoint instead) - check to see if the OUT endpoint has been initialized */ @@ -242,7 +242,7 @@ void WriteNextReport(uint8_t ReportOUTData, uint16_t ReportLength) } /* Read in HID report data */ - Pipe_Write_Stream_LE(&ReportOUTData, ReportLength); + Pipe_Write_Stream_LE(ReportOUTData, ReportLength); /* Clear the OUT endpoint, send last data packet */ Pipe_ClearCurrentBank(); diff --git a/Demos/Host/GenericHIDHost/GenericHIDHost.h b/Demos/Host/GenericHIDHost/GenericHIDHost.h index f3005e596d..d0f3e7ae49 100644 --- a/Demos/Host/GenericHIDHost/GenericHIDHost.h +++ b/Demos/Host/GenericHIDHost/GenericHIDHost.h @@ -88,6 +88,6 @@ /* Function Prototypes: */ void UpdateStatus(uint8_t CurrentStatus); void ReadNextReport(void); - void WriteNextReport(uint8_t ReportOUTData, uint16_t ReportLength); + void WriteNextReport(uint8_t* ReportOUTData, uint16_t ReportLength); #endif diff --git a/LUFA/ChangeLog.txt b/LUFA/ChangeLog.txt index 64182b02d3..e2d699c3e2 100644 --- a/LUFA/ChangeLog.txt +++ b/LUFA/ChangeLog.txt @@ -27,6 +27,8 @@ * - Added support to the CDCHost demo for devices with mutiple CDC interfaces which are not the correct ACM type preceeding the desired * ACM CDC interface * - Fixed GenericHID demo not starting USB and HID management tasks when not using interrupt driven modes (thanks to Carl Kjeldsen) + * - Fixed RNDISEthenet demo checking the incorrect message field for packet size constraints (thanks to Jonathan) + * - Fixed WriteNextReport code in the GenericHIDHost demo using incorrect parameter types and not selecting the correct endpoint * * \section Sec_ChangeLog090401 Version 090401 *