6 #ifdef USE_BINARY_SENSOR 12 namespace hydreon_rgxx {
24 #ifdef HYDREON_RGXX_NUM_SENSORS 25 static const uint8_t NUM_SENSORS = HYDREON_RGXX_NUM_SENSORS;
27 static const uint8_t NUM_SENSORS = 1;
30 #ifndef HYDREON_RGXX_PROTOCOL_LIST 31 #define HYDREON_RGXX_PROTOCOL_LIST(F, SEP) F("") 34 #define HYDREON_RGXX_IGNORE_LIST(F, SEP) F("Emitters") SEP F("Event") SEP F("Reset") 39 #ifdef USE_BINARY_SENSOR 53 void setup()
override;
68 #ifdef USE_BINARY_SENSOR
float get_setup_priority() const override
void set_disable_led(bool disable_led)
void set_model(RGModel model)
void dump_config() override
void set_resolution(RG15Resolution resolution)
binary_sensor::BinarySensor * too_cold_sensor_
binary_sensor::BinarySensor * lens_bad_sensor_
HydreonRGxxBinaryComponent(HydreonRGxxComponent *parent)
void set_too_cold_sensor(binary_sensor::BinarySensor *sensor)
void setup() override
Setup the sensor and test for a connection.
This class simplifies creating components that periodically check a state.
void schedule_reboot_()
Communication with the sensor is asynchronous.
void set_request_temperature(bool b)
RG15Resolution resolution_
void set_lens_bad_sensor(binary_sensor::BinarySensor *sensor)
int num_sensors_missing_()
void set_sensor(sensor::Sensor *sensor, int index)
void set_em_sat_sensor(binary_sensor::BinarySensor *sensor)
bool request_temperature_
sensor::Sensor * sensors_[NUM_SENSORS]
Implementation of SPI Controller mode.
binary_sensor::BinarySensor * em_sat_sensor_
Base class for all binary_sensor-type classes.
void loop() override
Read data once available.
bool buffer_starts_with_(const std::string &prefix)
Base-class for all sensors.
void update() override
Schedule data readings.
esphome::sensor::Sensor * sensor
int16_t no_response_count_