We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 10e9ae7 commit 6f807c6Copy full SHA for 6f807c6
README.md
@@ -31,6 +31,7 @@ world application would be sent this SPI packet to the physically SPI core inste
31
### Limits
32
33
* No timing behavior
34
+ * emulated with [WIP](https://github.com/akaeba/spi_flash_model/blob/main/spi_flash_model.h#L32) poll constant
35
36
37
## Releases
@@ -149,6 +150,12 @@ int main ()
149
150
spi[8] = 0x89;
151
spi[9] = 0xAB;
152
sfm (&spiFlash, spi, 10); // access flash model
153
+ // poll for WIP
154
+ for ( uint8_t i = 0; i < SFM_WIP_RETRY_IDLE; i++ ) {
155
+ spiLen = 2;
156
+ spi[0] = 0x05;
157
+ sfm(&spiFlash, spi, spiLen); // read state reg, needed for WIP poll
158
+ }
159
160
/* dump current flash content to check write */
161
sfm_dump (&spiFlash, 0x0, 0x10);
0 commit comments