(`datasheet and user manual <https://drive.google.com/drive/folders/1p4dhbEJA3YubyIjIIC7wwVsSo8x29Fq-?spm=a2g0o.detail.1000023.17.93465697yFwVxH>`__) with ESPHome.
The :ref:`UART <uart>` is required to be set up in your configuration for this sensor to work, ``parity`` and ``stop_bits``**must be** respectively ``NONE`` and ``1``.
-**uart_id** (*Optional*, :ref:`config-id`): Manually specify the ID of the :ref:`UART Component <uart>` if you want
to use multiple UART buses.
-**throttle** (*Optional*, int): Time in milliseconds to control the rate of data updates. Defaults to ``1000ms``.
-**id** (*Optional*, :ref:`config-id`): Manually specify the ID for this :doc:`ld2410` component if you need multiple components.
Binary Sensor
-------------
The ``ld2410`` binary sensor allows you to use your :doc:`ld2410` to perform different
measurements.
..code-block:: yaml
binary_sensor:
- platform: ld2410
has_target:
name: Presence
has_moving_target:
name: Moving Target
has_still_target:
name: Still Target
out_pin_presence_status:
name: out pin presence status
Configuration variables:
************************
-**has_target** (*Optional*): If true target detect either still or in movement.
All options from :ref:`Binary Sensor <config-binary_sensor>`.
-**has_moving_target** (*Optional*): If true a moving target is detected.
All options from :ref:`Binary Sensor <config-binary_sensor>`.
-**has_still_target** (*Optional*): If true a still target is detected.
All options from :ref:`Binary Sensor <config-binary_sensor>`.
-**out_pin_presence_status** (*Optional*): When in :ref:`engineering mode<ld2410-engineering-mode>`, indicates whether the OUT pin indicates presence or not, otherwise ``false``.
OUT pin indication depends on the :ref:`light function<ld2410-light-function>` configuration. Might need latest firmware to work.
All options from :ref:`Binary Sensor <config-binary_sensor>`.
-**ld2410_id** (*Optional*, :ref:`config-id`): Manually specify the ID for the :doc:`ld2410` component if you are using multiple components.
Sensor
------
The ``ld2410`` sensor allows you to use your :doc:`ld2410` to perform different
measurements.
..code-block:: yaml
sensor:
- platform: ld2410
light:
name: light
moving_distance:
name : Moving Distance
still_distance:
name: Still Distance
moving_energy:
name: Move Energy
still_energy:
name: Still Energy
detection_distance:
name: Detection Distance
g0:
move_energy:
name: g0 move energy
still_energy:
name: g0 still energy
g1:
move_energy:
name: g1 move energy
still_energy:
name: g1 still energy
g2:
move_energy:
name: g2 move energy
still_energy:
name: g2 still energy
g3:
move_energy:
name: g3 move energy
still_energy:
name: g3 still energy
g4:
move_energy:
name: g4 move energy
still_energy:
name: g4 still energy
g5:
move_energy:
name: g5 move energy
still_energy:
name: g5 still energy
g6:
move_energy:
name: g6 move energy
still_energy:
name: g6 still energy
g7:
move_energy:
name: g7 move energy
still_energy:
name: g7 still energy
g8:
move_energy:
name: g8 move energy
still_energy:
name: g8 still energy
.._ld2410-sensors:
Configuration variables:
************************
-**light** (*Optional*, int): When in :ref:`engineering mode<ld2410-engineering-mode>`, indicates the light sensitivity, otherwise ``unknown``.
Value between ``0`` and ``255`` inclusive. Though it seems that the value ``85`` is the lowest value at complete darkness.
All options from :ref:`Sensor <config-sensor>`.
-**moving_distance** (*Optional*, int): Distance in cm of detected moving target.
All options from :ref:`Sensor <config-sensor>`.
-**still_distance** (*Optional*, int): Distance in cm of detected still target.
All options from :ref:`Sensor <config-sensor>`.
-**moving_energy** (*Optional*, int): Energy for moving target.
Value between ``0`` and ``100`` inclusive.
All options from :ref:`Sensor <config-sensor>`.
-**still_energy** (*Optional*, int): Energy for still target.
Value between ``0`` and ``100`` inclusive.
All options from :ref:`Sensor <config-sensor>`.
-**detection_distance** (*Optional*, int): Distance in cm of target.
All options from :ref:`Sensor <config-sensor>`.
-**gX** (*Optional*): Energies for the Xth gate (X => 0 to 8).
-**distance_resolution** (*Optional*): Control the gates distance resolution. Can be ``0.75m`` or ``0.2m``. Defaults to ``0.75m``.
All options from :ref:`Select <config-select>`.
-**baud_rate** (*Optional*): Control the serial port baud rate. Defaults to ``256000``.
Once changed, all sensors will stop working until a fresh install with an updated :ref:`UART Component <uart>` configuration.
All options from :ref:`Select <config-select>`.
-**light_function** (*Optional*): If set, will affect the OUT pin value, based on :ref:`light threshold<ld2410-light-threshold>`. Can be ``off``, ``low`` or ``above``. Defaults to ``off``.
All options from :ref:`Select <config-select>`.
-**out_pin_level** (*Optional*): Control OUT pin ``away`` value. Can be ``low`` or ``high``. Defaults to ``low``.
All options from :ref:`Select <config-select>`.
-**ld2410_id** (*Optional*, :ref:`config-id`): Manually specify the ID for the :doc:`ld2410` component if you are using multiple components.
Automations
-----------
``bluetooth_password.set`` Action
*********************************
This is an :ref:`Action <config-action>` for setting the bluetooth password.
..code-block:: yaml
- bluetooth_password.set:
id: my_ld2410
password: "HiLink"
Configuration variables:
-**id** (**Required**, :ref:`config-id`): The ID of the :doc:`ld2410` component to set.