I am working on these ideas, hope they are right.
0. Check if device can sleep (several checks: is MAC idle, is modem inactive, etc.)
BTW: why MAC is never IDLE (without resetting it?)
1. Change clock mode, use ICG@125khz, in self clock mode.
PWRLib_ClockSetup(SelfClk_125kHz);
2. Turn off the Modem
PWRLib_RadioOnReq();
3. Wait some time
4. Turn on the Modem
PWRLib_RadioOnReq();
5. Restore external clock
PWRLib_ClockSetup(Normal_16MHz);
Is this ok?
Thanks for any help.
Problems i find:
1) MAC is never IDLE if i don't reset it. Why?
2) Should I initialize the MODEM after i turn it on again?
3) Should I initialize the MAC and/or reset it after I turn on the MODEM again?
4) Where can i find docs about PWRLIB etc? I found only a small pdf which says not much.
5) Why the MAC/PHY stops beaconing?