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

Functions

template<typename T , size_t N>
optional< size_t > find_index (const T(&arr)[N], T value)
 
const char * format_mac_str (const uint8_t *mac_address, std::span< char, MAC_ADDRESS_PRETTY_BUFFER_SIZE > buffer)
 
bool store_mac (const uint8_t *reported, uint8_t *mac_address)
 
void format_version_str (const uint8_t *version, std::span< char, 20 > buffer)
 
bool validate_header_footer (const uint8_t *header_footer, const uint8_t *buffer)
 
uint32_t cmd_frame_length (const uint8_t *buffer, uint8_t count)
 
uint8_t drop_to_next_header (uint8_t *buffer, uint8_t count, uint8_t from, const uint8_t *data_header)
 
template<size_t N, typename LengthFn , typename HandleFn , typename DropFn >
void feed_frame_byte (uint8_t(&buffer)[N], uint8_t &pos, uint8_t byte, const uint8_t *data_header, LengthFn frame_length, HandleFn handle_frame, DropFn on_drop)
 

Function Documentation

◆ cmd_frame_length()

uint32_t esphome::ld24xx::cmd_frame_length ( const uint8_t * buffer,
uint8_t count )
inline

Definition at line 92 of file ld24xx.h.

◆ drop_to_next_header()

uint8_t esphome::ld24xx::drop_to_next_header ( uint8_t * buffer,
uint8_t count,
uint8_t from,
const uint8_t * data_header )
inline

Definition at line 100 of file ld24xx.h.

◆ feed_frame_byte()

template<size_t N, typename LengthFn , typename HandleFn , typename DropFn >
void esphome::ld24xx::feed_frame_byte ( uint8_t(&) buffer[N],
uint8_t & pos,
uint8_t byte,
const uint8_t * data_header,
LengthFn frame_length,
HandleFn handle_frame,
DropFn on_drop )

Definition at line 116 of file ld24xx.h.

◆ find_index()

template<typename T , size_t N>
optional< size_t > esphome::ld24xx::find_index ( const T(&) arr[N],
T value )

Definition at line 27 of file ld24xx.h.

◆ format_mac_str()

const char * esphome::ld24xx::format_mac_str ( const uint8_t * mac_address,
std::span< char, MAC_ADDRESS_PRETTY_BUFFER_SIZE > buffer )
inline

Definition at line 43 of file ld24xx.h.

◆ format_version_str()

void esphome::ld24xx::format_version_str ( const uint8_t * version,
std::span< char, 20 > buffer )
inline

Definition at line 77 of file ld24xx.h.

◆ store_mac()

bool esphome::ld24xx::store_mac ( const uint8_t * reported,
uint8_t * mac_address )
inline

Definition at line 64 of file ld24xx.h.

◆ validate_header_footer()

bool esphome::ld24xx::validate_header_footer ( const uint8_t * header_footer,
const uint8_t * buffer )
inline

Definition at line 87 of file ld24xx.h.