Repository navigation
stm32gx improvements - #910
Merged
Nightwalker-87 merged 6 commits intoApr 6, 2020
Merged
Conversation
add a 'has_dual_bank' info to flash param, helping handling a couple of cases - selecting over dual bank specific code path without handling multiple chip id all over the code. - handling dual bank mode dynamic configuration
g4 cat3 devices can be configured in two mode via option bytes: - dual bank, 2x256kib, 2KiB pages. - single bank, 1x512KiB, 4KiB pages. in anycase, these have two banks, and need to be handled with more care. -> read optr after loading flash params to patch page size. -> in single bank mode, mass erase _must_ be triggered by applying MER1 and MER2 bits. erasing half of the flash will lead to a pgserr.
toggle proper MER bits, taking in account dual bank mode enabled or not.
only implement it for g0/g4 for now, but this is most probably a must for all chips.
Nightwalker-87
approved these changes
Apr 6, 2020
Member
|
Merci 🥇 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi,
here are a few patches to improve g4/g0 support
has_dual bank flag could probably avoid multiple device type check around the code with a bit of work.
flash programming check could probably be added in page erase and flash write and extended to other devices, to debug some silent issues.