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.

cc2538 sleep timer reset?

Other Parts Discussed in Thread: Z-STACK

i'm wondering if it is possible to reset the timer of the sleep timer, i'd like to reset it so as to keep it from overflowing.

  • This part is take care of Z-Stack and you don't have to worry about it.
  • i am trying to use the sleep timer counter to determine how much time has past in order to implement an RTC. currently we are using PM2 and the sleep timer wakes up the device every 10 minutes to take a data point. i pull the counter value and can determine how much time has past from the start but my concern is when the counter over flows. for example something i do is:

    New counter value/(new couter value - old counter value) = which will give me roughly how much time has past but my concern is when the timer over flows the difference will be negative. i do have a work around for this but id for simplicity of keeping track of "am" and "pm" id like to be able to set it so the counter resets anytime it get larger than a count which would correspond to 12 hrs
  • If I remember correct, there are timer/RTC APIs that you can use directly in osal_timer.c. You can check it first.