alarm.time – Trigger an alarm when the specified time is reached.¶
- class alarm.time.TimeAlarm(monotonic_time: Optional[float] = None, epoch_time: Optional[int] = None)¶
Create an alarm that will be triggered when
monotonic_time, or when
epoch_time. Only one of the two arguments can be given. The alarm is not active until it is passed to an
alarm-enabling function, such as
If the given time is in the past when sleep occurs, the alarm will be triggered immediately.