Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
10 years, 6 months ago.
how to put the KL25z in deepsleep
I am new to KL25Z, will this program put KL25Z in low power mood.
thanks,
- include "mbed.h" int main () {
deepsleep();
}
1 Answer
10 years, 6 months ago.
Yes. Two things to take in to account:
First, it will put the KL25 in a very low power mode, something like 3uA current consumption. However it doesn't do anything with the power consumption of everything else on the KL25Z board, so it is most useful on a custom PCB, or making really sure what is being powered on the default board.
Second: When powered via the SDA USB connector the KL25 is put into a debug mode, there it cannot properly enter deepsleep. To get it there you need a full power cycle, but not via that SDA connector. You can either use the other USB connector, or a jumper can be soldered on the board which can interrupt the power supply of the KL25 (and can also be used to measure current consumption).
I have a custom PCB with a KL25Z on it. I want to put it in deep sleep when other MCU are busy. I have reset, swd_clk and swd_dio wired out. could you please drop few sentences about how to use KL25Z to program this custom board. or just point to a link of the Freescale document. appreciate your help. David
posted by 29 Apr 2014I have never done it, this guy has: https://mbed.org/cookbook/Prototype-To-Hardware-KL25Z. But in principle you connect those to the pins on the KL25Z (there is a header which has them), and you need to make sure the KL25 on there isn't active. You can place a jumper on the KL25 board and cut a trace, so you can disconnect the swd_clk line to the onboard KL25.
posted by 29 Apr 2014