esp32_ble_tracker:
  id: ble_tracker_hub

sensor:
  # Explicit ble_hub_id: pins the neutral binding as a declared key.
  - platform: xiaomi_cgdk2
    ble_hub_id: ble_tracker_hub
    mac_address: A4:C1:38:D1:61:7D
    bindkey: c99d2313182473b38001086febf781bd
    temperature:
      name: Xiaomi CGDK2 Temperature
    humidity:
      name: Xiaomi CGDK2 Humidity
    battery_level:
      name: Xiaomi CGDK2 Battery Level
