micropython/shared/tinyusb
Damien George 880f7bc040 shared/tinyusb/mp_usbd_cdc: Fix short CDC TX timeouts.
The `mp_event_wait_ms()` function may return earlier than the requested
timeout, and if that happens repeatedly (eg due to lots of USB data and
IRQs) then the loop waiting for CDC TX FIFO space to become available may
exit much earlier than MICROPY_HW_USB_CDC_TX_TIMEOUT, even when there is
no space.

Fix this by using `mp_hal_ticks_ms()` to compute a more accurate timeout.

The `basics/int_big_mul.py` test fails on RPI_PICO without this fix.

Signed-off-by: Damien George <damien@micropython.org>
2024-06-26 14:50:42 +10:00
..
mp_usbd_cdc.c shared/tinyusb/mp_usbd_cdc: Fix short CDC TX timeouts. 2024-06-26 14:50:42 +10:00
mp_usbd_cdc.h shared/tinyusb: Allow ports to use 1200bps-touch without other CDC code. 2024-06-02 23:27:33 +10:00
mp_usbd_descriptor.c extmod/machine_usb_device: Add support for Python USB devices. 2024-03-15 14:22:11 +11:00
mp_usbd_runtime.c shared/tinyusb/mp_usbd_runtime: Fix pointer comparison in assert. 2024-06-26 13:57:45 +10:00
mp_usbd.c extmod/machine_usb_device: Add support for Python USB devices. 2024-03-15 14:22:11 +11:00
mp_usbd.h extmod/machine_usb_device: Add support for Python USB devices. 2024-03-15 14:22:11 +11:00
tusb_config.h shared/tinyusb: Buffer startup CDC data to send to host on connection. 2024-06-04 17:49:19 +10:00