2023-02-24 06:42 AM
I'm trying to write on the flash of the stm32u5 microcontroller. Why in the flash driver, in particular in the file stm32u5xx_hal_flash.c, is present only FLASH_TYPEPROGRAM_QUADWORD and FLASH_TYPEPROGRAM_BURST? Is it not possible to write on the flash a single byte?Thank you.
2023-02-24 06:47 AM
Right, because the flash line in the array is wider, and also contains additional error-correction bits that are not directly visible to you.
You're going to have adapt, and write bigger structures.
2023-02-24 11:58 AM
This is a limitation of STM32. Each model has a minimal write granularity. Some other flash chips allow writing even by single bits (toggle any 1 to 0).