diff options
Diffstat (limited to 'LUFA/Drivers/USB/Core/XMEGA/Template/Template_Endpoint_Control_W.c')
-rw-r--r-- | LUFA/Drivers/USB/Core/XMEGA/Template/Template_Endpoint_Control_W.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/LUFA/Drivers/USB/Core/XMEGA/Template/Template_Endpoint_Control_W.c b/LUFA/Drivers/USB/Core/XMEGA/Template/Template_Endpoint_Control_W.c index 36685f0c4..e5180693d 100644 --- a/LUFA/Drivers/USB/Core/XMEGA/Template/Template_Endpoint_Control_W.c +++ b/LUFA/Drivers/USB/Core/XMEGA/Template/Template_Endpoint_Control_W.c @@ -36,6 +36,8 @@ uint8_t TEMPLATE_FUNC_NAME (const void* const Buffer, uint8_t* DataStream = ((uint8_t*)Buffer + TEMPLATE_BUFFER_OFFSET(Length)); bool LastPacketFull = false; + Endpoint_SelectEndpoint(USB_Endpoint_SelectedEndpoint | ENDPOINT_DIR_IN); + if (Length > USB_ControlRequest.wLength) Length = USB_ControlRequest.wLength; else if (!(Length)) |