No REPL on ESP32-S2

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
p_j
Posts: 102
Joined: Mon Aug 23, 2021 1:08 pm
Location: Sydney

Re: No REPL on ESP32-S2

Post by p_j » Wed Jan 26, 2022 11:49 pm

leosok wrote:
Wed Jan 26, 2022 11:23 pm
Your last reply helped me a lot. "idf.py set-target esp32s2" did copy stuff, and after I could see/turn off TinyUSB in "idf.py menuconfig" - which seems to be off by default. "make BOARD=GENERIC_S2" did build a micropython.bin, which I found out, I needed to flash with the code from provided by make/idf

Code: Select all

esptool.py -p COM11 -b 460800 --before default_reset --after hard_reset --chip esp32s2  write_flash --flash_mode dio --flash_size detect --flash_freq 80m 0x1000 bootloader/bootloader.bin 0x8000 partition_table/partition-table.bin 0x10000 micropython.bin
This did work. But unfortunately again - no REPL.

I wonder if the board-definition BOARD=GENERIC_S2 turns on the TunyUSB again?
I don't think it would turn TinyUSB back on, there doesn't seem to be anything in the board definition.

What board are you using? Are you compiling with something like this.

Code: Select all

idf.py -D MICROPY_BOARD=ESP32_S2_WROVER build   

leosok
Posts: 18
Joined: Sun May 02, 2021 10:10 pm

Re: No REPL on ESP32-S2

Post by leosok » Thu Jan 27, 2022 5:10 pm

:D :D :D
TL;DR: Your command worked:
idf.py -D MICROPY_BOARD=ESP32_S2_WROVER build

The module I'm using is the Lilygo ESP32_S2 module
Honestly, I think I tried all commands for building before, starting with just "make", than, "make BOARD=GENERIC_S2", than
"idf.py -D MICROPY_BOARD=GENERIC_S2 -B build-GENERIC_S2 set-target esp32s2 build" (where I tried everything).

After I built the ESP32_S2_WROVER (as you proposed)

Code: Select all

idf.py -D MICROPY_BOARD=GENERIC_S2 build
also worked. I am puzzled but happy. Thanks for not giving up :-)

p_j
Posts: 102
Joined: Mon Aug 23, 2021 1:08 pm
Location: Sydney

Re: No REPL on ESP32-S2

Post by p_j » Thu Jan 27, 2022 11:30 pm

No problem glad you got it working! I did find it confusing also when I first started. :D
leosok wrote:
Thu Jan 27, 2022 5:10 pm
:D :D :D
TL;DR: Your command worked:
idf.py -D MICROPY_BOARD=ESP32_S2_WROVER build

The module I'm using is the Lilygo ESP32_S2 module
Honestly, I think I tried all commands for building before, starting with just "make", than, "make BOARD=GENERIC_S2", than
"idf.py -D MICROPY_BOARD=GENERIC_S2 -B build-GENERIC_S2 set-target esp32s2 build" (where I tried everything).

After I built the ESP32_S2_WROVER (as you proposed)

Code: Select all

idf.py -D MICROPY_BOARD=GENERIC_S2 build
also worked. I am puzzled but happy. Thanks for not giving up :-)

Post Reply