This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Correct way to handle ISRs for a Sleepy End Device.

Other Parts Discussed in Thread: CC2530, Z-STACK

I have a battery powered End Device application that must spend most of it's time in DEEP_SLEEP as per the application note SWRA248 Power Magement for the CC2530. Currently this works very well and the device is performs very well on battery usage, by spending most of the time in DEEP_SLEEP.

However part of the application needs to handle occasional (they occur at random intervals they are not periodic) interrupts on a GPIO pin (P0_6) to collect information.

Right now when the ISR exits, the CC2530 does not return to sleep

I could possibly force the CC2530 to sleep at the end of the ISR, but I'm concerned that the interrupt could occur during the regular timed wake-ups for Z-Stack.The ISR could occur when the CC2530 is in DEEP_SLEEP or when it is awake. It does not seem to me to be a good idea to interrupt normal Z-Stack processing and force the MPU to sleep.

What is the correct way to handle an ISR that may asynchronously interrupt the CC2530 in a way that will not interfere with the normal Z-Stack timer based processing?

+ Chris