SPRUJG0B December 2024 – November 2025 F29H850TU , F29H859TU-Q1
To understand the number of required Flash wait states depending on the CPU clock frequency, see the Flash Parameters section of the F29H85x and F29P58x Real-Time Microcontrollers Data Sheet. Also, make sure Pre-fetch, Pre-read and caches are enabled. Flash_initModule() can be used to perform these operations:
voidFlash_initModule(uint16_twaitstates)
{
..
// Set waitstates according to frequency
Flash_setWaitstates(waitstates);
..
// Enable data cache, code cache, prefetch, and data preread to improve performance of code// executed from flash.
Flash_configFRI(FLASH_FRI1, FLASH_DATAPREREAD_ENABLE | FLASH_CODECACHE_ENABLE | FLASH_DATACACHE_ENABLE | FLASH_PREFETCH_ENABLE);
..
}