We can choose erase flash method like below,
How to config it in platformio.ini?
thank you.
Open PlatformIO IDE Terminal and type pio run --target erase
i get ** Do not know how to make File target `erase’
any ideas how to fix this?
It looks like you use outdated ESP8266 dev-platform. Please open PIO Home > Platforms > Updates and update all packages. Otherwise, you can open PIO IDE Terminal and type pio update
.
Is there actually a way to just erase some parts of the flash?
e.g. filesystem (littlefs), eeprom…
You can use tool-esptoolpy package and call esptool.py
directly. See docs for erase*** sub-commands Basic Commands - ESP32 - — esptool.py latest documentation
How to call esptool.py
using PlatformIO?
pio upgrade --dev
command)esptool.py
:pio pkg exec -p tool-esptoolpy -- esptool.py --help
Docs for pio exec command.