Lines Matching refs:alarm
116 alarm = int(rtc.get_seconds() + seconds)
117 logging.debug('Suspend for %d seconds, wakealarm = %d', seconds, alarm)
118 rtc.set_wake_alarm(alarm)
119 return (alarm, wakeup_count)
122 def check_wakeup(alarm): argument
128 if now < alarm:
159 alarm, wakeup_count = prepare_wakeup(suspend_seconds)
165 check_wakeup(alarm)
166 return alarm
199 alarm, wakeup_count = prepare_wakeup(seconds)
208 if e.errno == errno.EBUSY and rtc.get_seconds() >= alarm:
219 check_wakeup(alarm)
231 alarm, _ = prepare_wakeup(seconds)
232 while rtc.get_seconds() < alarm:
243 return alarm
259 alarm, wakeup_count = prepare_wakeup(seconds)
272 check_wakeup(alarm)
273 return alarm