Ersa Wearable Platform
Embedded smartwatch firmware and application framework
Loading...
Searching...
No Matches
Public Member Functions | List of all members
ersa::hal::IRtc Class Referenceabstract

#include <rtc.h>

Inheritance diagram for ersa::hal::IRtc:
Inheritance graph
[legend]

Public Member Functions

virtual ~IRtc ()=default
 
virtual Result< void > init ()=0
 
virtual TimePoint now ()=0
 
virtual Result< void > adjust (const TimePoint &time)=0
 
virtual Result< void > setEpoch (uint32_t epochSeconds)=0
 
virtual bool isHealthy () const =0
 
virtual RtcDiagnostics diagnostics ()
 
virtual void resync ()
 

Detailed Description

Real-time clock contract using transport-neutral calendar values.

Constructor & Destructor Documentation

◆ ~IRtc()

virtual ersa::hal::IRtc::~IRtc ( )
virtualdefault

Member Function Documentation

◆ adjust()

virtual Result< void > ersa::hal::IRtc::adjust ( const TimePoint &  time)
pure virtual

Write explicit calendar fields and report bus/chip failures.

Implemented in ersa::test::MockRtc.

◆ diagnostics()

virtual RtcDiagnostics ersa::hal::IRtc::diagnostics ( )
inlinevirtual

Return best-effort chip status; generic implementations report current time only.

◆ init()

virtual Result< void > ersa::hal::IRtc::init ( )
pure virtual

Initialize the chip/bus and verify that calendar reads are plausible.

Implemented in ersa::test::MockRtc.

◆ isHealthy()

virtual bool ersa::hal::IRtc::isHealthy ( ) const
pure virtual

Report backend health; this does not guarantee the wall time is accurate.

Implemented in ersa::test::MockRtc.

◆ now()

virtual TimePoint ersa::hal::IRtc::now ( )
pure virtual

Return a calendar snapshot; the implementation may derive epoch fields.

Implemented in ersa::test::MockRtc.

◆ resync()

virtual void ersa::hal::IRtc::resync ( )
inlinevirtual

Force reconciliation with hardware after a wake where uptime paused.

◆ setEpoch()

virtual Result< void > ersa::hal::IRtc::setEpoch ( uint32_t  epochSeconds)
pure virtual

Convert and write epoch seconds without exposing a chip-specific date type.

Implemented in ersa::test::MockRtc.


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