diff options
Diffstat (limited to 'LUFA/Drivers/USB/Class/Device')
-rw-r--r-- | LUFA/Drivers/USB/Class/Device/CDC.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/LUFA/Drivers/USB/Class/Device/CDC.c b/LUFA/Drivers/USB/Class/Device/CDC.c index 0d6b37850..47290ceb6 100644 --- a/LUFA/Drivers/USB/Class/Device/CDC.c +++ b/LUFA/Drivers/USB/Class/Device/CDC.c @@ -161,6 +161,9 @@ uint16_t CDC_Device_BytesReceived(USB_ClassInfo_CDC_Device_t* const CDCInterface {
Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataOUTEndpointNumber);
+ if (Endpoint_IsOUTReceived() && !(Endpoint_BytesInEndpoint()))
+ Endpoint_ClearOUT();
+
return Endpoint_BytesInEndpoint();
}
|