Wireless Doorbell Speaker: How to detect if it's playing/has power (and for how long?)

Hi,

I am replacing my existing smart doorbell system due to it being unreliable and I think the wiring that runs in the walls to the buttons is broken somewhere as it works intermittently at best. I have bought a cheap wireless doorbell from my local hardware store that runs on 3 C batteries and has two chimes (one for the front and one for the back door) and I have two buttons. There is no LED; only a speaker. Is it possible for an ESP8266 to read when there is power going to a speaker and for how long? Ex. If it can read there is power for only xx milliseconds; then it is the front door. If it reads power for xx seconds; it is the back door?

I’m completely new to ESPhome as I haven’t really needed to program in Arduino (outside of 3D printer firmware) for a couple of years now so i’m a little rusty.

Thanks,

Aren’t doorbells usually 433Mhz? Why not detect the button push that way?

Not too sure what you mean there.

As @nickrout is saying, the wireless door might mostly be using 433Mhz radio frequency signals to communicate between the switches and the bell speaker unit. Since there are two remotes, they both will be transmitting different codes to the speaker unit when they are pressed. This can be detected by using a Rf reciever module connected to esp8266. For this purpose you can use either esphome or tasmota. Just check out these links

https://tasmota.github.io/docs/RF-Transciever/

This would be the best way to detect when the switches without even opening the speaker unit. it will also be reliable.

If you want to go for any of the shelf kind of solution, you can buy sonoff rf bridge.

Also please first verify that the device uses 433mhz, it should be mentioned on the device or the packaging.

Or https://www.home-assistant.io/integrations/rfxtrx/

Hi @nickrout and @sheminasalam

Thanks for explaining it like that; now I know what you mean. I had to do some digging as the frequency wasn’t listed on the box or in the directions for the doorbell; or even the extra button. After looking up the FCC ID I found on the back of the button; it is a 433.94MHz switch. I can’t remember for sure but I may have a 433MHz receiver from back when I was learning Arduino that was never used that I will try and adapt for this. Instead of hacking the hardware; i’ll hack the radio signal. This should give me some nice options in HA as well.

Now to see if there is a way that I can make a switch for the speaker so I can disable the door chime if I wanted to; but still get the text notification. Preferably not a relay.

Thank you both again!

Happy to help. If the speaker is connected to the PCB with wires, then its very easy, just cut one of the wires and attach a switch in between. If its soldered on to the PCB, then you might have to find the traces to the speaker and then cut it and attach a switch after peeling some pcb masking which could get messy.

Hi @sheminasalam

Yes, I could put a physical switch in. But I think there is a piece I can solder in; a transistor or a mosfet (can’t remember the exact name of the component). This way I can handle it from HA; and that would emulate the system i’m replacing perfectly.

1 Like

There is also https://github.com/1technophile/OpenMQTTGateway which supports 433MHz RF.

Ok. so I found a spare ESP8266 and a 433 receiver; but I am having issues getting the pin to go High to receive signal. Any ideas? I’ve tried different pins its always the same.

esphome:
  name: doorbell_receiver
  platform: ESP8266
#  board: nodemcuv2
  board: nodemcu
wifi:
  ssid: !secret wifi_network
  password: !secret wifi_password

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Doorbell Receiver"
    password: "DgRI5sHTbagf"

captive_portal:

# Enable logging
logger:

# Enable Home Assistant API
api:
  password: !secret api_password

ota:
  password: !secret api_password
  
remote_receiver:
  pin:
    number: D6
    inverted: true
  dump: rc_switch
  tolerance: 50%
  filter: 250ms
  idle: 10ms

logs

WiFi:
[22:15:22][C][wifi:303]:   SSID: [redacted]
[22:15:22][C][wifi:304]:   IP Address: 192.168.1.73
[22:15:22][C][wifi:306]:   BSSID: [redacted]
[22:15:22][C][wifi:307]:   Hostname: 'doorbell_receiver'
[22:15:22][C][wifi:311]:   Signal strength: -55 dB ▂▄▆█
[22:15:22][C][wifi:315]:   Channel: 7
[22:15:22][C][wifi:316]:   Subnet: 255.255.255.0
[22:15:22][C][wifi:317]:   Gateway: 192.168.1.1
[22:15:22][C][wifi:318]:   DNS1: 192.168.1.1
[22:15:22][C][wifi:319]:   DNS2: (IP unset)
[22:15:22][C][logger:185]: Logger:
[22:15:22][C][logger:186]:   Level: DEBUG
[22:15:22][C][logger:187]:   Log Baud Rate: 115200
[22:15:22][C][logger:188]:   Hardware UART: UART0
[22:15:22][C][remote_receiver.esp8266:059]: Remote Receiver:
[22:15:22][C][remote_receiver.esp8266:060]:   Pin: GPIO12 (Mode: INPUT, INVERTED)
[22:15:22][W][remote_receiver.esp8266:063]: Remote Receiver Signal starts with a HIGH value. Usually this means you have to invert the signal using 'inverted: True' in the pin schema!
[22:15:22][C][remote_receiver.esp8266:065]:   Buffer Size: 1000
[22:15:22][C][remote_receiver.esp8266:066]:   Tolerance: 50%
[22:15:22][C][remote_receiver.esp8266:067]:   Filter out pulses shorter than: 144 us
[22:15:22][C][remote_receiver.esp8266:068]:   Signal is done after 10000 us of no changes
[22:15:22][C][captive_portal:169]: Captive Portal:
[22:15:22][C][ota:029]: Over-The-Air Updates:
[22:15:22][C][ota:030]:   Address: doorbell_receiver.local:8266
[22:15:22][C][ota:032]:   Using Password.
[22:15:22][C][api:095]: API Server:
[22:15:22][C][api:096]:   Address: doorbell_receiver.local:6053

try changing inverted: true to inverted: yes

Hi @sheminasalam

Same thing unfortunately; no differrence.

esphome:
  name: doorbell_receiver
  platform: ESP8266
#  board: nodemcuv2
  board: nodemcu
wifi:
  ssid: !secret wifi_network
  password: !secret wifi_password

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Doorbell Receiver"
    password: "DgRI5sHTbagf"

captive_portal:

# Enable logging
logger:

# Enable Home Assistant API
api:
  password: !secret api_password

ota:
  password: !secret api_password
  
remote_receiver:
  pin:
    number: D6
    inverted: yes
  dump: rc_switch
  tolerance: 50%
  filter: 250ms
  idle: 10ms

I dont see any more issues with this. I have seen another code but dont know if it will work.

remote_receiver:
  pin:
    number: D6
    inverted: yes
    mode: INPUT_PULLUP
  dump: all

If this doesnt work out you can try tasmota. But flash the tasmota_sensors.bin. i am using it succesfully.

Ok thanks. I’m going to give tasmota a try and see what happens. I have the firmware flashed and connected to my Wi-Fi network; now to see if the code can be picked up.

-Cheers,

1 Like

Ok, so I have the tasmota sensors firmware flashed and the module configured as Generic; and D6 pin is set as RFrecv; but i’m still not getting anything in console when pushing the button on the doorbells. I’m beginning to think that maybe my RF receiver is broken or the wrong type?

I know this rf sensor, its not good. I bought about 4 and I was able to make only one work and that too with a range less than 1m. I later upgraded to one in this.
https://tasmota.github.io/docs/RF-Transciever/
It works fine although range is about 6m.I dont know how it performed for you with arduino but you could try with a very close range.

So as to narrow down the issue you may build an emitter setup and try to send to your receiver. It can be done with another ESP with a basic emitter + the senddemo example

If you see the signal comings this means that your receiver setup is working correctly and that your device protocol/signal is not decoded by the firmware used.