114 lines
2.2 KiB
YAML
114 lines
2.2 KiB
YAML
external_components:
|
|
# LD2410s mmwave sensor
|
|
- source:
|
|
type: git
|
|
url: https://github.com/MrUndead1996/ld2410s-esphome
|
|
ref: main
|
|
components: [ ld2410s ]
|
|
|
|
esphome:
|
|
name: ld2410s-esp32
|
|
friendly_name: ld2410s-esp32
|
|
|
|
esp32:
|
|
board: esp32-s2-saola-1
|
|
framework:
|
|
type: arduino
|
|
|
|
# Enable logging
|
|
logger:
|
|
|
|
# Enable Home Assistant API
|
|
api:
|
|
encryption:
|
|
key: !secret api_encryption_key
|
|
|
|
ota:
|
|
- platform: esphome
|
|
password: !secret ota_password
|
|
|
|
wifi:
|
|
ssid: !secret wifi_ssid
|
|
password: !secret wifi_password
|
|
|
|
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
|
ap:
|
|
ssid: !secret fallback_ap_ssid
|
|
password: !secret fallback_ap_password
|
|
|
|
captive_portal:
|
|
|
|
uart:
|
|
id: uart_bus
|
|
tx_pin: GPIO16
|
|
rx_pin: GPIO17
|
|
baud_rate: 115200
|
|
parity: NONE
|
|
stop_bits: 1
|
|
# debug:
|
|
# direction: BOTH
|
|
# dummy_receiver: false
|
|
# after:
|
|
# delimiter: "\n"
|
|
# sequence:
|
|
# - lambda: UARTDebug::log_hex(direction, bytes, ':');
|
|
|
|
#deep_sleep:
|
|
# wakeup_pin: GPIO15
|
|
# wakeup_pin_mode: KEEP_AWAKE
|
|
|
|
ld2410s:
|
|
uart_id: uart_bus
|
|
|
|
binary_sensor:
|
|
- platform: ld2410s
|
|
has_target:
|
|
name: Presence
|
|
has_threshold_update:
|
|
name: Threshold update running
|
|
|
|
sensor:
|
|
- platform: ld2410s
|
|
target_distance:
|
|
name : Target Distance
|
|
threshold_update:
|
|
name: Threshold update progress
|
|
|
|
number:
|
|
- platform: ld2410s
|
|
max_distance:
|
|
name: Max detect distance
|
|
min_distance:
|
|
name: Min detect distance
|
|
no_delay:
|
|
name: No detect report delay
|
|
status_reporting_frequency:
|
|
name: Status reporting frequency
|
|
distance_reporting_frequency:
|
|
name: Distance reporting frequency
|
|
|
|
button:
|
|
# - platform: template
|
|
# name: Enter sleep mode
|
|
# entity_category: CONFIG
|
|
# on_press:
|
|
# - deep_sleep.enter: {}
|
|
- platform: ld2410s
|
|
enable_config:
|
|
name: Enable config mode
|
|
disable_config:
|
|
name: Disable config mode
|
|
apply_config:
|
|
name: Apply config changes
|
|
auto_threshold:
|
|
name: Start auto threshold update
|
|
|
|
select:
|
|
- platform: ld2410s
|
|
response_speed:
|
|
name: Response speed
|
|
|
|
text_sensor:
|
|
- platform: ld2410s
|
|
fw_version:
|
|
name: Firmware version |