ESPHome 2026.1.0-dev
Loading...
Searching...
No Matches
ble_rssi_sensor.h
Go to the documentation of this file.
1#pragma once
2
7
8#ifdef USE_ESP32
9#include <esp_gattc_api.h>
10
11namespace esphome::ble_client {
12
14
16 public:
17 void loop() override;
18 void update() override;
19 void dump_config() override;
20
21 void gap_event_handler(esp_gap_ble_cb_event_t event, esp_ble_gap_cb_param_t *param) override;
22
23 void gattc_event_handler(esp_gattc_cb_event_t event, esp_gatt_if_t gattc_if,
24 esp_ble_gattc_cb_param_t *param) override;
25
26 protected:
27 void get_rssi_();
28 bool should_update_{false};
29};
30
31} // namespace esphome::ble_client
32#endif
This class simplifies creating components that periodically check a state.
Definition component.h:474
void gattc_event_handler(esp_gattc_cb_event_t event, esp_gatt_if_t gattc_if, esp_ble_gattc_cb_param_t *param) override
void gap_event_handler(esp_gap_ble_cb_event_t event, esp_ble_gap_cb_param_t *param) override
Base-class for all sensors.
Definition sensor.h:43