DoorBird Review

Posted on
Sun Jul 30, 2017 3:12 am
berkinet offline
User avatar
Posts: 3289
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: DoorBird Review

agame wrote:
...Being new to Indigo I'm still at a loss to grasp where to place the code on this post? (On vera I would be adding some to a startup script and the remainder on triggers.) Gonna have to study harder.
Sorry... I was on a small screen and didn't check on the specific posts you should look at. First see this post from @neilk, it gives the general locations and methods for making it work. Then, Check out the final revised script in this post (This is really the only script you will need).

Basically, you are creating a background script that Indigo will run on startup. That script will listen for events received from your DoorBird and take tell Indigo to run some arbitrary action group. Here is the code bit that for starts an action group for a Button Push (doorbell rung) event:
Code: Select all
if self.path == "/doorbell":
            indigo.server.log("DoorBird sent doorbell command", type="DoorBird")
            indigo.actionGroup.execute(actionBell)
The actual action is set earlier in the code with this line I.e., this is the line you will need to change...
Code: Select all
actionBell = 384010246       # ID of Action Group to run on the Doorbell rings.

So, basically,
  1. Follow the instructions to add an event to the DoorBird
  2. Place the script in some convenient location (like: /Library/Application Support/Perceptive Automation/Indigo 7/Scripts/Attachments
  3. Create an action to make your SONOS announcement
  4. Edit the script to change the action code to the code of your new action
  5. Ring the DoorBird

Good luck and post back here if you need any help.

Posted on
Sun Jul 30, 2017 3:17 am
agame offline
Posts: 514
Joined: Jul 13, 2017
Location: Melbourne, Australia

Re: DoorBird Review

thanks indeed for stepping through that. lets see how I go!

Posted on
Sun Jul 30, 2017 3:23 am
neilk offline
Posts: 713
Joined: Jul 13, 2015
Location: Reading, UK

Re: DoorBird Review

I now have the two devices patched together but as I expected its a bit flakey so would love to get on top of implementing this solution.


Happy to help.

1) Install the HTTPd Plugin for IFTTT Maker integration . NOTE I am not suggesting using the IFTT piece, simply using FlyingDivers local server to get around the simple authentication issue. No need to do anything in IFTTT or to do any port forwarding to make this work.

Using the username, password and port number and the local IP address of your indigo server the url per action would become :-

Code: Select all
http://username:password@indigolocalip:portnum/setvar?doorbird=pressed
http://username:password@indigolocalip:portnum/setvar?doorbirdmotion=detected
http://username:password@indigolocalip:portnum/setvar?doorbirdopen=pressed


This will create the variables for you (when triggered) prepended with http_doorbird in a folder HTTPd

You can test the urls (obviously the door open is only useful if you want to do something in indigo if the user presses the door open button in the door bird app) by putting them into your browser

2) Create a trigger based on a change to the http_doorbird variable (and motion and open if you wish to use them). In the trigger do the actions you wish, such as your sonos annoucement,and add a final action to set the http_doorbird variable back to another value like "nontpressed"

3) Create the long URL you need to subsrcibe to the door bird notification, much as you would have done on the vera, it will look something like this

Code: Select all
http://<doorbirduser>:<doorbirdpass>@<doorbirdip>/bha-api/notification.cgi?url=<your url from above>&event=doorbell&subscribe=1


I would need to try it so set the actual URL, as you may trip up on URL encoding, and for some reason this only worked for me on Chrome. It is also possible you may need to split out the username and password as parameters rather than in the form above so the <your url from above> becomes http://indigolocalip:portnum/setvar?doo ... ssed&user=<your httpdplugin user>&password=<your http plugin password>&event=doorbell&subscribe=1

4) Test the doorbell, rinse and repeat for motion and door open notifications

If this works I will then walk you through the image capture part as I do it and then we can end up with hopefully a definitive guide for setting this up. I cannot test it real time but the only tricky bit is the subscription URL on the door bird.

Thanks,
Nei
Last edited by neilk on Sun Jul 30, 2017 3:59 am, edited 1 time in total.

Posted on
Sun Jul 30, 2017 3:30 am
berkinet offline
User avatar
Posts: 3289
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: DoorBird Review

neilk wrote:
... the need for a plugin is even less now as this plugin

http://forums.indigodomo.com/viewtopic.php?f=216&t=17281

Does the job of the script I hacked far more elegantly from a configuration and install perspective. ...

Well, I wouldn't argue about the configuration and install perspective. However, it does so at the expense of involving cloud based resources and latency sending a message across the Internet and back just to tell you someone is at your door.

As noted way back in this thread, the most direct way to deal with this [announcement issue] would be to tie the DoorBird's Button Closure contacts to some I/O sensor (Insteon, Z-Wave, EasyDAQ, Phidget, etc.) and have Indigo monitor the I/O sensor in a trigger with an action to make an announcement. However, using DoorBird events (the most direct means, but conceptually a bit more difficult to grasp) also addreses the whole issue locally.

The following "laws" come to mind...
  • A complex system that works is invariably found to have evolved from a simple system that works.
  • It is simple to make something complex, and complex to make it simple.
  • Due to the strong coupling between components in complex systems, a failure in one or more components can lead to cascading failures which may have catastrophic consequences on the functioning of the system.
  • A complex system can fail in an infinite number of ways.
YMMV

Posted on
Sun Jul 30, 2017 3:44 am
neilk offline
Posts: 713
Joined: Jul 13, 2015
Location: Reading, UK

Re: DoorBird Review

Berkinet,
I am not suggesting using IFTTT itself, simply hijacking the mechanism that FlyingDiver wrote which essentially deals with the same issue of authentication and a local server but doesn't require hard coding the action groups. Should make it clear I am only suggesting (as an alternative to manually updating my script) and I have not tried it. No need to go anywhere near the cloud or IFTTT, and no need to do any port forwarding. I updated the post to make that clear as of course the name of the plugin makes it look that way, it could actually be used generically by any local network IOT device.
Thanks,
Neil

Posted on
Sun Jul 30, 2017 6:16 am
FlyingDiver offline
User avatar
Posts: 7184
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: DoorBird Review

I changed the title of that forum posting to make it clear that the plugin isn't solely for IFTTT. The name of the plugin has always been "HTTPd". It was never only for IFTTT.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Sun Jul 30, 2017 7:44 am
berkinet offline
User avatar
Posts: 3289
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: DoorBird Review

neilk wrote:
...I am not suggesting using IFTTT itself, simply hijacking the mechanism that FlyingDiver wrote which essentially deals with the same issue of authentication and a local server but doesn't require hard coding the action groups. Should make it clear I am only suggesting (as an alternative to manually updating my script) and I have not tried it. No need to go anywhere near the cloud or IFTTT, and no need to do any port forwarding. ...

Thanks for the clarification. And, I admit I didn't look at the suggestion all that carefully. The HTTPd does look like it would solve a lot of connection problems. Though, in this particular issue, there is no need for authentication and a simple script is pretty easy to manage. One thought, The need to edit the script could be removed completely if it read the Action IDs for the three events from variables with static names, like: actionMotion, actionOpen & actionBell. Then the user would only have to place the script somewhere, set a startup action to run it and and define the needed variables.

Posted on
Tue Aug 01, 2017 3:44 am
agame offline
Posts: 514
Joined: Jul 13, 2017
Location: Melbourne, Australia

Re: DoorBird Review

Ok. So I have the script implemented. the server is working because I get a good response to any URL calling the server iP and port (it rejects back whatever text follows the url).

Sometimes this is reflected in the log, and I get the action to execute. But then it stops working.. still a good response on a test browser page but no log entry or action.

any ideas?

Posted on
Tue Aug 01, 2017 3:52 am
berkinet offline
User avatar
Posts: 3289
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: DoorBird Review

agame wrote:
Ok. So I have the script implemented. the server is working because I get a good response to any URL calling the server iP and port (it rejects back whatever text follows the url).

Sometimes this is reflected in the log, and I get the action to execute. But then it stops working.. still a good response on a test browser page but no log entry or action.

any ideas?

Can you be more specific about "stops working." Do you see the script running in the Activity Monitor; is the incoming http request received and logged; does the Action execute; is the SONOS plugin called; is a message sent to your SONOS system?

Posted on
Tue Aug 01, 2017 4:10 am
agame offline
Posts: 514
Joined: Jul 13, 2017
Location: Melbourne, Australia

Re: DoorBird Review

berkinet wrote:
agame wrote:
Ok. So I have the script implemented. the server is working because I get a good response to any URL calling the server iP and port (it rejects back whatever text follows the url).

Sometimes this is reflected in the log, and I get the action to execute. But then it stops working.. still a good response on a test browser page but no log entry or action.

any ideas?

Can you be more specific about "stops working." Do you see the script running in the Activity Monitor; is the incoming http request received and logged; does the Action execute; is the SONOS plugin called; is a message sent to your SONOS system?


Hi Berkinet thanks for responding!

I'm not sure if I may have sorted it out just after posting...right now the whole thing is working perfectly, after an indigo server restart.

The symptom of 'not working' is the url appearing to execute fine from a browser, but nothing at all appearing in the indigo log (and no action). Anyhow this is the first time I've seen it going from end-to-end so fingers crossed!

Posted on
Thu May 03, 2018 10:07 pm
agame offline
Posts: 514
Joined: Jul 13, 2017
Location: Melbourne, Australia

Re: DoorBird Review

By way of an update for anyone looking to integrate Doorbird, it works very well.

I've just streamlined my Doorbird integration using the HTTPd plugin to receive events (finally overcoming the authentication problems I was having), and the Cynical Security Spy (and a couple of small scripts) to capture images and video based on events. Pushover sends push notifications (including images).

While it works extremely well, it seems Doorbird are deprecating the http notification paradigm, and instead have launched a UDP listening model. Very elegant, very secure, but lots of decryption would need to be coded. Hopefully the current model will continue indefinitely but if anyone wants a big coding challenge take a look at the LAN to LAN door bird api spec!

Posted on
Tue May 22, 2018 9:49 am
berkinet offline
User avatar
Posts: 3289
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: DoorBird Review

lanbrown wrote:
Looks like DoorBird has released an official API:
... ...Their API doesn't require the use of the cloud either.
They also added geofencing for triggering the relay.

That actually looks like a minor update. It is the same API that have had for a while. I have a script that runs on Indigo startup that implements the required HTTP server. I am using it to capture images on motion triggers. If you are interested in a copy, PM me with your email address. One note: for API motion events, the masking of the camera image is not applied as it is for local and cloud storage. So, you get triggers on anything that moves within sight of the camera.

The geofencing only sort of works for me. Maybe 25% of the time. Probably a factor of the relatively poor mobile IP connectivity near my location.

Posted on
Tue May 22, 2018 6:49 pm
kidney offline
Posts: 237
Joined: Jul 15, 2007

Re: DoorBird Review

HI!

Are neilk instruction still valid?
Also do you need a cloud sub for this to work?

Posted on
Tue May 22, 2018 9:21 pm
tazswe offline
Posts: 211
Joined: Mar 13, 2017
Location: Sweden

Re: DoorBird Review

kidney wrote:
HI!

Are neilk instruction still valid?
Also do you need a cloud sub for this to work?


I am running neilk instructions on both my Doorbirds so yes they are still valid.


Skickat från min iPad med Tapatalk

Posted on
Tue May 22, 2018 9:24 pm
tazswe offline
Posts: 211
Joined: Mar 13, 2017
Location: Sweden

Re: DoorBird Review

berkinet wrote:
lanbrown wrote:
Looks like DoorBird has released an official API:
... ...Their API doesn't require the use of the cloud either.
They also added geofencing for triggering the relay.

That actually looks like a minor update. It is the same API that have had for a while. I have a script that runs on Indigo startup that implements the required HTTP server. I am using it to capture images on motion triggers. If you are interested in a copy, PM me with your email address. One note: for API motion events, the masking of the camera image is not applied as it is for local and cloud storage. So, you get triggers on anything that moves within sight of the camera.

The geofencing only sort of works for me. Maybe 25% of the time. Probably a factor of the relatively poor mobile IP connectivity near my location.


It’s a pity that masking doesn’t work, one of my cameras are facing the road and are useless as a motion trigger.


Skickat från min iPad med Tapatalk

Page 4 of 10 1, 2, 3, 4, 5, 6, 7 ... 10

Who is online

Users browsing this forum: No registered users and 0 guests