diff options
Diffstat (limited to 'LUFA')
-rw-r--r-- | LUFA/DoxygenPages/ChangeLog.txt | 2 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Device/CDCClassDevice.c | 5 | ||||
-rw-r--r-- | LUFA/Drivers/USB/Class/Device/MIDIClassDevice.c | 5 |
3 files changed, 10 insertions, 2 deletions
diff --git a/LUFA/DoxygenPages/ChangeLog.txt b/LUFA/DoxygenPages/ChangeLog.txt index 271c23d10..e92f026cf 100644 --- a/LUFA/DoxygenPages/ChangeLog.txt +++ b/LUFA/DoxygenPages/ChangeLog.txt @@ -34,6 +34,8 @@ * - Library Applications: * - Fixed broken RESET_TOGGLES_LIBUSB_COMPAT compile time option in the AVRISP-MKII project * - Fixed incompatibility in the CDC class bootloader on some systems (thanks to Sylvain Munaut) + * - Fixed lengthy timeouts in the USBtoSerial project if no application on the host is consuming data (thanks to Nicolas Saugnier) + * - Fixed lengthy automatic data flushing in the CDC and MIDI device class drivers * * \section Sec_ChangeLog120730 Version 120730 * <b>New:</b> diff --git a/LUFA/Drivers/USB/Class/Device/CDCClassDevice.c b/LUFA/Drivers/USB/Class/Device/CDCClassDevice.c index ff0f9bb55..61f4be9d7 100644 --- a/LUFA/Drivers/USB/Class/Device/CDCClassDevice.c +++ b/LUFA/Drivers/USB/Class/Device/CDCClassDevice.c @@ -138,7 +138,10 @@ void CDC_Device_USBTask(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo) return; #if !defined(NO_CLASS_DRIVER_AUTOFLUSH) - CDC_Device_Flush(CDCInterfaceInfo); + Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpoint.Address); + + if (Endpoint_IsINReady()) + CDC_Device_Flush(CDCInterfaceInfo); #endif } diff --git a/LUFA/Drivers/USB/Class/Device/MIDIClassDevice.c b/LUFA/Drivers/USB/Class/Device/MIDIClassDevice.c index c9553a413..5defa142a 100644 --- a/LUFA/Drivers/USB/Class/Device/MIDIClassDevice.c +++ b/LUFA/Drivers/USB/Class/Device/MIDIClassDevice.c @@ -59,7 +59,10 @@ void MIDI_Device_USBTask(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo) return; #if !defined(NO_CLASS_DRIVER_AUTOFLUSH) - MIDI_Device_Flush(MIDIInterfaceInfo); + Endpoint_SelectEndpoint(MIDIInterfaceInfo->Config.DataINEndpoint.Address); + + if (Endpoint_IsINReady()) + MIDI_Device_Flush(MIDIInterfaceInfo); #endif } |