Today I brought my existing doorbell into OpenHAB via ZWave. Since I did not want to replace my existing wiring, button and bell I had to hack it a bit.
The wiring uses 12V DC and activates a battery-driven bell. So everytime someone pushes the button, 12V will be sent up to the bell which then plays a sound. I figured that I needed something connected to the 12V that notifies OpenHab whenever power gets activated.
In comes my unused Doorsensor by Devolo! This sensor is usually put on a door, a small magnet is placed on the frame. Whenever the magnet is near the sensor, it notifies that the door has been closed. What I did was to connect an electro magnet to the bell wiring and placed the door sensor beside it. So whenever someone rings the bell, the magnet gets activated and the door sensor sends “Door Closed” to the system.