Go Down

Topic: Detecting Doorbell Button Press w/o Chime (Read 1 time) previous topic - next topic

scruzloose33

I purchased two of the video doorbells shown in the spec sheet below (requiring 16-24VAC). I do not have a mechanical chime, so I want to hook these to an Arduino Uno to detect when the doorbell buttons are pressed (eventually to notify OpenHAB of the button press to play a tone through my house speakers). I will probably buy a 16V AC doorbell transformer or a 24VAC plug-in transformer for the circuits. Since these doorbells are made to work with mechanical chimes, I assume I need to add a resistor into the circuit. But, what is the best way to hook these circuits into the Arduino pins so I can detect the button presses? Can I simply use a 7805 regulator to drop the (16 or 24V) voltage down to 5V to be safe for the Arduino? Am I going to need diodes, capacitors, or anything else?

https://www.nellyssecurity.com/media/specsheets/hikvision/ip-cameras/nsc-db1.pdf

Thanks in advance for any suggestions you may have for this Arduino noob!

Paul_KD7HB

Your link gives absolutely no information on connecting a chime to the circuit. Best wait until you find out how it is supported and connected.

Paul

scruzloose33

Unfortunately, the vague diagram in the bottom left of that spec sheet is about all they provide. The quick start guide at the link below discusses using a resistor when no mechanical chime is used, but there still isn't a lot of useful information (nothing additional came in the box).

https://www.nellyssecurity.com/quickstart/guides/doorbell.php

It seems like this expects to operate as a standard US 16VAC doorbell circuit because it says to just swap it in to replace a standard doorbell running on 16V. What additional information do you think would be helpful? Maybe I can get something from the vendor.


promacjoe2

In order for this unit to work,  It needs to have a secondary load on the circuit to limit the current to the camera.When the button is pushed, The button bypasses the camera power input and puts full current to the doorbell. If you do not have a primary doorbell, you need a relay, at the proper voltage, To emulate this load. The relay can activate the Arduino, or any other device you need. Also, the relay should be heavy enough to provide the current needed for the unit to operate. At this point it is an unknown.

scruzloose33

Thanks for the help. Are you suggesting I simply need a power relay module that can support 16VAC input that I would install in place of the typical door chime? Most relays that I see appear to take low voltage input to switch on and off high voltage power. Am I searching incorrectly and there are relays that that a high voltage control signal to switch 5V output power? Sorry for the basic question, but I want to make sure I get the correct parts. Thanks!

promacjoe2

A relay by itself would work, but only if it would provide enough current to power the device without being energized itself. Finding such a relay is the problem. A relay that is placed in parallel with the doorbell solenoid is a better solution. If you do not have a doorbell solenoid, another option might be a 16/24 V transformer. Use the secondary side as a load, and isolate the primary so that it does not draw any current. The relay could be placed in parallel with the transformer Secondary windings.

Even a lightbulb might be enough to provide power to the device. The lightbulb would have to be large enough to be very dim under normal operation, when the doorbell button is pushed, The lightbulb would get brighter. If a lightbulb would work to power your device, you can optically couple your Arduino using the lightbulb. No need for a relay.

You can also use a hall affects current sensor. Although you would still need some sort of load, You could adjust it in programming so that the Arduino would only react when the doorbell button was pushed.

There are many ways of doing the same thing. Without knowing your specific application, it is hard to tell you what the best way is.

DVDdoug

Quote
Since these doorbells are made to work with mechanical chimes, I assume I need to add a resistor into the circuit.
I would assume so...    Lighted doorbells and lighted wall switches are powered through the load.    When the button is pressed (or the light switched-on), the light goes out..  If we assume 1/2 Amp -  16V @ 1/2 Amp would be 32 Ohms (at 8 Watts).  Of course that's just a guess, so the resistor doesn't have to be exactly 32-Ohms, but it does have to be rated for the wattage.   (It will only dissipate significant power when the button is being pushed.) 


The voltage should "appear" across the load when the button is pushed.  (There will be a small voltage at all times because there is some small current required to power the thing, and current current will be flowing.)

Quote
But, what is the best way to hook these circuits into the Arduino pins so I can detect the button presses?
Do you have a multimeter?

That's AC, and the negative-half of the cycle can kill an Arduino.  so, you'll need a rectifier (diode).    You'll also need a Voltave Divider (2 resistors) to bring tgeh voltage down to 5V.    The resistor values are not critical, it's the ratio that's important, but if you make them add-up to about 10K that should work.

Note that the peak of an AC waveform is about 1.4 times the RMS value, so 16VAC will peak at about 23V.   And, the transformer will have a tolerance and the voltage will vary with the actual power line voltage, and with the load...    To be safe, you should add a Protection Diode along with the voltage divider.   (The resistor is an important part of the protection circuit, but the resistors that make-up your voltage divider will suffice, so you just need a diode.)

Since the AC is transformer-isolated from "everything else", you can connect either end of the resistor to the Arduino ground and the other end is the "signal" through the rectifier & voltage divider to the Arduino's input.   Note the "reverse logic"...   The Arduino input goes low when the button is pushed.

promacjoe2

According to the document he provided, current consumption .6 A max.
That would indicate constant load of +/- 8W. You would have to include this in your calculation.

scruzloose33

If I want to simplify my work, could I use this pre-fabricated full wave rectifier with the smoothing capacitor and voltage regulator? Could I simply connect the doorbell transformer circuit (16VAC) to the input and use the 5V DC output to the Arduino pin? Would I need anything else in the circuit?

http://microcontrollershop.com/product_info.php?products_id=4239

I am struggling to find the correct optocouplers and other recommended parts and don't mind spending a few extra bucks if I can find something that makes my life much easier.

scruzloose33

#9
Jan 14, 2018, 10:24 pm Last Edit: Jan 14, 2018, 11:16 pm by scruzloose33
What I am hoping to do is something like the following.  Since the max power consumption of each doorbell is 0.6A and I have two of them (front and back), I assume I need a 16VAC/30VA transformer (I will probably use a 40VA to be safe).  I then want to route each doorbell to the above-mentioned regulator board that rectifies, smoothes, and regulates down to 5V DC.  I would then hook the 5V output from each regulator board to a digital input pin on the Arduino Uno.  I would expect the cameras to be the primary loads when the button is not pressed, but the full 16V would go to the regulator boards when the buttons are pressed.  This would signal the Arduino and I could then program what I wanted to happen.



Something about this diagram does not seem right to me, but I cannot figure out how to adjust it to meet my needs.  Any help would be appreciated.

  • Can I hook two of these 0.6A doorbells to the single transformer if it is rated 40VA?
  • I assume a doorbell button simply operates as a button switch.  This would mean 16VAC across the switch when the switch is open and 0V across it when closed.  That would indicate that the regulator boards would get 0V typically, but it would temporarily spike to 16V when the button is pressed (similar to the voltage seen at a mechanical chime to charge the solenoid).  I don't understand the "reverse logic" that DVDdoug mentions above.
  • I don't know if the way I have proposed completing the circuit from the doorbells through the regulator boards and back to the transformer makes sense.  Would this work and the regulator boards could serve as the load when the button is pressed.  Based on the schematic, could one of the input screw terminals connect to the doorbell button and the other to the transformer (as I have drawn in the connection diagram)?

Regulator board schematic:


Thanks again for all of your help!

promacjoe2

The problem is,Your doorbell camera/Button requires a certain load to operate. That load has to be continuous at all times. When the doorbell button is pressed, you are essentially bypassing that load and putting power to the doorbell. The camera takes one amount of current, The camera will operate in series with the doorbell because it takes less current. That current is not enough to trigger the doorbell.  Two reasons why your schematic will not work. 1, the load required by the camera is greater than the load required by the power supply that you're using. 2, The power converter that you're using has a very wide input voltage range. It will provide an output voltage regardless of whether the button is pressed or not. You need a secondary load greater than the load for the camera, such as a doorbell. Only then will you get your Arduino to be able to detect when the button is pressed.

scruzloose33

The problem is,Your doorbell camera/Button requires a certain load to operate. That load has to be continuous at all times. When the doorbell button is pressed, you are essentially bypassing that load and putting power to the doorbell. The camera takes one amount of current, The camera will operate in series with the doorbell because it takes less current. That current is not enough to trigger the doorbell.  Two reasons why your schematic will not work. 1, the load required by the camera is greater than the load required by the power supply that you're using. 2, The power converter that you're using has a very wide input voltage range. It will provide an output voltage regardless of whether the button is pressed or not. You need a secondary load greater than the load for the camera, such as a doorbell. Only then will you get your Arduino to be able to detect when the button is pressed.
I am not opposed to wiring in a mechanical chime if that will make my life much easier.  I eventually want to include the ability to silence my doorbells (e.g., for when the baby is sleeping), but I can deal with that later by removing the tone bars in the chime box or something similar.  Having a chime will actually buy me more time to figure out the Arduino and home automation programming.

If we assume I do add a mechanical chime to the mix and wire this up like a regular doorbell (both buttons wired to a single chime), what would then be the best/easiest way to tie that into the Arduino input pins?  Could I connect two of those rectifying/regulating boards in parallel with the chime?  Is using a relay (as mentioned above) the better option?

promacjoe2

A halls affect current sensor is probably your best option. With it in the program, you can specify a threshold current to trigger the Arduino. It will also not interfere with the operation of the doorbell/camera.

scruzloose33

Thanks for the suggestion.  Would something like this do the trick?

https://www.adafruit.com/product/158

I assume I would just connect the sensor Vcc to the 5V power from the Arduino and get the sensor close to the magnetic chime.  It looks like I then attach a 10k pull-up resistor and hook that back up to the Arduino input pin.  This pin would read low (0V) most of the time and would jump to high (5V) when the magnetic field from the chime solenoid was charged.  Does that sound right?  I wonder if I could mount this Arduino (or by breadboard) right to the outside of the chime box to sense the magnetic field.

scruzloose33

The downside of this setup is that I likely wouldn't be able to differentiate the front and back doors.  The isolation is great, but I would probably need two separate chime boxes if I wanted to differentiate them with a halls effect sensor.

Go Up