:: Erase flash
set /p pport=Enter a Com port
echo %pport%
pause
esptool.py --port %pport% erase_flash
pause
The Output:
C:\Users\jj\Documents\espruinoEsp8266Flash\espruino_1v95_esp32>set /p pport=Enter a Com port
Enter a Com port com7
C:\Users\jj\Documents\espruinoEsp8266Flash\espruino_1v95_esp32>echo com7
com7
C:\Users\jj\Documents\espruinoEsp8266Flash\espruino_1v95_esp32>pause
Press any key to continue . . .
C:\Users\jj\Documents\espruinoEsp8266Flash\espruino_1v95_esp32>esptool.py --port com7 erase_flash
esptool.py v2.2.1
Connecting......
Detecting chip type... ESP32
Chip is ESP32D0WDQ6 (revision 0)
Uploading stub...
Running stub...
Stub running...
Erasing flash (this may take a while)...
Chip erase completed successfully in 7.7s
Hard resetting...
C:\Users\jj\Documents\espruinoEsp8266Flash\espruino_1v95_esp32>pause
Press any key to continue . . .
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Batch file to erase flash on ESP8266 oe ESP32
The Output:
1 Attachment