Hello,
I’m using an LD2410 with an ESP32 but the sensor only works if I plug (power) the sensor after I boot the ESP32. The sensor connected is through pins 1 and 3.
If I boot the ESP32 with the sensor already connected then I don’t see any messages being transmitted through UART.
I was thinking that maybe I need to delay the initial connection, but I haven’t found a way to do that.
Any ideas?
Thank you.
zoogara
(Daryl)
April 10, 2023, 7:18am
2
Could be a sensor brownout due to initial high power demand.
Things I’d try first before looking into delays:
Try a high quality esp32 (cheap ones can have crappy voltage regulators).
Try your best power supply and cables.
Solder connections.
Is it powered by 5V? From the ESP 5V pin?
After that you can try something like this.
I was curious about this and searched the ESPHome Discord for it.
It seems some people are using it like this:
sensor:
- platform: am2320
setup_priority: -100
address: 0x5C
temperature:
name: "temp02"
humidity:
name: "humi02"
update_interval: 60s
I couldn’t find anything on a quick docs check.
Or this:
Ok, I was on the right track the whole time. I seem to have solved the problem with a lower level command found here:
The BH1750 now is switchable, like it should be.
I was not aware that such commands can be used in the yaml, this opens up a lot of possibilities:
esphome:
name: esphome--6
on_boot:
priority: 900
then:
- delay: 2s
- switch.turn_off: mosfet_switch
- lambda: |-
Wire.begin(); #solves the problem with BH1750
#wake_up command BH1750
- d…