TPM timer initial delay when using 32kHz EXTAL

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

TPM timer initial delay when using 32kHz EXTAL

1,334件の閲覧回数
jpatel1
Contributor I

I'm trying to use TPM clock on KL17 using external 32kHz crystal. I've initialized MOD value with 32, so expecting it to interrupt after 1ms.

But I always get the first interrupt from tpm counter after 120ms delay, subsequent interrupts happen at 1ms interval.

Any pointers to debugging this issue?

ラベル(1)
0 件の賞賛
返信
2 返答(返信)

1,190件の閲覧回数
jpatel1
Contributor I

Thanks Vincente for the response!

I am using gpio pin toggle when I initialize TPM timer and when I receive interrupt; measuring the delay using oscilloscope.

what is the best way to verify in code if crystal/clock stabilization has happened?  

I am using VLPS3 sleep mode with RTC configured for external crystal. I was expecting the delay will not happen when waking up from sleep as OSC still running in sleep mode. What am I missing here?

0 件の賞賛
返信

1,190件の閲覧回数
vicentegomez
NXP TechSupport
NXP TechSupport

Hi

How are you measuring the first pulse, remember you will need to add the time for the clock stabilization