Hi SIVA VELUPPILLAI ,
You mentioned: During this 250mS sleep the only thing needed to work is wake up from pin change/pin interrupt.
Do you mean, you want 250ms to wake up from VLPS, or the external pin interrupt, right?
Then you want to use the LPTMR as the timer to wake up from the VLPS, right?
LPO 1Khz is defined, and can't be calibrated.
But I think you can use ERCLK32K:
Because already add the external 32K crystal, you can use it.
Wish it helps you!
If you still have questions about it, please kindly let me know.
Thank you Kerry for the reply,
Yes we want either the wake up conditions to wake:
1) 250ms to wake up from VLPS or
2) External pin interrupt
The LPTMR0 is used in the main full run and are we able to use this during sleep?
We can restart this timer and reinitialise, when we wake up.
Are you able to share a sample code routine to switch LPTMR for 250ms wake up with 32.768Hz clock?
How many LPTMR are they?
Hi SIVA VELUPPILLAI,
Check the RM, chapter 7, you will find LPTMR0 works in VLPS mode, LPTMR is the low power timer.
Before you enter the VLPS mode, set your LPTMR timer interrupt to 250ms, then enter the VLPS, after 250ms, the LPTMR interrupt will happens and wake up the VLPS directly.
Wish it helps you!.