Hi,
I'm using vAHI_Sleep(E_AHI_SLEEP_OSCON_RAMON) to get JN5189 to go into sleep for x Seconds. The sleep and wake seems to work well. However, upon wake the application variables seem to have gone back to the cold start initialized value and not retained, despite the 'RAMON' option.
Are there other configurations needed prior to sleep or after wakeup to retain the application variable values?
Thanks
Kuan
Solved! Go to Solution.
Having looked at the Zigbee 3.0 Sensors AN-1246, I've decided to still use the easier vAHI_Sleep() for simple sleep-wake cycle testing, instead of the PWRM method used in the application reference.
Found that my earlier problem with vAHI_Sleep() was not declaring a WarmStart() function as required in startup.c. The consequence, i guess, was that each wake from sleep was treated like a 'cold start' instead of a 'warm start'?
In any case, this issue is now resolved. Thanks.
Having looked at the Zigbee 3.0 Sensors AN-1246, I've decided to still use the easier vAHI_Sleep() for simple sleep-wake cycle testing, instead of the PWRM method used in the application reference.
Found that my earlier problem with vAHI_Sleep() was not declaring a WarmStart() function as required in startup.c. The consequence, i guess, was that each wake from sleep was treated like a 'cold start' instead of a 'warm start'?
In any case, this issue is now resolved. Thanks.
Hello,
Hope you are doing well. I would recommend checking this Application Note: Zigbee 3.0 Sensors.
Please refer to the Occupancy Sensor example. The Occupancy Sensor is a sleeping End Device and will, by default, attempt to sleep with RAM held and the 32kHz oscillator on.
Regards,
Ricardo