7#ifdef USE_BINARY_SENSOR
25#ifdef HYDREON_RGXX_NUM_SENSORS
26static const uint8_t NUM_SENSORS = HYDREON_RGXX_NUM_SENSORS;
28static const uint8_t NUM_SENSORS = 1;
31#ifndef HYDREON_RGXX_PROTOCOL_LIST
32#define HYDREON_RGXX_PROTOCOL_LIST(F, SEP) F("")
35#define HYDREON_RGXX_IGNORE_LIST(F, SEP) F("Emitters") SEP F("Event") SEP F("Reset")
38#ifdef USE_BINARY_SENSOR
39 SUB_BINARY_SENSOR(too_cold)
40 SUB_BINARY_SENSOR(lens_bad)
41 SUB_BINARY_SENSOR(em_sat)
51 void update()
override;
55 void setup()
override;
56 void dump_config()
override;
58 void set_disable_led(
bool disable_led) { this->
disable_led_ = disable_led; }
Collects bytes into NUL terminated lines of up to N - 1 characters; IGNORE_CHAR bytes are skipped and...
This class simplifies creating components that periodically check a state.
StringRef is a reference to a string owned by something else.
int16_t no_response_count_
int num_sensors_missing_()
void process_line_(StringRef line)
line is NUL terminated
bool request_temperature_
LineReader< 80 > line_reader_
void schedule_reboot_()
Communication with the sensor is asynchronous.
RG15Resolution resolution_
sensor::Sensor * sensors_[NUM_SENSORS]
Base-class for all sensors.