I am using ESP-S3-12K from AI-Thinker. After upload Micropython image to flash, and reset, I cannot see REPL via serial port.
I read the online document, I saw the following statement:
Once you have the firmware on the device you can access the REPL (Python prompt) over UART0 (GPIO1=TX, GPIO3=RX), which might be connected to a USB-serial convertor.
Howerver, for my board, UART0 is on GPIO43 and GPIO44. I guess that is the root cause.
If my guess is correct, the question is: how can I modify MicroPython code to make REPL work for my board?
REPL console
-
- Posts: 6
- Joined: Mon Mar 21, 2022 10:55 am
Re: REPL console
Here is the output I got from COM4 (via putty):
ESP-ROM:esp32s3-20210327
Build:Mar 27 2021
rst:0x1 (POWERON),boot:0x8 (SPI_FAST_FLASH_BOOT)
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fcd0108,len:0x1030
load:0x403b6000,len:0xd6c
load:0x403ba000,len:0x2d60
entry 0x403b6228
-----------------------------------------
I wrote a simple app using C language. It can print message to the serial console without any issue. So, I guess issue is specific to MicroPython.
ESP-ROM:esp32s3-20210327
Build:Mar 27 2021
rst:0x1 (POWERON),boot:0x8 (SPI_FAST_FLASH_BOOT)
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fcd0108,len:0x1030
load:0x403b6000,len:0xd6c
load:0x403ba000,len:0x2d60
entry 0x403b6228
-----------------------------------------
I wrote a simple app using C language. It can print message to the serial console without any issue. So, I guess issue is specific to MicroPython.
Re: REPL console
Hi, I had a similar issue with an ESP32-S2, maybe this thread will help ?
-
- Posts: 6
- Joined: Mon Mar 21, 2022 10:55 am
Re: REPL console
Thank you ash10.
But my issue could be different. As I mentioned, I can run C program without any issue. So, I did more testing. I flashed the following images to the chip:
So, the issue is with the bootloader: the bootloader generated from micropython project does NOT work, but the bootloader generated from my C program project does work.
I am new to ESP32, please correct me if I am wrong: all bootloader code comes from IDF framework, it is just compiled in micropython project, and use certain customized configurations of micropython project. Appreciate if anyone can give me some clues how to investigate the issue.
But my issue could be different. As I mentioned, I can run C program without any issue. So, I did more testing. I flashed the following images to the chip:
- bootloader image of my C program.
mycropython image
partition table image of my C program.
So, the issue is with the bootloader: the bootloader generated from micropython project does NOT work, but the bootloader generated from my C program project does work.
I am new to ESP32, please correct me if I am wrong: all bootloader code comes from IDF framework, it is just compiled in micropython project, and use certain customized configurations of micropython project. Appreciate if anyone can give me some clues how to investigate the issue.
-
- Posts: 6
- Joined: Mon Mar 21, 2022 10:55 am
Re: REPL console
I have been able to get a workaround for this issue with ESP-S3-12K:
Using the most recent (HEAD) code of MicroPython (need to use the new function uart_stdout_init() to init UART)
Disable USB settings in sdkconfig.usb
Then I can get a workable REPL on UART console.
Hope this is useful to others as well. And hope we can get next MicroPython release soon.
Using the most recent (HEAD) code of MicroPython (need to use the new function uart_stdout_init() to init UART)
Disable USB settings in sdkconfig.usb
Then I can get a workable REPL on UART console.
Hope this is useful to others as well. And hope we can get next MicroPython release soon.