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

#include <board.h>

Public Member Functions

virtual ~Board ()=default
 
virtual Result< void > init ()=0
 
virtual const char * getName () const =0
 
virtual const DeviceInfo & getDeviceInfo () const =0
 
virtual const BoardConfig & getConfig () const =0
 
virtual const Pins & getPins () const =0
 
const BoardCapabilities & capabilities () const
 Return the capability set declared by this board.
 
virtual hal::IDisplay & getDisplay ()=0
 Return the generic display implementation selected by this BSP.
 
virtual hal::IRtc & getRtc ()=0
 Return the RTC implementation selected by this BSP.
 
virtual hal::IBattery & getBattery ()=0
 Return the battery implementation selected by this BSP.
 
virtual hal::IInput & getInput ()=0
 Return the normalized input implementation selected by this BSP.
 
virtual hal::IBluetooth & getBluetooth ()=0
 Return the BLE transport selected by this BSP.
 
virtual hal::ICompanionSource & getCompanionSource ()=0
 Return the companion-data provider selected by this BSP.
 
virtual hal::IWifiRadio & getWifi ()=0
 Return the Wi-Fi radio selected by this BSP.
 
virtual hal::IPowerManagement & getPowerManagement ()=0
 Return the platform power-management implementation selected by this BSP.
 
virtual hal::IConsole & getConsole ()=0
 Return the platform debug/control console selected by this BSP.
 
virtual hal::IHttpServer & getHttpServer ()=0
 Return the board's local HTTP server adapter used by captive apps.
 
virtual hal::IDnsServer & getDnsServer ()=0
 Return the board's captive DNS responder adapter.
 
virtual hal::IHttpClient & getHttpClient ()=0
 Return platform HTTP transport for portable sync and provisioning services.
 
virtual hal::INtpTimeSource & getNtpTimeSource ()=0
 Return the platform NTP synchronization adapter.
 
virtual hal::IPlatformDiagnostics & getDiagnostics ()=0
 Return reset, memory, and CPU readings through the platform diagnostics HAL.
 
virtual uint32_t getUptimeMs () const =0
 
virtual void delayMs (uint32_t ms)=0
 
virtual void restart ()=0
 

Static Public Member Functions

static Board & current ()
 
static Board * currentOrNull ()
 

Detailed Description

Composition contract for one selected board support package.

A BSP owns concrete driver instances and exposes them through generic HAL references. Firmware services depend on this contract instead of naming a specific watch or panel, allowing another board composition to replace the current one without changing application/service code. Returned references are borrowed and remain valid for the lifetime of the board object.

Constructor & Destructor Documentation

◆ ~Board()

virtual ersa::board::Board::~Board ( )
virtualdefault

Member Function Documentation

◆ capabilities()

const BoardCapabilities & ersa::board::Board::capabilities ( ) const
inline

Return the capability set declared by this board.

◆ current()

Board & ersa::board::Board::current ( )
static

Return the build-selected board before initialization. Kconfig chooses the composition at compile time, avoiding a runtime factory and keeping invalid board/firmware combinations unrepresentable.

◆ currentOrNull()

Board * ersa::board::Board::currentOrNull ( )
static

Return the selected board when one is installed, or null when host tests deliberately build without an embedded BSP provider.

◆ delayMs()

virtual void ersa::board::Board::delayMs ( uint32_t  ms)
pure virtual

Delay the caller task; do not use this for UI-loop waits on long I/O.

◆ getBattery()

virtual hal::IBattery & ersa::board::Board::getBattery ( )
pure virtual

Return the battery implementation selected by this BSP.

◆ getBluetooth()

virtual hal::IBluetooth & ersa::board::Board::getBluetooth ( )
pure virtual

Return the BLE transport selected by this BSP.

◆ getCompanionSource()

virtual hal::ICompanionSource & ersa::board::Board::getCompanionSource ( )
pure virtual

Return the companion-data provider selected by this BSP.

◆ getConfig()

virtual const BoardConfig & ersa::board::Board::getConfig ( ) const
pure virtual

Return immutable capabilities and geometry used by generic policy.

◆ getConsole()

virtual hal::IConsole & ersa::board::Board::getConsole ( )
pure virtual

Return the platform debug/control console selected by this BSP.

◆ getDeviceInfo()

virtual const DeviceInfo & ersa::board::Board::getDeviceInfo ( ) const
pure virtual

Return static manufacturer/platform/product identity for diagnostics.

◆ getDiagnostics()

virtual hal::IPlatformDiagnostics & ersa::board::Board::getDiagnostics ( )
pure virtual

Return reset, memory, and CPU readings through the platform diagnostics HAL.

◆ getDisplay()

virtual hal::IDisplay & ersa::board::Board::getDisplay ( )
pure virtual

Return the generic display implementation selected by this BSP.

◆ getDnsServer()

virtual hal::IDnsServer & ersa::board::Board::getDnsServer ( )
pure virtual

Return the board's captive DNS responder adapter.

◆ getHttpClient()

virtual hal::IHttpClient & ersa::board::Board::getHttpClient ( )
pure virtual

Return platform HTTP transport for portable sync and provisioning services.

◆ getHttpServer()

virtual hal::IHttpServer & ersa::board::Board::getHttpServer ( )
pure virtual

Return the board's local HTTP server adapter used by captive apps.

◆ getInput()

virtual hal::IInput & ersa::board::Board::getInput ( )
pure virtual

Return the normalized input implementation selected by this BSP.

◆ getName()

virtual const char * ersa::board::Board::getName ( ) const
pure virtual

Return the stable user-facing product label.

◆ getNtpTimeSource()

virtual hal::INtpTimeSource & ersa::board::Board::getNtpTimeSource ( )
pure virtual

Return the platform NTP synchronization adapter.

◆ getPins()

virtual const Pins & ersa::board::Board::getPins ( ) const
pure virtual

Return the logical pin contract used by pinctrl and peripheral setup.

◆ getPowerManagement()

virtual hal::IPowerManagement & ersa::board::Board::getPowerManagement ( )
pure virtual

Return the platform power-management implementation selected by this BSP.

◆ getRtc()

virtual hal::IRtc & ersa::board::Board::getRtc ( )
pure virtual

Return the RTC implementation selected by this BSP.

◆ getUptimeMs()

virtual uint32_t ersa::board::Board::getUptimeMs ( ) const
pure virtual

Return monotonic milliseconds; values wrap according to uint32_t uptime.

◆ getWifi()

virtual hal::IWifiRadio & ersa::board::Board::getWifi ( )
pure virtual

Return the Wi-Fi radio selected by this BSP.

◆ init()

virtual Result< void > ersa::board::Board::init ( )
pure virtual

Configure pinctrl, buses, and board-owned resources before service init.

◆ restart()

virtual void ersa::board::Board::restart ( )
pure virtual

Request a platform restart, normally used for reset or OTA handoff.


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