Ersa Wearable Platform
Embedded smartwatch firmware and application framework
Loading...
Searching...
No Matches
Static Public Member Functions | List of all members
ersa::services::SessionStats Class Reference

#include <session_stats.h>

Static Public Member Functions

static void begin ()
 
static void tick (uint32_t uptimeMs)
 
static uint32_t previousSessionUptimeSeconds ()
 

Detailed Description

Tracks uptime across boots using a small persistent session record. The service stores checkpoints rather than writing flash every UI tick, so callers can report the previous session while limiting flash wear.

Member Function Documentation

◆ begin()

void ersa::services::SessionStats::begin ( )
static

Load prior-session metadata and start the current uptime counter.

◆ previousSessionUptimeSeconds()

uint32_t ersa::services::SessionStats::previousSessionUptimeSeconds ( )
static

Return the last persisted uptime, in seconds, from the previous boot.

◆ tick()

void ersa::services::SessionStats::tick ( uint32_t  uptimeMs)
static

Persist a checkpoint only when the configured reporting interval elapsed.


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