Skip to content

Add NOR flash trait #6

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 5 commits into from
Jan 15, 2021

Conversation

Sympatron
Copy link
Contributor

@Sympatron Sympatron commented Dec 10, 2020

This is my first try of a NOR flash trait.

try_read, try_write and try_erase are similar to ReadWrite, but with different semantics.

Additionally it can return up to 4 regions with differing erase sizes to account for flashes that support some erase sizes only for specific address ranges.

Ate the moment regions and erase_sizes return heapless::Vec. I don't know if this is the optimal way to go.

This was discussed in #1 and #3.

@Sympatron
Copy link
Contributor Author

I thought adding a simplified version for everyone who doesn't want to deal with the complexity of different regions is a good idea.

@MathiasKoch
Copy link
Collaborator

@Sympatron Could you rebase this?

@MathiasKoch MathiasKoch merged commit 52a1352 into rust-embedded-community:master Jan 15, 2021
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