Fixes to write/erase failures observed on Winbond SPI flash W25Q128JV#4
Open
jcard0na wants to merge 3 commits intoChurrosoft:masterfrom
Open
Fixes to write/erase failures observed on Winbond SPI flash W25Q128JV#4jcard0na wants to merge 3 commits intoChurrosoft:masterfrom
jcard0na wants to merge 3 commits intoChurrosoft:masterfrom
Conversation
added 3 commits
November 30, 2023 21:44
This example does result in verification failures in a setup with STM32 and Winbond W25Q128JV flash.
Any write or erase command will be ignored unless this bit is set, so make sure the WEL bit is set before exiting write_enable(). The WEL bit is set in response to the Write Enable command, but prior to this change, the WEL bit status was not being checked. This would result in occasional erase failures.
This addresses two failure modes associated with the reading of the BUSY status bit: the case when the BUSY bit is not yet set on entering the function, and the case where it is briefly cleared but immediately reset by the chip. The latter is not really documented behavior but has been observed on Winbond W25Q128JV
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
These changes solve several issues we observed with this driver and Winbond's SPI flash W25Q128JV.
The observed symptoms were occasional failed erase and write operations. The example code in the first commit reveals the problems and we observe many failures unless the subsequent commits are applied.