diff options
| author | Damien George <damien@micropython.org> | 2022-04-13 16:00:22 +1000 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2022-04-14 14:39:20 +1000 |
| commit | fe9eaf12f391232f195ac052005ac2b852409dd6 (patch) | |
| tree | f3fafe6b57b8a4f4c832f17f2002e7019639319e /ports/esp32/uart.h | |
| parent | be25e333dfff076f631e50fd5eec2fa626b2625b (diff) | |
esp32: Add MICROPY_HW_ENABLE_UART_REPL and enable on generic S2/S3.
Some S2/S3 modules don't use the native USB interface but instead have an
external USB-UART. To make the GENERIC_S3/S3 firmware work on these boards
the UART REPL is enabled in addition to the native USB CDC REPL.
Fixes issues #8418 and #8524.
Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'ports/esp32/uart.h')
| -rw-r--r-- | ports/esp32/uart.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ports/esp32/uart.h b/ports/esp32/uart.h index f32d5cf34..e3c7482e7 100644 --- a/ports/esp32/uart.h +++ b/ports/esp32/uart.h @@ -28,6 +28,11 @@ #ifndef MICROPY_INCLUDED_ESP32_UART_H #define MICROPY_INCLUDED_ESP32_UART_H +// Whether to enable the REPL on a UART. +#ifndef MICROPY_HW_ENABLE_UART_REPL +#define MICROPY_HW_ENABLE_UART_REPL (!CONFIG_USB_ENABLED && !CONFIG_ESP_CONSOLE_USB_SERIAL_JTAG) +#endif + #ifndef MICROPY_HW_UART_REPL #define MICROPY_HW_UART_REPL (UART_NUM_0) #endif |
