Page 1 of 1

idf.py flash only, skip build

Posted: Wed May 15, 2024 7:50 am
by MeriJo
Hey,

I am setting up a pc for flashing my app onto many esp32-wroom-32e chips. I copied the project folder over and it flashed the app as it should.
I want to remove the base code (like main.c, etc) from the project because I don't want people using this pc to have access to it. But it seems that, when I run "idf.py -p comX flash" command, it tries to rebuild or it checks for those files and fails if I have them removed from the folder.

Is there a command to just flash the app onto the chip? Maybe use what's in the build folder?

Kind regards,
Meri

Re: idf.py flash only, skip build

Posted: Wed May 15, 2024 9:10 am
by ESP_Roland
At the end of the output of "idf.py build" you can see the flashing command using esptool.py. Running that command won't re-trigger build.

This also means that you don't even need on the flashing machine to have ESP-IDF. You can set up just esptool.py there (https://docs.espressif.com/projects/esp ... ation.html) and copy over just the binaries to flash.

BTW, there is also a new "idf.py merge-bin" command (only in the very latest ESP-IDF) which creates one binary and then you can move to the flashing machine only one file.

Re: idf.py flash only, skip build

Posted: Wed May 15, 2024 1:24 pm
by MeriJo
Thank you so much!