HOWTO: Integrate doorPi [SIP based Raspberry doorbell] into openHAB

Some time ago, I wanted to have a SIP based doorbell to nicely integrate with my smarthome and while searching, I came across doorPi.

With my below described config, one will be able to turn on the lights on your doorPi based on openHAB Astro Binding, have your Alexa say something like “Doorbell is ringing” and hangup when the door is opened.

You need to have a up and running doorPi.
Instructions can be found here (German only, sorry)

doorPi.ini - piFace config

prodsystem = piface

0 = sleep:0		// doorbell pushbutton
1 = sleep:0		// Lights ON
2 = sleep:0		// Lights OFF
3 = hangup:0	// Receive openHAB command to hangup when door is opened

0 = Sound
1 = Lights

Usually, you would use your input pins directly to make a call in doorPi. Defining just a sleep command lets us use the event system to take further action.
The output pins present piFace outputs to switch the relais for the soundcard or the lights.

doorPi.ini - Event config

10 = os_execute:curl --header "Content-Type: text/plain" --request POST --data "ON"
20 = call:**611#622#623

When the doorbell button is pressed, this event is triggered, sending a REST call to a openHAB Switch Item, indicating an active call. The call will be initiated in line two.

10 = out:Lights,1
10 = out:Lights,0

The unused piFace inputs 1 and 2 are used to receive a trigger from openHAB to switch ON/OFF the lights.

10 = out:Sound,0
20 = os_execute:curl --header "Content-Type: text/plain" --request POST --data "OFF"

Switch off the amplifier and send information to openHAB that the door call has ended.

10 = out:Verstaerker,1

Switch on the amplifier when a call will be initiated.

openHAB Items

Switch doorPiCall "doorPi call active"	<soundvolume>
String Echo_Living_TTS "Text to Speech" {channel="amazonechocontrol:echo:148fa16d:B0F00715603600UB:textToSpeech"}

openHAB Rules

rule "Switch ON doorPi lights"
	Channel 'astro:sun:local:set#event' triggered START  
rule "Switch OFF doorPi lights"
	Channel 'astro:sun:local:rise#event' triggered START  

rule "Hangup doorPi call when frontdoor is opened"
    Item ContactFrontDoor changed to OPEN
    if (doorPiCall.state == ON) {

rule "doorPi calling"
	Item doorPiCall changed to ON
    Echo_Living_TTS.sendCommand("Doorbell Is Ringing")

What is missing ?
A fancy widget for HABpanel to receive the video stream with integration of a JavaScript SIP client.


Did not forget about it! I will provide in the next few days!

This was not mentioned to push you George.:smiley:

1 Like

Hello dear,

Can doorPi work with any SIP intercom like 2N, Dahua without needing of SIP server? And it is ok to run doorPi on raspberryPI that hosts openHAB?

No, it can’t as it is using a SIP client for communication, so you need a SIP Server like Asterisk.
I would not recommend to run it on the same PI as openHAB, as you ideally locate it next to your doorbell.

Is there an updated instructions for Doorpi in english ? Would like to try this as it seems really cost effective compared to eg. Doorbird

Hi George,
any news on the SIP intercom widget?


DoorPi is a complete different project, so please ask specific questions on their community.