A custom Zigbee doorbell (2023)(stevestreeting.com)
stevestreeting.com
A custom Zigbee doorbell (2023)
https://www.stevestreeting.com/2023/03/26/a-custom-zigbee-doorbell/
29 comments
I've been trying to get Zigbee python libs to work without having to use Home Assistant, and have had so many problems. I'd love to see some lighterweight examples that actually work. I've downloaded a dozen GitHub projects based on various gateway chips I've bought, and they are all outdated. Compared to BLE, it's trickier to get ZigBee working, at least that's been my experience. Too bad because I like the idea of having a mesh rather than relying a -112 dB Rx BLE receiver in my gateway.
Its Home Assistant or nothing, which is frustrating because HA is so overweight for what I need to do.
Its Home Assistant or nothing, which is frustrating because HA is so overweight for what I need to do.
Not python but zigbee2mqtt + node-red are pretty great.
Maybe have a look at nodered? It talks to zigbee2mqtt reasonably well...
Have you considered Zigbee2mqtt[0]? You'd be running an extra program, but the docs are really good, it's pretty lightweight, and MQTT is incredibly easy to talk to from python or basically anything else. It's compatible with HomeAssistant (which is how I use it), but can be used standalone without having to run HA at all. It also means you don't have to handle the weird idiosyncrasies between different manufacturers.
[0] - https://www.zigbee2mqtt.io/
[0] - https://www.zigbee2mqtt.io/
This is the way to go. Z2M makes interoperability trivial. Just publish to MQTT.
I didn't play with it because I wasn't sure if every sensor out there is natively MQTT capable? ANd if it is, it still has to document the topics it responds to, right? For example, I have a Sonoff temp sensor, how do I know what topic it publishes to and how do I query it? The documentation said nothing about MQTT.
I’m happy to tell you that you are fundamentally misunderstanding. This is good because reality is even simpler.
Z2M takes ordinary Zigbee devices, and generates MQTT messages from them. The devices are oblivious to this, and have no idea what MQTT is. They just act like Zigbee devices.
Z2M just publishes messages on a dedicated topic per device, with all the relevant information in that message. Generally for battery powered devices like temperature sensors, you won’t “query” their state by asking the device - because they sleep with the radio off. Instead you just wait for an update (and store it as needed).
Docs for your device : https://www.zigbee2mqtt.io/devices/SNZB-02.html
Z2M takes ordinary Zigbee devices, and generates MQTT messages from them. The devices are oblivious to this, and have no idea what MQTT is. They just act like Zigbee devices.
Z2M just publishes messages on a dedicated topic per device, with all the relevant information in that message. Generally for battery powered devices like temperature sensors, you won’t “query” their state by asking the device - because they sleep with the radio off. Instead you just wait for an update (and store it as needed).
Docs for your device : https://www.zigbee2mqtt.io/devices/SNZB-02.html
Zigbee2mqtt has a huge number of supported devices (here's their official list [0]), which can also be expanded if the existing mappings don't work.
It took me a minute to find, but the full MQTT structure is detailed here [1], and then individual devices detail what they expose on their page (e.g. this [2] is a random Sonoff temperature sensor). This means that the topic "zigbee2mqtt/sonoff-temp-example" will just have a simple JSON message with '{"humidity":46.93,"temperature":21.73, ...}'.
Hope this helps!
[0] https://www.zigbee2mqtt.io/supported-devices/
[1] https://www.zigbee2mqtt.io/guide/usage/mqtt_topics_and_messa...
[2] https://www.zigbee2mqtt.io/devices/SNZB-02.html
It took me a minute to find, but the full MQTT structure is detailed here [1], and then individual devices detail what they expose on their page (e.g. this [2] is a random Sonoff temperature sensor). This means that the topic "zigbee2mqtt/sonoff-temp-example" will just have a simple JSON message with '{"humidity":46.93,"temperature":21.73, ...}'.
Hope this helps!
[0] https://www.zigbee2mqtt.io/supported-devices/
[1] https://www.zigbee2mqtt.io/guide/usage/mqtt_topics_and_messa...
[2] https://www.zigbee2mqtt.io/devices/SNZB-02.html
fwiw I've had the same experience. Struggled for ages trying to build (in my case) custom ZigBee compatible smart devices running python and it seemed impossible.
Bit the bullet and setup home assistant and I've not looked back - I can even send post requests to web servers to do literally anything as part of it, it's great .
Bit the bullet and setup home assistant and I've not looked back - I can even send post requests to web servers to do literally anything as part of it, it's great .
I got a Sonoff RF gateway and flashed it with Tasmota. Now all the normal 433Mhz devices work 'as is'. My doorbell is unchanged, a 3 year battery life and costs 10 bucks.
The doorbell sound does ring on a custom device. An esp32 with an I2S class D amplifier that can play an an arbitrary mp3 from a web server with an mqtt command:
https://github.com/mianos/doorbell2/tree/main/src
The doorbell sound does ring on a custom device. An esp32 with an I2S class D amplifier that can play an an arbitrary mp3 from a web server with an mqtt command:
https://github.com/mianos/doorbell2/tree/main/src
I've got a similar setup with a SDR tuned to 433Mhz using rtl_433. Really useful as the range is massive and it picks up all kind of devices; temperature sensors, weather stations, tyre pressure sensors.
I had a little SDR connected to an LXD container at first but I found the positioning was not really optimal.
What is also fun, is being able to use those little RF remotes and program node-red flows to, say, run the aircon (controlled with Tasmota IR box) for 20 minutes when I go to bed and another to turn off the lights. Much better than having to open the phone.
What is also fun, is being able to use those little RF remotes and program node-red flows to, say, run the aircon (controlled with Tasmota IR box) for 20 minutes when I go to bed and another to turn off the lights. Much better than having to open the phone.
Been using the same buttons as doorbells for a while. The biggest problem is folks don't look at it like a doorbell. We had to write "press me" on it for folks to use it unfortunately.
The battery life has been great, they have withstood direct sun and indirect rain and snow.
I also name each trigger ID after the door associated with the doorbell, so the message sent can send which door triggered it dynamically.
The battery life has been great, they have withstood direct sun and indirect rain and snow.
I also name each trigger ID after the door associated with the doorbell, so the message sent can send which door triggered it dynamically.
I bought an ESPHome smart doorbell board and put it in the existing 8V AC loop with the existing button and bell. It connects to Home Assistant over MQTT and works a treat, including the ability to silence the bell circuit.
https://www.zuidwijk.com/product/smart-doorbell/
https://www.zuidwijk.com/product/smart-doorbell/
I did pretty much the same thing. The issue wasn't cats (I have two, but they'll gladly let anyone pet and feed them), it was that I can't hear the doorbell from my WFH office. I wanted to flash the light. I already use Home Assistant for loads of stuff.
I tried ESP32 and a 433MHz antenna thingy, so that I could continue to use my cheapo bell. That proved unreliable (a press got picked up, at best, about 90% of the time).
Then I went through two zigbee buttons. The issue is that Amazon and other delivery drivers appear to use a hammer to press doorbells. That's the only explanation I can think of for the state of the buttons after a few weeks.
I finally just caved and bought the cheapest (still expensive) Ring doorbell and disabled the camera. It's been solid, but I feel dirty and regret it each time I pay the annual bill. It's my last cloud-enabled device, but I can't afford to just keep throwing Zigbee buttons at the gorillas who deliver my packages.
I tried ESP32 and a 433MHz antenna thingy, so that I could continue to use my cheapo bell. That proved unreliable (a press got picked up, at best, about 90% of the time).
Then I went through two zigbee buttons. The issue is that Amazon and other delivery drivers appear to use a hammer to press doorbells. That's the only explanation I can think of for the state of the buttons after a few weeks.
I finally just caved and bought the cheapest (still expensive) Ring doorbell and disabled the camera. It's been solid, but I feel dirty and regret it each time I pay the annual bill. It's my last cloud-enabled device, but I can't afford to just keep throwing Zigbee buttons at the gorillas who deliver my packages.
I have an Amcrest doorbell and run amcrest2mqtt which sends messages that get picked up by Home Assistant. Keeps everything local and means I don't have to pay for a Ring subscription.
My only complaint is that when I blocked the doorbell from the internet, it just started rebooting every few minutes. If I cared, I'd tape over the camera, but I'm not too worried about someone spying on my front yard via my doorbell camera.
My only complaint is that when I blocked the doorbell from the internet, it just started rebooting every few minutes. If I cared, I'd tape over the camera, but I'm not too worried about someone spying on my front yard via my doorbell camera.
The threat model is that they capture your ingress and egress patterns.
If someone's targeting me specifically then I feel like it's easier to just watch my house in person. Plus there are all the neighbors with (I assume) their doorbell cameras that would also have my house in view. And this threat would have to, I don't know, run CV on the feed from my camera to see when I leave or when my car leaves, then figure out if everyone in the house left so they could break in?
For this to be worth doing with hacked cameras instead of in person, you need to be monitoring a lot of camera feeds. But to get any useful info out of it, you need to spend a lot of time putting together data about a single feed. And unless you've already evaluated the target, you don't know which feeds are from valuable houses.
I just don't buy this as a real threat for any but the most valuable targets.
For this to be worth doing with hacked cameras instead of in person, you need to be monitoring a lot of camera feeds. But to get any useful info out of it, you need to spend a lot of time putting together data about a single feed. And unless you've already evaluated the target, you don't know which feeds are from valuable houses.
I just don't buy this as a real threat for any but the most valuable targets.
He uses an Aqara Wireless Mini Switch, which isn't water proof. I'm searching for a (reasonably priced) waterproof button for my front door. Until I find one, I'm still sticking to my ESP3389 which acts as a MiTM notifying my HomeAssistant over MQTT.
I wonder if there any devices that send Zigbee message when circuit is closed. I have wired doorbell hooked up to transmitter which triggers doorbell receiver.
I would like to get phone notification but don’t want to mess with doorbell or ringer. I thought about receiving the transmission with SDR. But splicing in another transmitter might work. I wonder if there are Zigbee alarms.
I would like to get phone notification but don’t want to mess with doorbell or ringer. I thought about receiving the transmission with SDR. But splicing in another transmitter might work. I wonder if there are Zigbee alarms.
This is a cool project! Next, I want an open source smart lock with zigbee, matter or whatever.
I can’t do it by myself. But I always imagine, naively I know, that an ESP, a battery and a servomotor must be easy to integrate into Home Assistant.
I would love to pay for that.
I can’t do it by myself. But I always imagine, naively I know, that an ESP, a battery and a servomotor must be easy to integrate into Home Assistant.
I would love to pay for that.
You might want to take a look at https://esphome.io/ for an easy integration of an ESP32/8266 into home Assistant.
I had exactly the same setup, and it worked quite well. But I decided after a couple of weeks to replace it with a low-tech wireless doorbell from Amazon. It's more reliable now, and I prefer my phone to be quiet most of the time.
Oh, I have a spare IKEA button. Might have to give this a try.
i use the same button but with zigbee2mqtt and it works seamlessly with HA
We have essentially the same thing and I can confirm that my dogs now freak out at the critical alert sound on my phone.