LD1125H mmWave Sensor dealing with Ceiling Fans

I have a LD1125H mmWave sensor that I use in my office that I just have sticky tacked to the side of a bookshelf for “testing”. I’ve been “testing” it for about 5 months now and I really do like it, but I have one minor complaint, if I have my ceiling fan on and then leave the room, the lights will never turn off because my fan is (understandably) triggering it’s motion sensors.

The LD1125H has a max distance that you can set so you aren’t getting false detections by someone in another room, but it doesn’t have a min distance from what I’ve seen to prevent false detections by objects that are too close, like a ceiling fan.

Has anyone modified the code provided by patrick3399 for using these modules with espHome to include an minimum detection range or has anyone found a good method for avoiding ceiling fan detection with these mmWave sensors?

It not easy with the LD1125H. It mentions in the manual that it should be installed avoiding any air outlet of an air conditioner, fans and other objects.

You can set the detection sensitivity but only in the following three segments:

  1. 0 - 2.8m
  2. 2.8 - 8m
  3. 8m and beyond

From the manual:

Configuration directives
rmax=**,Set the maximum detection distance. The distance value with one decimal place can be set, and the unit is meters. For example: Set the module to only detect targets within a distance of 6 meters. Then send rmax=6, at this time the module will only output the target within 6 meters. Targets 6 meters away will not output. The module defaults to rmax=6.
mth1=**,Set the segmentation sensitivity threshold of 1. mth1 corresponds to the signal threshold within 2.8 meters. The default value is 60.
mth2=**,Set the segmentation sensitivity threshold of 2. mth2 corresponds to the signal threshold within 2.8-8 meters. The default value is 30.
mth3=**,Set the segmentation sensitivity threshold of 3. mth3 corresponds to the signal threshold beyond 8 meters. The default value is 20.

So unless you happen to always be in one segment and the fan in another, it’ll be hard to avoid detecting the fan.

You’ll have better luck avoiding detection of fans with, for example, a LD2410c, with its 8 gates and noise detection feature (in the app).

1 Like

I was thinking of modifying the code in ESPHome such that before it set occupied or movement I compared it to a min distance value. I’m not sure if the ESP32 could process the text string quickly enough. And assuming it did, if the module would send a string that contained the distance to the fan followed by a string that contained the distance to any other movement it found or if the fan would completely block any movement beyond it. But I figure it was worth a shot provided no one else had already tried and confirmed that it was a waste of time, lol.

I think the ESP32 would be fast enough, but also that the fan would block any detection beyond it.

1 Like

I never got this working with ceiling fan, it keeps detecting after changing the move/still energy. I just moved on to LD2450

1 Like