AceTime  0.1
Date and time classes for Arduino that supports the TZ DAtabase, and a system clock synchronized from an NTP server or an RTC chip.
Public Member Functions | List of all members
ace_time::provider::SystemTimeHeartbeatCoroutine Class Reference

A coroutine that calls SystemTimeKeeper.getNow() peridically. More...

#include <SystemTimeHeartbeatCoroutine.h>

Inheritance diagram for ace_time::provider::SystemTimeHeartbeatCoroutine:
Inheritance graph
[legend]
Collaboration diagram for ace_time::provider::SystemTimeHeartbeatCoroutine:
Collaboration graph
[legend]

Public Member Functions

 SystemTimeHeartbeatCoroutine (SystemTimeKeeper &systemTimeKeeper, uint16_t heartbeatPeriodMillis=5000)
 Constructor. More...
 
int runCoroutine () override
 

Detailed Description

A coroutine that calls SystemTimeKeeper.getNow() peridically.

This must be performed before the uint16_t timer in SystemTimeKeeper overflows, i.e. every 65535 milliseconds at a minimum. I recommend every 5000 millis, which is the default.

Definition at line 16 of file SystemTimeHeartbeatCoroutine.h.

Constructor & Destructor Documentation

ace_time::provider::SystemTimeHeartbeatCoroutine::SystemTimeHeartbeatCoroutine ( SystemTimeKeeper systemTimeKeeper,
uint16_t  heartbeatPeriodMillis = 5000 
)
inline

Constructor.

Parameters
systemTimeKeeperthe underlying SystemTimeKeeper
heartbeatPeriodMillismilliseconds between calls to getNow() (default 5000)

Definition at line 25 of file SystemTimeHeartbeatCoroutine.h.


The documentation for this class was generated from the following file: