Hei,
I have a project in CW 10.6, using Processor Expert, where a timer should wake up the MCU from STOP (LLS) mode every second. I'm using LPTMR0 as LLWU source, which works fine.
Measuring the current the MCU uses in LLS mode - 0.4 mA - I noticed that the clock source for the LPTMR is not LPO, but actually ERCLK (8 Mhz). I think that this is causing the high current consumption in LLS mode.
How can I get Processor Expert to use LPO as a clock source for LPTMR in order to save some power in LLS mode?
From this picture, the Processor Expert help text suggests that LPO is already used as source for LPTMR.
From this Timing dialog at the bottom of the screen I see that actually ERCLK with 8Mhz is used as a clock source for LPTMR.
Attached are the Processor Expert settings as well.
Do I need to use another MCG mode?
Any hints or suggestions are highly appreciated!
Best regards,
Dominik
Original Attachment has been moved to: pesettings.pef.zip
Solved! Go to Solution.
Hello Dominik,
You can select LPO clock source by using timing dialog of the Counter Frequency property of the UtcClockTimer:TimerUnit_LDD component in your project. See the screenshot below:
Please note, that the Period property just select the module value of counter.
Best Regards,
Marek Neuzil
Hello Dominik,
You can select LPO clock source by using timing dialog of the Counter Frequency property of the UtcClockTimer:TimerUnit_LDD component in your project. See the screenshot below:
Please note, that the Period property just select the module value of counter.
Best Regards,
Marek Neuzil
Dominik
I can't help with the PE setup but to use the LPO for the LPTMR you just need to select it as follows:
LPTMR0_PSR = (LPTMR_PSR_PCS_LPO | LPTMR_PSR_PBYP);
In the uTasker project this is controlled by the configuration define LPTMR_CLOCK_LPO.
As reference, you can check the links below - for the KL26 you can expect about 8mA in RUN mode (at 48MHz), 6mA in WAIT mode (full operation including USB), 1.8mA in STOP mode (full operation but possibly some peripheral response restrictions incl. USB), around 30uA in VLPS but with more peripheral response restrictions (UARTs will lose data at high Bauds).
You should get about 1..2uA in LLS with wakeup to RUN mode from LLWU pin or module (LPTMR, RTC)
and about 2uA in VLLS modes with wakeup from the same sources via reset.
Regards
Mark
Kinetis: µTasker Kinetis support (with out-of-the-box dynamic low power control)
KL26: µTasker Kinetis FRDM-KL26Z support / µTasker Kinetis Teensy LC support
LLWU: µTasker LLWU Support
For the complete "out-of-the-box" Kinetis experience and faster time to market
Hei Mark,
thanks for the helpful answer. I will try to set things manually and report back when I get to it.