substitutions:
device_name: "esp32-ld2410b"
esphome:
name: "${device_name}"
# Automatically add the mac address to the name
# so you can use a single firmware for all devices
name_add_mac_suffix: True
esp32:
board: nodemcu-32s
# board: esp32dev
framework:
type: arduino
wifi:
ap: {}
api:
ota:
# Enable logging
logger:
# baud_rate: 0
web_server:
captive_portal:
i2c:
sda: GPIO21
scl: GPIO22
scan: true
id: i2c_bus
uart:
id: uart_bus
tx_pin: GPIO17
rx_pin: GPIO16
baud_rate: 256000 # Change this according to your setting
parity: NONE
stop_bits: 1
ld2410:
uart_id: uart_bus
switch:
- platform: ld2410
bluetooth:
name: "${device_name} BT"
button:
- platform: ld2410
restart:
name: "${device_name} Ld2410 Reboot"
binary_sensor:
- platform: gpio
pin: GPIO33
name: "${device_name} MW"
device_class: motion
# - platform: ld2410
# has_target:
# name: "${device_name} Presence"
# has_moving_target:
# name: "${device_name} Moving Target"
# has_still_target:
# name: "${device_name} Still Target"
# - platform: gpio
# pin: GPIO32
# name: "${device_name} IR"
# device_class: motion
# - platform: status
# name: "${device_name} Online"
sensor:
- platform: bh1750
name: "${device_name} Illuminance"
address: 0x23
update_interval: 15s
# - platform: ld2410
# moving_distance:
# name : "${device_name} Moving Distance"
# still_distance:
# name: "${device_name} Still Distance"
# moving_energy:
# name: "${device_name} Move Energy"
# still_energy:
# name: "${device_name} Still Energy"
# detection_distance:
# name: "${device_name} Detection Distance"
# - platform: internal_temperature
# name: "${device_name} Internal Temperature"
|