Hello, nice of you to drop by and take an interest in the "Push notifications for doorbells" project.
I live in a flat with an unfavourable layout and therefore often missed my doorbell. This was often annoying because visitors had to wait outside the door for a long time or call me to open the door.
Thanks to the project, I no longer have this problem. I also learnt a lot while implementing the project and I really enjoyed it. I hope you have as much fun realising it as I did.
If you have any questions about the project, you can find my email address at the bottom of this page. Don't hesitate to write to me, even if you have suggestions for improvement.
Best regards
Alex
You need the following things to realise the project:
Of course, an existing wired doorbell like this one: https://www.chbyron.eu/de-de/byron-produkte/turoffnung/drahtgebundene-turklingeln-klingelknopfe/byron-00-640-80-771-kabelgebundene-t%C3%BCrklingel-wei%C3%9F-00.640.80
It doesn't matter exactly which model you have. The main thing is that it runs on a 9V battery and has wiring similar to the one in this picture:
Your own Pushover account. You can create one at: https://pushover.net/. An account for your client device (whether iPhone, Android or desktop) costs $5 once!
A Wifi-capable Arduino or ESP. I used a D1 Mini - ESP8266 development board. You can buy this here, for example: https://www.berrybase.de/d1-mini-esp8266-entwicklungsboard
A battery with 3.7 V or LIPO, such as this one here: https://amzn.eu/d/gHfH5Ar This should have a high capacity so that your Arduino lasts a long time and you don't have to change the battery every week. I used the one from the link above, which has a capacity of 2000 mAh. So far the Arduino has run for over a month without the battery running out.
A few wires, resistors and a transistor. I used a 2N2222 NPN bipolar transistor. Any other NPN transistor should do as well.
Here is the complete circuit diagram. It shows which resistors I have used. The connections of the Arduino or ESP are also marked. You can find out how to make the connection to the wired doorbell below under "Wiring and installation".
In order to receive a notification on your mobile phone or PC later, you need to create a Pushover account and generate two API tokens. One for the notification that the doorbell at your front door has been pressed and one for the notification that the battery level of your LIPO is low and you should replace or charge the battery.
You can create the Pushover account here: https://pushover.net/login
You then need to create two new API tokens. You can do this via the link under the item: Your Applications (Create an Application/API Token) in your Pushover profile at: https://pushover.net/ or via the following link: https://pushover.net/apps/build
There you do not need to enter anything more than the name of the API token. An example would be
doorbell
and
battery status
If you like, you can add an icon to have a better overview in the Pushover app or in the web interface for Pushover Desktop.
You can download the code for the project here on the left or via this link. The code is located in the folder "Push_notifications_for_doorbells". You can open the file using the Arduino IDE and transfer it to your Arduino or ESP. (Note: Arduino always wants you to have an .ino file in a folder. It is therefore best to download the entire "Push_notifications_for_doorbells" folder and open the .ino file from there)
You can download the Arduino IDE here: https://www.arduino.cc/en/software
Board Manager
If you are using a D1 Mini - ESP8266 development board like me, you must download and install the corresponding library via the Board Manager before you can transfer the code to the ESP. For the ESP8266 it is the one shown on the left.
Libaries
To be able to upload the code to your Arduino or ESP, you will need various libraries. You can download these via the Libary Manager in the Arduino IDE.
You need:
Pushover-master
Time
If you can't find the libaries in the Libary Manager, I have also put the files in the "Push notifications for doorbells project" folder in Google Drive. You should copy the folders of the libraries to: "C:\Users\YourUserName\Documents\Arduino\libraries\".
You can find documentation on the libraries at:
Code
Once you have downloaded the code and installed all the required libraries, you now need to adapt the code so that it matches your Pushover configuration. To do this, you must insert your tokens in code lines 32 and 33. Which tokens you need to insert can be found in the comment above line 32.
But here is a brief description. You can find your user key and your API token in your Pushover profile at: https://pushover.net/ and there under "Your User Key" and the API token if you click on the API token you have created.
I output a message at many programme points via the serial interface. I have used this for debugging. If you want, you can remove all lines of code with "Serial.print(XXX);" or "Serial.println(XXX);" as well as: "Serial.begin(115200);"
Transfer code to Arduino or ESP
Once you have successfully customised the code and installed the corresponding libaries, you can now transfer the code to your Arduino or ESP. To do this, connect your Arduino or ESP to your PC via USB.
In the Arduino IDE, select the port to which you have connected your Arduino or ESP and select the correct board. If, like me, you are using the D1 Mini - ESP8266 development board, the correct board is the: LOLIN(WEMOS) D1 R2 & mini.
Now you can load the programme onto the Arduino or ESP. If no errors are displayed at the bottom of the console in the Arduino IDE, you have done everything correctly.
I built a small case for my ESP and the circuit and printed it out with the 3D printer. The case is still in its first version and has a few problems here and there. Of course you can still download and print it.
I have thought of the following things that should be improved:
Thicker walls
Improve the passage for the battery cables
Larger clips which hold better
Make a hole for the cables coming out of the doorbell
Enlarge the case, as the battery is difficult to fit in
If you would like to improve the case, I will be happy to send you the .ipt file. Just send an email to the address given below.
The best way to wire the resistors and LEDs is to use the circuit diagram that I have provided at the top of this page.
You should make the connection to the doorbell as follows:
There should be two cables coming out of your wall from the switch outside your home where your guests can ring your doorbell. In my case, these are at markings 1 (red) and 3 (purple). It doesn't really matter which of these cables you connect where, as there is only a simple switch outside.
You should connect or leave one of these cables connected to point 3 (purple) of the wired doorbell.
Connect the other of the cables from outside to the point shown on the wiring diagram as the "red cable" point. Like me, you can use an extra red cable to bridge the path, as you can see on the left in the picture. This red cable (in my case) should therefore be connected via the 660 Ohm resistor at the base of your transistor.
Another cable, I used a black one as you can see in the picture, is connected to the "black cable" point as shown in the circuit diagram. Connect the other end of the black cable to point 2 (black) of the wired bell.
Your Arduino or ESP should now be connected correctly. If you still have problems, I have added a few pictures here that will hopefully help:
I have also uploaded these pictures here in the Pictures folder. If that doesn't help either, please contact me by email and I will try to help you.
Important: When you install the doorbell for the first time, or every time you replace the battery, a notification is sent once that the doorbell has been activated. This is unfortunately predetermined by the implementation of the code. If you can think of a solution, please write to me.
If you have any questions or suggestions for improving the project, please write to me at alexprojects@mailbox.org.