Reliable and cheap door/window sensors

Yes, there no battery information.
But I’ve had mine running now for almost 9 months. I just set a 12 month automation/timer and Ill replace the batteries regardless. I think a year is pretty good

1 Like

I have another question :slight_smile:
Is there a way to make the sensors retain their state when restarting HA?

Not on these and not on any sensors.

How do you handle this situation of restarting HA and your sensors not providing accurate information?
I can only think of having input booleans mirroring the sensor state but that seems like a messy solution.

I dont believe HA saves sensor states for any kind of sensor.
If the condition changed during restart, then im not sure whats the solution other than as you say using booleans.
In fact I believe it’s the reason boolean state does persist through restart according to this

I posted a specific question elsewhere and got this response. Not perfect but a big improvement.

1 Like

thank you. did you try it?
edit: didnt read well first time. it still has the same problem. If the door is open during restart HA wont know.

Not yet, I am about to!
Yes it still has the problem if the state changes while HA is down but as I read it, it should remember the previous state when it restarts, which is better than always changing to ‘Closed’.

Let’s see if it works…

EDIT: It does but read the whole thread as some small changes were made. Now there is only a problem if the sensor state changes while the 433 Hub or HA is offline, which is a big improvement on them being wrong after every HA restart.

Just an update - I have received my first batch of Xiaomi sensors and I ended up using deconz/conbee as the zigbee controller. It so far works flawlessly and a pretty cheap solution :slight_smile:

2 Likes

Hi, have you succeded with the flashing?

No I couldn’t flash them and gave up in the end. There must be something interfering on the circuit?

They do now work with IFTTT though, although the project is on temporary hold at the moment due to doing other jobs so I haven’t really set anything up yet.

Device that has only 1 code, you can add " off_delay: xx " xx = time in seconds to reset payload_on, such as Motion sensor, Carbon Monoxide Sensor, Leak Detection.

  • platform: mqtt
    name: “PIR Motion Sensor”
    state_topic: “tele/RF_Bridge/RESULT”
    value_template: ‘{{value_json.RfReceived.Data}}’
    payload_on: “xxx7742”
    device_class: motion
    off_delay: 5
    retain: false

  • platform: mqtt
    name: “CO Sensor”
    state_topic: “tele/RF_Bridge/RESULT”
    value_template: ‘{{value_json.RfReceived.Data}}’
    payload_on: “xxx16387”
    device_class: smoke
    off_delay: 10
    retain: false

Thank you. I tried your suggestion and that doesn’t work. It doesn’t actually turn off the sensor. My understanding of of_delay is that once the device is off it will need to be off for at least 5 seconds (in this case) before it actually reports off, but it doesn’t turn the device off.

now this works without a turn off automation:

- platform: mqtt
  name: "pir8_mastertoilet"
  state_topic: 'tele/sonoff/rfbridge/RESULT' 
  value_template: '{{ value_json["RfReceived"].Data if value_json else "825888OFF" }}' 
  payload_on: "825888"
  payload_off: "825888OFF"
  device_class: motion
  scan_interval: 10
  retain: true

the sensor scans every 10 seconds, if the template doesnt get the on payload it assumes its off.

So easy, not my idea :wink: I got it from an unrelated post.

I just received two Neo NAS DS01W door switches- are they useless in a Home Assistant installation?

You can use them with IFTTT so not useless.

There is an extra MCU on them that seems to be putting them to sleep if you flash them with another firmware.
So need to work out how it’s doing it or find a way to mod the existing firmware to redirect the MQTT destination to a local one.

Thanks. YAML is easy compared to IFTTT, so for me, it’s a no-starter.

I’m also interested in use tasmota with those Wi-Fi door sensors. I have some from gocomma brand which are the same as the ones from Neo.
Please share if you find the way :wink:

I have a bunch of these Neo/gocomma sensors too. First I’m going to make some current measurements to see how long the battery will really last. If it seems reasonable (at least a year) I’ll have a go at reverse engineering the circuit and try to work out what the extra processor is doing. Don’t hold your breath though. I have a lot of projects on the go at the moment and this low down on the priority list.

can anybody send me the original firmware of the door sensor?
i have mine flashed with tasmota and forgot to backup the original firmware

Does these cheap gs-wds07 sensors work correctly for You? I have around 15 and around 30% of them are really unreliable. Not always giving the close/open state to the Tasmotized Sonoff RF (I have 2 of these to cover the whole house, so the signal is not an issue) . I am thinking the reed switch is faulty and needs to be replaced. Does anyone have the same issues with these switches?