hi ALL
I created a project about pit timer about 1 ms timer interrupt with RTD 3.0.0 ,S32DS 3.5, s32K312
PIT clock frequency is 30 MHz ,so 1 ms =1/( 30 MHz/30000)
so PIT_PERIOD = 30000,but the timer is incorrect ,
and i debug the project find the PIT clock frequency ≈ 121 MHz
could you tell me was wrong with my project ?thanks
see attached file "pit_test.zip"
Solved! Go to Solution.
Hi,
your system is running out of FIRC not SPLL due to wrong clock init API used.
So instead of Clock_Ip_InitClock(&Clock_Ip_aClockConfig[0]); use rather
Clock_Ip_Init(&Clock_Ip_aClockConfig[0]);
then have #define PIT_PERIOD 30000U /* 1ms */ as you calculated
BR, Petr
Hi,
your system is running out of FIRC not SPLL due to wrong clock init API used.
So instead of Clock_Ip_InitClock(&Clock_Ip_aClockConfig[0]); use rather
Clock_Ip_Init(&Clock_Ip_aClockConfig[0]);
then have #define PIT_PERIOD 30000U /* 1ms */ as you calculated
BR, Petr