So I built a RAID-like storage thing on an STM32F401RE with 4 Winbond W25Q64FV NOR flashes over SPI. Each stripe is 3 data blocks plus one parity block, P = A ^ B ^ C, and the parity spot rotates across all 4 chips so any single flash can die and the data still comes back. Two failures and you're out of luck, wich I understand is normal for this scheme.
When a failure shows up it kills writes and drops into a read-only degraded mode. Right now the rebuild only happens in the STM32's RAM when a block is asked for, nothing gets rewritten to the flash, and the only input is over UART. I know that's a limitation but it's where I stopped.
I wrote the read, write and clear block drivers myself, poking at the SPI commands, and honestly that part went fine. Where I struggled was linking all 4 flashes into one logical address space and the parity rebuild logic, so I leaned on AI for those pieces. Mostly I just want this finished for my resume, it's up on GitHub if anyone wants a look. If any memory or storage firmware people are reading this, please tear into it. I'm aiming at places like Micron, Western Digital and SanDisk and I'd rather fix the dumb stuff now than get called out later. What should I improve?