Skip to content
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

Support writing binary images directly from flash command. #770

Open
AVee opened this issue Feb 14, 2025 · 0 comments
Open

Support writing binary images directly from flash command. #770

AVee opened this issue Feb 14, 2025 · 0 comments

Comments

@AVee
Copy link
Contributor

AVee commented Feb 14, 2025

Currently the flash command expects an ELF image to be flashed to the device. This makes sense in the context of a cargo project since the output there will always be an ELF image. But on the command line it would be useful to be able to directly flash an already converted image. In our case we already build those for OTA updates and it would be convenient to be able to use the same files when flashing directly.

It looks to me like it's should be doable to just detect the type of file passed to the flash command based on the magic bytes in the file. An ELF file could be converted and flashed, but when a ESP binary is found it's just flashed directly. All of that would then be transparent for the user and 'just work' regardless of the type of image used. Would this be a sensible approach, or would a more explicit (separate command or extra argument) be preferred?

This might be a solution to #684 as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

1 participant