19#ifndef H_ESP32_E12_SPEC
20#define H_ESP32_E12_SPEC
60 virtual int begin(
void* bus, uint8_t e12_addr = 0);
102 virtual int log(uint8_t type, uint8_t status, uint32_t ts,
void* data);
112 virtual int on_config(
const char* s,
int len);
152 virtual int sleep(uint32_t ms,
void* data);
This class represents an ESP32 node for the e12 protocol.
Definition esp32_e12_node_protocol.h:35
virtual int set_node_auth_credentials(e12_auth_data_t *auth)
Sets the authentication credentials for the node.
Definition esp32_e12_node_protocol.cpp:143
virtual uint32_t get_time_ms()
Gets the current time in milliseconds.
Definition esp32_e12_node_protocol.cpp:60
~e12_esp32_node()
Destructor for the e12_esp32_node class.
Definition esp32_e12_node_protocol.cpp:40
virtual e12_packet_t * read()
Reads a packet from the e12 node.
Definition esp32_e12_node_protocol.cpp:208
virtual int on_config(const char *s, int len)
Configures the node with the given settings.
Definition esp32_e12_node_protocol.cpp:181
virtual int send(e12_packet_t *buf, bool retry=true)
Sends a packet to the e12 node.
Definition esp32_e12_node_protocol.cpp:75
virtual int begin(void *bus, uint8_t e12_addr=0)
Initializes the node with the given bus and address.
Definition esp32_e12_node_protocol.cpp:49
virtual int on_get_state(char *s, int len, void *ctx)
Gets the current state of the node.
Definition esp32_e12_node_protocol.cpp:110
virtual int log(uint8_t type, uint8_t status, uint32_t ts, void *data)
Logs an event.
Definition esp32_e12_node_protocol.cpp:169
virtual int sleep(uint32_t ms, void *data)
Puts the node to sleep for the specified duration.
Definition esp32_e12_node_protocol.cpp:155
virtual int on_restore_state(const char *s, int len)
Restores the state of the node from the given string.
Definition esp32_e12_node_protocol.cpp:122
virtual int print_buffer(e12_onwire_t *buf)
Prints the contents of the buffer.
Definition esp32_e12_node_protocol.cpp:193
virtual int on_wakeup()
Wakes up the node.
Definition esp32_e12_node_protocol.cpp:132
virtual e12_log_evt_t * get_log_evt()
Gets the log event.
Definition esp32_e12_node_protocol.cpp:100
This class represents the base class for the e12 protocol.
Definition e12_protocol.h:403
e12_auth_data_t
Definition e12_protocol.h:225
e12_onwire_t
Definition e12_protocol.h:371
e12_log_evt_t
Definition e12_protocol.h:174
e12_packet_t
Definition e12_protocol.h:357