Skip to content

Add support for flash.rs on bigger chips #168

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

Merged
merged 2 commits into from
Feb 8, 2022

Conversation

maximeborges
Copy link
Member

The current code to erase flash is only using the mer field.
On bigger chips, there is two memory banks, so the mer field is split in two for the two memory banks, mer1 and mer2.

This PR add checks to configure either mer or mer[12] for erase functions.

@maximeborges maximeborges force-pushed the bugfix/flash_on_big_chips branch from 8c46b5c to 649f65c Compare January 28, 2022 16:47
@maximeborges maximeborges changed the title Add support for flash.rs on bigger chips (F7x[6789]) Add support for flash.rs on bigger chips Jan 28, 2022
@hannobraun
Copy link
Contributor

See #167 (comment).

Copy link
Contributor

@hannobraun hannobraun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks again, @maximeborges!

How confident are you in this change? I don't have a test setup ready, don't really understand what this does, and don't have the time to study up in the reference manual.

If you're happy with your testing and your understanding this change, that's good enough for me. If this requires more testing, I can add a help wanted label.

Also, CI is failing, due to formatting. Running cargo fmt should fix that.

Once CI is green and you give me the go-ahead regarding my questions above, I'm happy to merge.

@maximeborges maximeborges force-pushed the bugfix/flash_on_big_chips branch from bb922f1 to 4ab3693 Compare February 8, 2022 16:53
@maximeborges
Copy link
Member Author

I confirm that this example works on my Nucleo-F767ZI

Copy link
Contributor

@hannobraun hannobraun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CI is green now. Thank you, @maximeborges!

@hannobraun hannobraun merged commit 90ca932 into stm32-rs:master Feb 8, 2022
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.

2 participants