Page 1 of 1

idf.py export-manifest

Posted: Wed Feb 28, 2024 3:50 pm
by DrMickeyLauer
I wonder whether there is something like idf.py export-manifest (name made up) that does the following steps:
  • Build the project, if necessary.
  • Parse the output of the idf.py build command to find out which build artefacts exist.
  • Grab the build artefacts and copy them into a directory together with a script that calls esptool to flash.
  • (Optionally) Zip everything up for sending.
That way I could easily send the programming data to someone who just needs esptool installed.

Re: idf.py export-manifest

Posted: Wed Feb 28, 2024 3:56 pm
by DrMickeyLauer
I just learned about uf2.bin that looks like it's a step in that direction, however it seems to be solely for the esp-usb-bridge -- or can I use uf2.bin also as input file for esptool?

Re: idf.py export-manifest

Posted: Wed Feb 28, 2024 11:09 pm
by MicroController
DrMickeyLauer wrote:
Wed Feb 28, 2024 3:50 pm
  • ...
  • Parse the output of the idf.py build command to find out which build artefacts exist.
    ...
This would be pretty easy to do: Look at "flasher_args.json" or "flash_project_args" inside the build directory. If you zip up the .bin files named there and pass them on together with the flash_project_args file and a batch file like

Code: Select all

@echo off
pushd build
%IDF_PYTHON% %IDF_PATH%\components\esptool_py\esptool\esptool.py -p COM7 -b 460800 --before default_reset --after hard_reset --chip esp32s3 write_flash @flash_project_args
popd
you're almost set :)