summaryrefslogtreecommitdiff
path: root/ports/esp32/main.c
diff options
context:
space:
mode:
authorAndrew Leech <andrew.leech@planetinnovation.com.au>2024-05-23 17:23:41 +1000
committerDamien George <damien@micropython.org>2024-10-07 11:06:29 +1100
commit4247921c4ebfced79aa7ccfbb835c9f60ad6f0fc (patch)
tree96c6286dde050cdb7690c6bbb46fbcfb7e4c714d /ports/esp32/main.c
parentca6723b144501d3ea96a5a79bb18f0947a63fc87 (diff)
esp32: Use shared/tinyusb integration for S2 and S3 USB.
Uses newer TinyUSB synopsys/dwc2 driver for esp32s2 and esp32s3 rather than the IDF tinyusb component. This allows re-use of other tinyusb integration code and features shared between ports. Signed-off-by: Andrew Leech <andrew@alelec.net>
Diffstat (limited to 'ports/esp32/main.c')
-rw-r--r--ports/esp32/main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ports/esp32/main.c b/ports/esp32/main.c
index ca5a0e3c2..03dc0807a 100644
--- a/ports/esp32/main.c
+++ b/ports/esp32/main.c
@@ -52,6 +52,7 @@
#include "shared/readline/readline.h"
#include "shared/runtime/pyexec.h"
#include "shared/timeutils/timeutils.h"
+#include "shared/tinyusb/mp_usbd.h"
#include "mbedtls/platform_time.h"
#include "uart.h"
@@ -101,7 +102,7 @@ void mp_task(void *pvParameter) {
#endif
#if MICROPY_HW_ESP_USB_SERIAL_JTAG
usb_serial_jtag_init();
- #elif MICROPY_HW_USB_CDC
+ #elif MICROPY_HW_ENABLE_USBDEV
usb_init();
#endif
#if MICROPY_HW_ENABLE_UART_REPL