ESPHome 2026.3.0-dev
Loading...
Searching...
No Matches
radon_eye_rd200.h
Go to the documentation of this file.
1#pragma once
2
3#ifdef USE_ESP32
4
5#include <esp_gattc_api.h>
6#include <algorithm>
7#include <iterator>
12#include "esphome/core/log.h"
13
14namespace esphome {
15namespace radon_eye_rd200 {
16
18 public:
20
21 void dump_config() override;
22 void update() override;
23
24 void gattc_event_handler(esp_gattc_cb_event_t event, esp_gatt_if_t gattc_if,
25 esp_ble_gattc_cb_param_t *param) override;
26
27 void set_radon(sensor::Sensor *radon) { radon_sensor_ = radon; }
28 void set_radon_long_term(sensor::Sensor *radon_long_term) { radon_long_term_sensor_ = radon_long_term; }
29
30 protected:
31 void read_sensors_(uint8_t *value, uint16_t value_len);
32
35
37 uint16_t read_handle_;
38 uint16_t write_handle_;
42};
43
44} // namespace radon_eye_rd200
45} // namespace esphome
46
47#endif // USE_ESP32
This class simplifies creating components that periodically check a state.
Definition component.h:527
void read_sensors_(uint8_t *value, uint16_t value_len)
void set_radon_long_term(sensor::Sensor *radon_long_term)
esp32_ble_tracker::ESPBTUUID sensors_write_characteristic_uuid_
esp32_ble_tracker::ESPBTUUID service_uuid_
esp32_ble_tracker::ESPBTUUID sensors_read_characteristic_uuid_
void set_radon(sensor::Sensor *radon)
void gattc_event_handler(esp_gattc_cb_event_t event, esp_gatt_if_t gattc_if, esp_ble_gattc_cb_param_t *param) override
Base-class for all sensors.
Definition sensor.h:47
Providing packet encoding functions for exchanging data with a remote host.
Definition a01nyub.cpp:7