• Models
  • Contests
  • Slicer
  • Login
  • Start Here
    thingiverse-iconprintables-iconcults3d-iconmakerworld-iconmyminifactory-icon

    3D GO

    3D ModelsContestsCollectionsSaved ModelsOn a mobile device?

3D GO

Privacy Policy
ESP32 Relay Board with LD2450 3D Printer File Image 1
ESP32 Relay Board with LD2450 3D Printer File Image 2
ESP32 Relay Board with LD2450 3D Printer File Thumbnail 1
ESP32 Relay Board with LD2450 3D Printer File Thumbnail 2

ESP32 Relay Board with LD2450

Mawoka avatarMawoka

May 1, 2025

printables-icon
DescriptionCommentsTags

Description

I had a PIR movement sensor in the basement controlling the light, but it sucked pretty bad and I had an LD2450 mmWave sensor lying around. I also found the relay board relatively cheap and just combined both things in a compact(ish) case.

 

BOM

  • The Relay board (AC90-250 variant)
  • The LD2450 (select it and not a cable or so)
  • Some short cables
  • (A Serial to USB converter)

 

Preparation

Connect the LD2450 to the relay board. Use 5v as the power supply and choose any of the GPIO pins to connect with the RX and TX pins from the sensor. Soldering the serial header on also makes sense to flash the esp with ESPhome for initial setup.

 

The Case

Print the 2 parts how you want, but I'd recommend to face the vent holes up. The sensor can be slid into the lid.

 

Software

esphome:
  name: device_name
  friendly_name: DeviceName

esp32:
  board: esp32dev
  framework:
    type: arduino

# Enable logging
logger:

# Enable Home Assistant API
api:
  encryption:
    key: "SOMETHING"

ota:
  - platform: esphome
    password: "SOMETHING"

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "DeviceName Fallback Hotspot"
    password: "SOMETHING"

captive_portal:
    

uart:
  - baud_rate: 256000
    rx_pin: GPIO32 # Adjust these pins (RX on ESP to TX on sensor)
    tx_pin: GPIO25 # Adjust these pins (TX on ESP to RX on sensor)
    parity: NONE
    stop_bits: 1
ld2450:
  - id: radar
    throttle: 500ms
binary_sensor:
  - platform: ld2450
    ld2450_id: radar
    has_target:
      id: has_target
      name: Presence
    has_moving_target:
      name: Moving Target
    has_still_target:
      name: Still Target
  - platform: copy
    source_id: has_target
    id: light_on
    filters: 
      - delayed_off: 0s # Adjust here for off delay
    on_press: 
      then:
        - switch.turn_on: light_relay
    on_release: 
      then:
        - switch.turn_off: light_relay
switch:
  - platform: gpio
    pin: GPIO16
    name: "Light"
    id: light_relay
  - platform: ld2450
    ld2450_id: radar
    bluetooth:
      name: "Bluetooth"
    multi_target:
      name: Multi Target Tracking"
button:
  - platform: ld2450
    ld2450_id: radar
    factory_reset:
      name: "LD2450 Factory Reset"
      entity_category: "config"
    restart:
      name: "LD2450 Restart"
      entity_category: "config"
text_sensor:
  - platform: ld2450
    ld2450_id: radar
    version:
      name: "LD2450 Firmware"
    mac_address:
      name: "LD2450 BT MAC"
    target_1:
      direction:
        name: "Target-1 Direction"
    target_2:
      direction:
        name: "Target-2 Direction"
    target_3:
      direction:
        name: "Target-3 Direction"
sensor:
  - platform: ld2450
    ld2450_id: radar
    target_count:
      name: Presence Target Count
  - platform: ld2450
    ld2450_id: radar
    still_target_count:
      name: Still Target Count
  - platform: ld2450
    ld2450_id: radar
    moving_target_count:
      name: Moving Target Count
  - platform: ld2450
    ld2450_id: radar
    target_1:
      x:
        name: Target-1 X
      y:
        name: Target-1 Y
      speed:
        name: Target-1 Speed
      angle:
        name: Target-1 Angle
      distance:
        name: Target-1 Distance
      resolution:
        name: Target-1 Resolution

 

License:

Creative Commons — Attribution — Share Alike

Related Models

Thor Mjolnir Hammer Bic Pen preview image

Thor Mjolnir Hammer Bic Pen

effektz profile image

effektz

9,096

Diverse Schilder / various labels  for hobby & makers preview image

Diverse Schilder / various labels for hobby & makers

RPK profile image

RPK

2

Cute Fluffy Puppy Figurine to Print preview image

Cute Fluffy Puppy Figurine to Print

bonowski. profile image

bonowski.

3

Vorpal The Hexapod Walking Robot preview image

Vorpal The Hexapod Walking Robot

vorpal profile image

vorpal

4,986

MakerZ – Open Source 1/28 RC Drift Chassis by Fails & Makes | Açık Kaynak 1/28 RC Drift Şasisi preview image

MakerZ – Open Source 1/28 RC Drift Chassis by Fails & Makes | Açık Kaynak 1/28 RC Drift Şasisi

Fails&Makes profile image

Fails&Makes

Customizable EU License Plate Keychain preview image

Customizable EU License Plate Keychain

John_M profile image

John_M

44

Snap-Together Mini Minecraft Jack-O-Lantern with integrated LED preview image

Snap-Together Mini Minecraft Jack-O-Lantern with integrated LED

scottrlindsey profile image

scottrlindsey

4,456

Small Parts Storage Drawers - Organizer preview image

Small Parts Storage Drawers - Organizer

GT 3D Makers profile image

GT 3D Makers

29

10