ST 32f429I-Discovery wrong delay timing

Hi guys, I’m trying to use freeRTOS 8.1.2 with the aforementioned board but till now I only have bad timings. I’ve attached my current configuration for freeRTOS any idea?

ST 32f429I-Discovery wrong delay timing

#define configCPU_CLOCK_HZ ( SystemCoreClock )
Are you setting SystemCoreClock anywhere? To do that you normally call SystemCoreClockUpdate.

ST 32f429I-Discovery wrong delay timing

Yes, I’ve checked and it correctly returns 180000000 (180MHz). I’m using the Standard Peripheral Driver from ST website, no problem at all with STM32F407 cpu

ST 32f429I-Discovery wrong delay timing

Is SystemCoreClockUpdate() setting up the clock, or just setting SystemCoreClock to 180000000. If it is not setting up the clock does anything set up the clock. Maybe it is done before main() is called. My guess is the clock is not actually running at 180000000.

ST 32f429I-Discovery wrong delay timing

SystemCoreClock is 168000000 at default, after initialization becames 180000000. I’m really stuck in this, seems like if the clock is about 4 times slower. I was wondering, on which clock the tick frequency is calculated? Could it be a PCLK1 or PCLK2?

ST 32f429I-Discovery wrong delay timing

Solved, the default main clock, as you said, was different. FIXED Thanks a lot