PIR Sensor does not work, need config support

I put everything on a breadboard for testing and added the sensor config to esphome, but it does not work. I have no idea if the esp config is wrong, the breadboard layout or if i used the wrong pin on the hardware.

how do you know what gpio config and esphome config you need for the PIR Sensor EKMC1603113? I can not find it in esphome documentation

binary_sensor:
  - platform: gpio
    name: mmwave_in_bedroom
    pin:
      number: GPIO22
      mode: INPUT_PULLDOWN
  - platform: gpio
    pin: GPIO26
    name: "PIR Sensor"
    device_class: motion

Any ideas or tips why it does not work or how to test?

1 Like

In your wiring I see only two wires from the sensor.
You need VCC, GND and OUT.
Connect OUT to the nodemcu pin and check the power supply according to the sensor data sheet

3 Likes

So i got the PIR sensor working but it switches very fast from on to off and back, nothing is moving in front of it. Any idea?

ok looks like it also switches between on and off when PIR Sensor is not connected to the board :frowning:

Is it connected to 5v or 3.3v ?
It should be more stable on 5v :wink:

tried both but no difference in stability. But I also wonder why the status changes fast when the Sensor is not connected

Possibly need a pullup/down

Yeah, thats wierd.
I just connected mine last night, and also have the flickering in “detected/clear” But I have not tried to see what happens if i disconnect the “out”. Just figured it was due to 3.3v and not 5v. (will try both when I get home)

What do you mean with pull-up/down?

Did you figure this out?

Did you try this?

binary_sensor:
  - platform: gpio
    name: mmwave_in_bedroom
    pin:
      number: 22
      mode: INPUT_PULLDOWN
  - platform: gpio
    name: "PIR Sensor"
    device_class: motion
    pin:
      number: 26
      mode: INPUT_PULLDOWN

If it doesn’t work, put a 10k resistor between gnd and the pin 26. this will do a pulldown and prevent fluctuation between on and off.

This worked!
image