Doorbird video doorbell binding

Important Update:

  • The binding was merged into to the openHAB distribution today, Oct 17. It should be available in a snapshot release after build 1728, as well as the next milestone release.

  • We made several changes to the binding throughout the review process:

    • The restart and sipHangup channels were removed. They were replaced by the thing actions restart() and sipHangup() that can be called from within rules. There’s an example in the README.
    • The doorbell channel was redefined to be a system.rawbutton channel that will generate trigger events PRESSED and RELEASED. If you want to use this channel with a Switch item, you need to add the rawbutton-on-off-switch profile to the channel definition. There’s an example of this in the README. If you’re not running a recent snapshot, this won’t work because the rawbutton-on-off-switch profile was recently added to the openHAB core. Instead, you may need to define a proxy item and update its state in a rule that triggered off the PRESSED and RELEASED events.
    • The getImage channel was removed. To refresh the image channel, send a REFRESH command to the item linked to the image channel.

End of update.

I’ve been developing a binding for the Doorbird doorbells. If anyone is interested in trying it out, the binding jar file and related 3rd party dependencies can be found here.

Features include:

  • support for models D101 and D210x (note I don’t have a D210x, so that model has not been tested)
  • channels for doorbell pressed and motion detected events, including switch channels, timestamp channels, and image channels
  • image channel that can be refreshed on a user defined number of seconds
  • image and timestamp channels for retrieving historical images and timestamps for button press and motion detected events
  • history image “montage” channels for displaying a montage (photo strip) of the last n doorbell press and/or motion history images
  • channels for triggering open door and light relays
  • all interactions with the Doorbird are done directly (i.e. no cloud) with the exception of the retrieval of the doorbell and motion history images, which the Doorbird pulls from the cloud

Please post back here with any issues or feature requests.

Thanks to @swamiller for helping me test the binding.

Thanks to @dastrix80 for testing some of the new features, as well as the D210x.

Thanks to @Skibi for testing on the RPi. The binding now should work on the RPi2 and Rpi3.

Thanks to @Novanoid for helping me sort out the issues with multiple Doorbirds.

18 Likes

Awesome Mark!
Another reason to get the doorbird

1 Like

Great! That binding was what i was waiting for before buying a doorbird!

Niiiiiicccee Mark! Ill definitely test as I have the D2101x

Look forward to the video feature and switch for RFID

Great. Let me know how it works.

This may be a while, as it’s not supported in the API spec at the moment (although there is something in there that says it’s coming). I’ll email their support to find out if there are really plans to add it.

Hi Mark, i had spoke to them and its coming yes. There is an ability right now with RFID, I have setup the Doorbird to send a HTTP request when the RFID is used to turn on my RFID switch item so there is already some functionality.

@dastrix80 That’s good to know. If they add it to the UDP event stream, it should be pretty easy to add to the binding.

1 Like

Hi @mhilbush once the two binding files are added, is the thing added as per normal by hitting + under THINGS in paperui? Or do we require a THING file ? If so, do you have a sample.

You can create it using Paper UI and/or with a .things file. I just haven’t written the sample .things file yet.

OK. I installed both files, the dependency first, but the binding isnt listed in the karaf console.


openhab> bundle:list | grep door
openhab> bundle:list | grep bird
openhab> bundle:list | grep bird
openhab>


kris@ihp:/usr/share/openhab2/addons$ ls
doorbird-deps-1.0.0.jar   org.openhab.binding.amazonechocontrol-2.5.0-SNAPSHOT.jar  org.openhab.binding.doorbird-2.5.0-SNAPSHOT.jar  org.openhab.binding.unifi-2.3.0-SNAPSHOT.jar  README
openhab-addons-2.4.0.kar  org.openhab.binding.broadlink-2.2.0-BETA2.jar             org.openhab.binding.ipcamera-2.5.0-SNAPSHOT.jar  org.openhab.binding.zwave-2.5.0-SNAPSHOT.jar
kris@ihp:/usr/share/openhab2/addons$

Hmm.

It should look like this. What version of openHAB are you running?

openhab> bundle:list | grep bird
277 │ Active   │  80 │ 2.5.0.201905031150     │ openHAB Add-ons :: Bundles :: Doorbird Binding
278 │ Active   │  80 │ 1.0.0                  │ doorbird-deps bundle

Or

openhab> list -s | grep doorbird
277 │ Active   │  80 │ 2.5.0.201905031150     │ org.openhab.binding.doorbird
278 │ Active   │  80 │ 1.0.0                  │ doorbird-deps

Hi Mark, 2.4.0 stable

Hmm. I running it on a 2.5 snapshot, and it’s a fairly old snapshot version (build 1502). That build was prior to the ESH reintegration work, and the conversion to the new build system. So, if it runs on that, it should run on 2.4 stable.

Is there anything in the logs?

What hardware are you running?

Hi Mark

Xeon 3.5ghz, under a QNAP NAS. Nothing in events, openhab or syslog

The fact that the dependency bundle isn’t showing up is really odd.

What is the size of the jar files in addons? Are you sure you downloaded the jar files? Did you right-click SaveAs on the jar file links, or did you click on the jar file links, then press the Download button? The former will get you an HTML file.

$ ls -l /opt/openhab2/addons
total 8448
-rw-r--r-- 1 mark mark 3824192 Apr 23 08:12 doorbird-deps-1.0.0.jar
-rw-r--r-- 1 mark mark   25079 May  3 07:50 org.openhab.binding.doorbird-2.5.0-SNAPSHOT.jar

Edit: Your doorbird binding might not be exactly the same size, as I’m running a newer version that what’s posted in my Github repo.

If you want to define the thing in a .things file, you would do something like this. The last three parameters are optional, and could be removed, if desired. Note I haven’t tested these…

doorbird:d101:doorbell
    "Doorbird D101 Doorbell"
    [
        doorbirdId="1",
        doorbirdHost="your.doorbird.host",
        userId="ghpcaa0002",
        userPassword="KJUyhgbvdr",
        imageRefreshRate=120,
        doorbellOffDelay=2,
        motionOffDelay=60
    ]

Or

doorbird:d210x:doorbell
    "Doorbird D210x Doorbell"
    [
        doorbirdId="1",
        doorbirdHost="your.doorbird.host",
        userId="ghpcaa0002",
        userPassword="KJUyhgbvdr",
        imageRefreshRate=120,
        doorbellOffDelay=2,
        motionOffDelay=60
    ]
1 Like

See below:

total 185300
-rw-rw-r-- 1 kris    kris        81171 May  4 05:49 doorbird-deps-1.0.0.jar
-rw-r--r-- 1 openhab openhab 182006216 Dec 17 19:00 openhab-addons-2.4.0.kar
-rw-r--r-- 1 root    root       172671 Apr 26 11:03 org.openhab.binding.amazonechocontrol-2.5.0-SNAPSHOT.jar
-rw-rw-r-- 1 kris    kris        56877 Apr 25 08:30 org.openhab.binding.broadlink-2.2.0-BETA2.jar
-rw-rw-r-- 1 kris    kris            0 May  4 05:49 org.openhab.binding.doorbird-2.5.0-SNAPSHOT.jar
-rw-rw-r-- 1 kris    kris      4742312 Apr 25 08:30 org.openhab.binding.ipcamera-2.5.0-SNAPSHOT.jar
-rw-rw-r-- 1 kris    kris        39315 Apr 25 08:30 org.openhab.binding.unifi-2.3.0-SNAPSHOT.jar
-rw-rw-r-- 1 kris    kris      2631747 Apr 25 08:12 org.openhab.binding.zwave-2.5.0-SNAPSHOT.jar
-rw-r--r-- 1 openhab openhab        70 Dec 17 19:01 README

-rw-rw-r-- 1 kris kris 81171 May 4 05:49 doorbird-deps-1.0.0.jar

That’s definitely not right. Should be almost 4 MB.

-rw-rw-r-- 1 kris kris 0 May 4 05:49 org.openhab.binding.doorbird-2.5.0-SNAPSHOT.jar

Zero bytes? That doesn’t look good either.

Try downloading again.

1 Like

Hi Mark,

Light and Relay Open work. THING is recognised fine. I’m not entirely sure how to display the Images in a HabPanel UI but so far so good!