smartledz-protocol
Smart LEDZ protocol v1 command and state codec library
Loading...
Searching...
No Matches
smartledz_protocol::v1::DeviceStateSnapshot Struct Reference

Last known state fields decoded from mesh notifications. More...

#include <state_codec.h>

Public Attributes

bool seen {false}
 True after at least one payload was applied for this address.
 
uint8_t online_status {0}
 Raw online status byte from 0xDC online-status payloads.
 
bool has_online_brightness {false}
 True when online_brightness is valid.
 
uint8_t online_brightness {0}
 Brightness byte from online-status payload.
 
bool has_power {false}
 True when power has been derived from a payload.
 
bool power {false}
 Derived power state (status != 0 && brightness != 0).
 
bool has_brightness {false}
 True when brightness has been decoded from any payload type.
 
uint8_t brightness {0}
 Brightness byte from dimming/online payloads.
 
uint8_t type_raw {0}
 Device type/raw mode byte seen in online-status payloads.
 
bool has_ct {false}
 True when ct_raw is valid.
 
uint8_t ct_raw {0}
 Raw CT byte (18..65 in currently known payloads).
 
bool has_rgb {false}
 True when rgb is valid.
 
std::array< uint8_t, 3 > rgb {0, 0, 0}
 RGB channels decoded from status payload.
 
uint32_t last_update_ms {0}
 Caller-provided timestamp for latest decoded update.
 

Detailed Description

Last known state fields decoded from mesh notifications.


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