I’ve received a couple of ProS3 devices. The run the LED lighting code fine but that is not what I bought them for.
I’m using Linux Mint 64 bit and Thonny 4.02. I’ve been able to install pros3-20220618-v1.19.1.bin but when I go to the main interface and click the “Stop” button (even after reconnecting the Esp32) I just get:
============
invalid header: 0xffffffff
invalid header: 0xffffffff
invalid header: 0xffffffff
invalid header: 0xffffffff
Connection lost – device reports readiness to read but returned no data (device disconnected or multiple access on port?)
Use Stop/Restart to reconnect.
Process ended with exit code 1.
I also dragged out a Linux notebook and after lots of updating couldn’t even setup the firmware.
Any advice?
1 Like
Hi John,
Welcome to the forum
I’m not sure exactly what’s caused that issue but I’ve found a few similar reports that were caused by having the ESP32 variant set slightly wrong, which caused the chip to fail to flash correctly. If your standard blinky sketch works ok but the other binary doesn’t is it possible it was generated for a slightly different ESP32 version?
Other users have got similar error messages related to flash either being present or not targeted correctly for their specific board variant.
opened 08:15AM - 23 May 22 UTC
closed 01:27AM - 24 May 22 UTC
Status: Opened
- Module or chip used: ESP32-C3 on a customized board
- IDF version: v5.0-dev-3… 043-g70109e2393
- Build System: idf.py
- Compiler version: riscv32-esp-elf-gcc (crosstool-NG esp-2021r2-patch3) 8.4.0
- Operating System: Linux
- Power Supply: USB
It looks like "idf.py app-flash" can successfully download the firmware,
however, monitor shows "invalid header: 0xffffffff".
Also note "idf.py erase-flash" got error:
A fatal error occurred: ESP32-C3 ROM does not support function erase_flash.
esptool.py failed with exit code 2
See below log:
$ idf.py app-flash monitor
Executing action: app-flash
Serial port /dev/ttyACM0
Connecting....
Detecting chip type... ESP32-C3
Running ninja in directory /home/axel/esp/esp-idf-dev/apps/myproj/build
Executing "ninja app-flash"...
[1/2] cd /home/axel/esp/esp-idf-dev/apps/myproj/build/esp-idf/esptool_py && /home/axel/.espressif/p...ld/partition_table/partition-table.bin /home/axel/esp/esp-idf-dev/apps/myproj/build/myproj.bin
[1/2] cd /home/axel/esp/esp-idf/components/esptool_py && /usr/local/bin/cmake -D IDF_PATH=/home/axel/esp...esp-idf-dev/apps/myproj/build -P /home/axel/esp/esp-idf/components/esptool_py/run_serial_tool.cmake
esptool.py esp32c3 -p /dev/ttyACM0 -b 460800 --before=default_reset --after=hard_reset --no-stub write_flash --flash_mode dio --flash_freq 80m --flash_size 4MB 0x110000 myproj.bin
esptool.py v3.3.1
Serial port /dev/ttyACM0
Connecting...
Chip is ESP32-C3 (revision 3)
Features: Wi-Fi
Crystal is 40MHz
MAC: 7c:df:a1:a4:93:28
Changing baud rate to 460800
Changed.
Enabling default SPI flash mode...
Configuring flash size...
Flash will be erased from 0x00110000 to 0x00214fff...
Erasing flash...
Took 5.33s to erase flash block
Writing at 0x00110000... (0 %)
Writing at 0x00110400... (0 %)
Writing at 0x00110800... (0 %)
Writing at 0x00110c00... (0 %)
Writing at 0x00111000... (0 %)
Writing at 0x00111400... (0 %)
Writing at 0x00111800... (0 %)
Writing at 0x00111c00... (0 %)
Writing at 0x00112000... (0 %)
Writing at 0x00112400... (0 %)
Writing at 0x00112800... (1 %)
Writing at 0x00112c00... (1 %)
Writing at 0x00113000... (1 %)
Writing at 0x00113400... (1 %)
Writing at 0x00113800... (1 %)
Writing at 0x00113c00... (1 %)
Writing at 0x00114000... (1 %)
Writing at 0x00114400... (1 %)
Writing at 0x00114800... (1 %)
Writing at 0x00114c00... (1 %)
Writing at 0x00115000... (2 %)
Writing at 0x00115400... (2 %)
...
Writing at 0x0020f400... (98 %)
Writing at 0x0020f800... (98 %)
Writing at 0x0020fc00... (98 %)
Writing at 0x00210000... (98 %)
Writing at 0x00210400... (98 %)
Writing at 0x00210800... (98 %)
Writing at 0x00210c00... (98 %)
Writing at 0x00211000... (98 %)
Writing at 0x00211400... (98 %)
Writing at 0x00211800... (99 %)
Writing at 0x00211c00... (99 %)
Writing at 0x00212000... (99 %)
Writing at 0x00212400... (99 %)
Writing at 0x00212800... (99 %)
Writing at 0x00212c00... (99 %)
Writing at 0x00213000... (99 %)
Writing at 0x00213400... (99 %)
Writing at 0x00213800... (99 %)
Writing at 0x00213c00... (99 %)
Writing at 0x00214000... (100 %)
Wrote 1065984 bytes at 0x00110000 in 16.0 seconds (533.9 kbit/s)...
Hash of data verified.
Leaving...
Hard resetting via RTS pin...
Executing action: monitor
Serial port /dev/ttyACM0
Connecting...
Detecting chip type... ESP32-C3
Running idf_monitor in directory /home/axel/esp/esp-idf-dev/apps/myproj
Executing "/home/axel/.espressif/python_env/idf5.0_py3.10_env/bin/python /home/axel/esp/esp-idf/tools/idf_monitor.py -p /dev/ttyACM0 -b 115200 --toolchain-prefix riscv32-esp-elf- --target esp32c3 --decode-panic backtrace /home/axel/esp/esp-idf-dev/apps/myproj/build/myproj.elf -m '/home/axel/.espressif/python_env/idf5.0_py3.10_env/bin/python' '/home/axel/esp/esp-idf/tools/idf.py'"...
--- idf_monitor on /dev/ttyACM0 115200 ---
--- Quit: Ctrl+] | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H ---
ESP-ROM:esp32c3-api1-20210207
Build:Feb 7 2021
rst:0x15 (USB_UART_CHIP_RESET),boot:0xd (SPI_FAST_FLASH_BOOT)
Saved PC:0x4004c728
invalid header: 0xffffffff
invalid header: 0xffffffff
invalid header: 0xffffffff
invalid header: 0xffffffff
....
invalid header: 0xffffffff
invalid header: 0xffffffff
invalid header: 0xffffffff
invalid header:ESP-ROM:esp32c3-api1-20210207
Build:Feb 7 2021
rst:0x7 (TG0WDT_SYS_RST),boot:0xd (SPI_FAST_FLASH_BOOT)
Saved PC:0x4004c0d4
...
$ idf.py erase-flash
Executing action: erase-flash
Serial port /dev/ttyACM0
Connecting.....
Detecting chip type... ESP32-C3
Running esptool.py in directory /home/axel/esp/esp-idf-dev/apps/myproj/build
Executing "/home/axel/.espressif/python_env/idf5.0_py3.10_env/bin/python /home/axel/esp/esp-idf/components/esptool_py/esptool/esptool.py -p /dev/ttyACM0 -b 460800 --before default_reset --after hard_reset --chip esp32c3 --no-stub erase_flash"...
esptool.py v3.3.1
Serial port /dev/ttyACM0
Connecting...
Chip is ESP32-C3 (revision 3)
Features: Wi-Fi
Crystal is 40MHz
MAC: 7c:df:a1:a4:93:28
Changing baud rate to 460800
Changed.
Enabling default SPI flash mode...
Erasing flash (this may take a while)...
A fatal error occurred: ESP32-C3 ROM does not support function erase_flash.
esptool.py failed with exit code 2
1 Like
Attached is a screenshot that shows how I chose the firmware. It clearly matches the ProS3 whereas none of the others do. I also tried other variants with no success.
It looks as though I’m wasting my time with these boards. I had no problems with a friend’s eBay ESP32 earlier this week.
1 Like
Hi John,
Would it be possible to paste the command you used to flash the micropython image?
Noting that with the S3 you have to start writing from 0x0 rather than 0x1000 on the ESP32 (not S3).
Does ESPtool show any errors during installation?
1 Like
Using 0x0 did the trick Liam. That is what the download page for the ProS3 specifies if you use esptool.py.
I was using Thonny to do the installation. It looks as though it uses 0x000 and there is no option to change that.
I used esptool.py to erase and then write the flash file using 0x0 rather than 0x000. I could then open Thonny and it immediately showed:
MicroPython v1.19.1 on 2022-06-18; ProS3 with ESP32-S3
Type “help()” for more information.
Thanks for the forum help and to your advice in particular Liam.
1 Like
Hi John,
I believe Thonny only starts at 0x1000 for the ‘standard’ ESP32, glad to hear you got it working tho! The ProS3’s are great boards😁
1 Like
In the future I’ll use esptool.py directly for flashing. Thonny uses esptools.py but clearly doesn’t pass the correct starting memory address for writing.
I bought 2 ProS3 boards and left the second alone. It is probably good to use as is but both boards booted up and run a RGB LED program and don’t have boot.py or main.py. I prefer to build on a solid platform.
I had no problems getting MQTT running so don’t expect problems when I get serious.
Thanks again Liam.
1 Like