Files
hassos_config/esphome/bt-proxy-woonkamer.yaml
willem bdbeec27aa Update devices.yaml and state.json with new device configurations and states
- Refactored friendly names in devices.yaml for consistency and clarity.
- Added new devices and updated existing ones in devices.yaml.
- Populated state.json with detailed state information for various devices, including brightness, power, and link quality.
- Included update information for devices where applicable.
2026-04-03 00:39:43 +02:00

62 lines
1.8 KiB
YAML

substitutions:
device_name: "btproxywoonkamer"
friendly_name: "BT_proxy_woonkamer"
comment: "ESP32-c3 BTproxy"
location: "woonkamer"
board: "esp32-c3-devkitm-1"
framework: esp-idf
api_password: !secret bt_proxy_keuken_api
ota_password: !secret ota_password
wifi_ssid: !secret wifi_ssid
wifi_password: !secret wifi_password
pin_status: GPIO8
packages:
board: !include boards/esp32-gen.yaml
connection: !include common/wifi.yaml
device_base: !include common/common.yaml
logger: !include templates/logger.yaml
btproxy: !include templates/bt_proxy.yaml
# esp32_ble_tracker:
# on_ble_advertise:
# then:
# - lambda: |-
# ESP_LOGD("BLE", "MAC: %s | RSSI: %d", x.address_str().c_str(), x.get_rssi());
sensor:
- platform: xiaomi_hhccjcy01
mac_address: "5C:85:7E:13:17:A3"
temperature:
name: "Xiaomi MiFlora Temperature"
moisture:
name: "Xiaomi MiFlora Moisture"
illuminance:
name: "Xiaomi MiFlora Illuminance"
conductivity:
name: "Xiaomi MiFlora Soil Conductivity"
battery_level:
name: "Xiaomi MiFlora Battery Level"
esp32_ble_tracker:
on_ble_advertise:
then:
- lambda: |-
// MAC-adres als string
std::string mac = x.address_str();
// RSSI ophalen via getter
int rssi = x.get_rssi();
// Naam ophalen, lege string als onbekend
std::string name = x.get_name(); // geen has_value(), gewoon std::string
// Filter: Xiaomi MAC-prefixes of Flowercare naam
if (mac.rfind("A4:C1:38", 0) == 0 ||
mac.rfind("62:26:28", 0) == 0 ||
mac.rfind("4C:65:A8", 0) == 0 ||
name.find("Flower") != std::string::npos) {
ESP_LOGD("xiaomi_logger", "Xiaomi device found: %s (%s), RSSI: %d", mac.c_str(), name.c_str(), rssi);
}