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.
6 years, 7 months ago.
Sleep Manager API Method Location in code.
Hi I'm using ST Nucleo board nowadays. I wonder which one is best way to use sleep method.
sleep method before while statement
#include "mbed.h" void main(void){ sleep(); while(true){ } }
sleep method before while statement
#include "mbed.h" void main(void){ while(true){ sleep(); } }
References
- https://os.mbed.com/docs/v5.8/reference/power-management.html
- https://os.mbed.com/docs/v5.8/reference/deepsleeplock.html