ESPHome 2026.11.0b6
Loading...
Searching...
No Matches
esphome::daikin_madoka Namespace Reference

Data Structures

class  DaikinMadoka
 
class  MessageAssembler
 Reassembles notifications (one chunk id byte followed by payload) into a message. More...
 
struct  Query
 

Typedefs

using QueryArgs = StaticVector<uint8_t, MAX_QUERY_ARGS>
 

Enumerations

enum class  ChunkResult : uint8_t {
  CHUNK_RESULT_PARTIAL , CHUNK_RESULT_COMPLETE , CHUNK_RESULT_INVALID_LENGTH , CHUNK_RESULT_INVALID_ID ,
  CHUNK_RESULT_TOO_LONG
}
 

Functions

 ESPHOME_LOG_TAG (TAG, "daikin_madoka")
 
bool is_valid_message (std::span< const uint8_t > msg)
 True when the length byte matches and the header (length, reserved, function id) is present.
 
uint16_t message_function_id (std::span< const uint8_t > msg)
 
std::span< const uint8_t > find_arg (std::span< const uint8_t > msg, uint8_t id)
 Returns the value of argument id, or an empty span when it is absent, has no value or the records are truncated.
 
bool merge_args (QueryArgs &args, std::span< const uint8_t > incoming)
 Merges the records {id, len, value...} of incoming into args: a record whose id is already present is replaced in place, a new one is appended.
 
void append_setpoint (QueryArgs &args, uint8_t id, float temperature)
 Appends a setpoint record {id, 2, msb, lsb}, clamped to the supported range.
 
float decode_setpoint (std::span< const uint8_t > value)
 Decodes a two byte setpoint value; the caller checks the size.
 

Typedef Documentation

◆ QueryArgs

using esphome::daikin_madoka::QueryArgs = StaticVector<uint8_t, MAX_QUERY_ARGS>

Definition at line 122 of file daikin_madoka_protocol.h.

Enumeration Type Documentation

◆ ChunkResult

enum class esphome::daikin_madoka::ChunkResult : uint8_t
strong
Enumerator
CHUNK_RESULT_PARTIAL 
CHUNK_RESULT_COMPLETE 
CHUNK_RESULT_INVALID_LENGTH 
CHUNK_RESULT_INVALID_ID 
CHUNK_RESULT_TOO_LONG 

Definition at line 32 of file daikin_madoka_protocol.h.

Function Documentation

◆ append_setpoint()

void esphome::daikin_madoka::append_setpoint ( QueryArgs & args,
uint8_t id,
float temperature )
inline

Appends a setpoint record {id, 2, msb, lsb}, clamped to the supported range.

Definition at line 159 of file daikin_madoka_protocol.h.

◆ decode_setpoint()

float esphome::daikin_madoka::decode_setpoint ( std::span< const uint8_t > value)
inline

Decodes a two byte setpoint value; the caller checks the size.

Definition at line 169 of file daikin_madoka_protocol.h.

◆ ESPHOME_LOG_TAG()

esphome::daikin_madoka::ESPHOME_LOG_TAG ( TAG ,
"daikin_madoka"  )

◆ find_arg()

std::span< const uint8_t > esphome::daikin_madoka::find_arg ( std::span< const uint8_t > msg,
uint8_t id )
inline

Returns the value of argument id, or an empty span when it is absent, has no value or the records are truncated.

Definition at line 107 of file daikin_madoka_protocol.h.

◆ is_valid_message()

bool esphome::daikin_madoka::is_valid_message ( std::span< const uint8_t > msg)
inline

True when the length byte matches and the header (length, reserved, function id) is present.

Definition at line 100 of file daikin_madoka_protocol.h.

◆ merge_args()

bool esphome::daikin_madoka::merge_args ( QueryArgs & args,
std::span< const uint8_t > incoming )
inline

Merges the records {id, len, value...} of incoming into args: a record whose id is already present is replaced in place, a new one is appended.

False, with args unchanged, when a record does not fit or the two records of one id differ in length.

Definition at line 127 of file daikin_madoka_protocol.h.

◆ message_function_id()

uint16_t esphome::daikin_madoka::message_function_id ( std::span< const uint8_t > msg)
inline

Definition at line 104 of file daikin_madoka_protocol.h.