in order flashing images I built esptool and mkspiffs as a standalone exe for Windows,
because I'd like to config my little app outside an esp-idf.
Both exe seem work fine, but with the exe stuff no data are read from the config.txt.
Making the spiffs image on Windows:
Code: Select all
mkspiffs.exe -d 5 -c image -b 4096 -p 256 -s 1048576 spiffs.bin
esptool.exe --chip esp32 --port COM3 --baud 115200 write_flash -z 0x110000 spiffs.bin
Code: Select all
D:\Source\esp\bitbucket\esp32-uartbridge\bin>mkspiffs -d 5 -c image -b 4096 -p 256 -s 1048576 spiffs.bin
Debug output enabled
/config.txt
file size: 36
D:\Source\esp\bitbucket\esp32-uartbridge\bin>esptool.exe --chip esp32 --port COM3 --baud 115200 write_flash -z 0x110000 spiffs.bin
esptool.py v2.2.1
Connecting........_
Chip is ESP32D0WDQ6 (revision 0)
Uploading stub...
Running stub...
Stub running...
Configuring flash size...
Auto-detected Flash size: 4MB
Compressed 1048576 bytes to 2088...
Wrote 1048576 bytes (2088 compressed) at 0x00110000 in 0.2 seconds (effective 39945.8 kbit/s)...
Hash of data verified.
Leaving...
Hard resetting...
D:\Source\esp\bitbucket\esp32-uartbridge\bin>flash_config.cmd
D:\Source\esp\bitbucket\esp32-uartbridge\bin>mkspiffs.exe -d 5 -c image -b 4096 -p 256 -s 1048576 spiffs.bin
Debug output enabled
/config.txt
file size: 36
Code: Select all
I (0) cpu_start: App cpu up.
I (210) heap_init: Initializing. RAM available for dynamic allocation:
I (217) heap_init: At 3FFAE6E0 len 00001920 (6 KiB): DRAM
I (223) heap_init: At 3FFB29D8 len 0002D628 (181 KiB): DRAM
I (229) heap_init: At 3FFE0440 len 00003BC0 (14 KiB): D/IRAM
I (235) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM
I (242) heap_init: At 40088B48 len 000174B8 (93 KiB): IRAM
I (248) cpu_start: Pro cpu start user code
I (266) cpu_start: Starting scheduler on PRO CPU.
I (0) cpu_start: Starting scheduler on APP CPU.
I (353) ...SPIFFS...: Initializing SPIFFS
I (463) ...SPIFFS...: Partition size: total: 956561, used: 502
I (463) config.txt: bytes read: 0
(If fopen results in an Error, a message would shown)
same procedure within esp-idf (msys2)
Code: Select all
$ make makefs
Making spiffs image ...
/config.txt
$ make flashfs monitor
Make & flash spiffs image ...
/config.txt
esptool.py v2.2.1
Connecting........_
Chip is ESP32D0WDQ6 (revision 0)
Uploading stub...
Running stub...
Stub running...
Configuring flash size...
Auto-detected Flash size: 4MB
Compressed 1048576 bytes to 2089...
Wrote 1048576 bytes (2089 compressed) at 0x00110000 in 0.2 seconds (effective 39945.7 kbit/s)...
Hash of data verified.
Leaving...
Hard resetting...
MONITOR
.....
I (0) cpu_start: App cpu up.
I (210) heap_init: Initializing. RAM available for dynamic allocation:
I (217) heap_init: At 3FFAE6E0 len 00001920 (6 KiB): DRAM
I (223) heap_init: At 3FFB29D8 len 0002D628 (181 KiB): DRAM
I (229) heap_init: At 3FFE0440 len 00003BC0 (14 KiB): D/IRAM
I (235) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM
I (242) heap_init: At 40088B48 len 000174B8 (93 KiB): IRAM
I (248) cpu_start: Pro cpu start user code
I (266) cpu_start: Starting scheduler on PRO CPU.
I (0) cpu_start: Starting scheduler on APP CPU.
I (353) ...SPIFFS...: Initializing SPIFFS
I (463) ...SPIFFS...: Partition size: total: 956561, used: 502
I (463) config.txt: bytes read: 36
I (463) config.txt: SSID wlanssid
I (473) config.txt: PW wlanpw
linuxpaul