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

add argument to erase flash before flashing #344

Closed
wants to merge 1 commit into from

Conversation

Callahan93
Copy link
Contributor

Description of change

Sometimes we want to erase the whole chip because we use some partitions for other data (like OTA) which is not overwritten when flashed with new firmware. Currently, this makes this a 2 stage process (erase_flash ... then write_flash) - This change is intended to make this a one stage command.

As this is a new argument please advise if you prefer another format.

I have tested this change with the following hardware & software combinations:

ESP32, Windows 7, Python 3.6

projectgus pushed a commit that referenced this pull request Jan 9, 2019
@marcelstoer
Copy link
Contributor

Since v2.6 is out now this could be closed I guess.

@projectgus
Copy link
Contributor

@marcelstoer You're too quick for me. It can indeed, cherry-picked as 822112b (small tweak: used a hyphen instead of an underscore for --erase-all. Eventually I want to standardize on hyphens for all commands and options, probably as a breaking change in v3.0).

There are probably some optimisations possible with this option, at least with the stub, because sending "Sector Erase"/"Block Erase" commands are redundant if we know the whole chip is already erased. But this is fine for now (and sector erases take less time when the chip is erased, so the performance hit is not as bad as it could be!).

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

Successfully merging this pull request may close these issues.

3 participants