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

espflash is not compatible with Secure Download mode #740

Closed
ivmarkov opened this issue Feb 3, 2025 · 1 comment
Closed

espflash is not compatible with Secure Download mode #740

ivmarkov opened this issue Feb 3, 2025 · 1 comment

Comments

@ivmarkov
Copy link
Contributor

ivmarkov commented Feb 3, 2025

Once Secure Download mode had been enabled on the MCU (by burning the relevant eFUSE bits), espflash is unable to flash a binary (or ELF) image anymore.

Note that this is not related to the stub loader, because I'm passing the --no-stub flag:

ivan@ivan-laptop:~$ espflash flash --no-stub --chip esp32s3 --flash-size 16mb ./my-firmware 
[2025-02-03T12:35:14Z INFO ] Serial port: '/dev/ttyUSB0'
[2025-02-03T12:35:14Z INFO ] Connecting...
Error: espflash::timeout

  × Error while connecting to device
  ╰─▶ Timeout while running ReadReg command

I've also tried various combinations of --before (and --after) reset sequences, but none of those did work.

Note that esptool is capable of flashing even when the chip is in a Secure Download mode.
The command to do so is something like:

esptools tool --chip esp32s3 --no-stub write_flash 0x10000 ./my-firmware.bin --flash_size 16mb --force 

... where the --force parameter does all the magic.

@ivmarkov
Copy link
Contributor Author

ivmarkov commented Feb 3, 2025

Ah, I've already reported this as #726 !

@ivmarkov ivmarkov closed this as completed Feb 3, 2025
@github-project-automation github-project-automation bot moved this from Todo to Done in esp-rs Feb 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

No branches or pull requests

1 participant