GenericOnOffServer

Generic OnOff Server for a local mesh element.

Represents a binary-state device on the mesh network. The server maintains the current on/off state and handles incoming GET/SET messages from remote clients.

Properties

Link copied to clipboard
val state: StateFlow<Boolean>

Current on/off state.

Functions

Link copied to clipboard
suspend fun setState(on: Boolean)

Set the state locally (e.g., from a physical switch).