-
Notifications
You must be signed in to change notification settings - Fork 125
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
espflash save-image
always creates a binary which is the bootloader, partition table and factory image concatenated together
#714
Comments
By coincidence I was finally getting around to posting some of my patches I've had because I needed to sign and encrypt individual partitions and found this report posted on the same day. I'm not sure my patch addresses everything listed above though.
Actual:
Expected each segment to be saved as individual binaries. This is critical for signing and encrypting partitions individually With my proposed patch:
NOTE: the default output now matches the documentation but if anyone has built any automation around the current behavior, they will break. |
UPDATED: I confused Thank you for chiming-in! Glad to see other folks are also looking into this. An alternative might be to keep
BTW - and for the super-short-term (I'm really pressed by time) - there is now as mentioned You'll need |
I actually have a full working writeup on how to enable encryption and save images with espflash except for No need for anyone to trash a bunch of ESPs anymore. The worst I did to mine was permanently enable Secure Download Mode and disable JTAG. |
I'm in the mid-to-end of my own journey in doing this. I'm using the following:
How do you deploy the whole circus at the factory premises? I did over-design a bit and rather than a python/shell script that glues it all together, I have a WIP Rust tool -
No by trashing a bunch of ESPs what I mean is only if we (or somebody) tries to re-write |
I.e. invoking (via the command line, or via the
espflash
API):... would output a
my-firmware.bin
which - sequentially:Now, I get it that this way it is maybe simpler for the user - in un-sophisticated scenarios - to flash the binary by just doing then
espflash write-bin --chip esp32s3 0 my-firmware-.bin
but this is making it difficult for that very same user to cover the scenario where she just wants her.ELF
to be converted to.bin
on the command-line without any bootloader and partition-table concatenations in-between.Even when using the
espflash
API rather than the command line, it is a bit weird, as I still have to deal with the bootloader and the partition table, even though - as mentioned - I just want to convert the .ELF to bin no extra stuff included thank you very much :-)Also the question is a bit - in those un-sophisticated scenarios - the user is likely not going through the two step process of "save-image" and "write-bin" anyway. She probably just wants to do
espflash flash --chip esp32s3 target/xtensa-esp32s3-espidf/debug/my-firmware
(optionally passing a custom bootloader image and part-table on the command line) and then the "concatenation" is invisible anyways as it happens internally toespflash
. Which is fine.So why not supporting a variant of "save-image" which is doing the "no-thrills" stuff of outputting a binary app image and that's it?
And then separate commands for converting and outputting the embedded bootloader to
.bin
and the embedded or externally-passed partition-table CSV to .bin?The text was updated successfully, but these errors were encountered: