INSTAR Deutschland GmbHINSTAR Deutschland GmbH

homee Z-Wave Bridge



In the following tutorial I want to add a Fibaro Motion Sensor and an ABUS Indoor Siren to our network. Both will be connected using the Z-Wave wireless communications protocol with the help of the homee Gateway and Z-Wave Bridge Modul. The gateway will then function as a bridge between the wireless Z-Wave network and our INSTAR Full HD Camera.

Adding Z-Wave Components

To add the Z-Wave devices I first login to the homee administrator dashboard https://my.hom.ee - alternatively you can also use the homee iOS app - the Android app was not working at the time of writing:


Homee INSTAR Cameras


Go to the Devices tab and click the + button to add a new Z-Wave device:


Homee INSTAR Cameras


Select Z-Wave - Note you need to have the Z-Wave cube installed on your homee gateway. homee also offers a Zigbee and EnOcean cube that, of course, only works with devices that support those protocols:


Homee INSTAR Cameras


First I select the motion sensor from the following list:


Homee INSTAR Cameras


And follow the instruction to pair the Fibaro Motion Sensor - click on the green start button and then press the pair button on the motion sensor 3x fast:


Homee INSTAR Cameras


Once the sensor is paired you can give it a name and click Next:


Homee INSTAR Cameras


The sensor was successfully paired and is obviously already working:


Homee INSTAR Cameras


Now I repeat the previous steps with the ABUS Indoor Siren:


Homee INSTAR Cameras


Both Z-Wave devices are now paired with the homee gateway and can now be used logical IF-THEN chains that homee calls Homeegrams








Camera Alarmserver and homee Webhook

In this step I want to generate a web hook - a URL on the homee gateway that can be accessed by the Alarm Server on an INSTAR Full HD camera. This web hook is then contacted in case of an alarm on the camera and should trigger the ASUS siren I installed earlier.

Start by going to the Homeegrams tab and click the + button to add a new function:


Homee INSTAR Cameras


I am choosing the Webhook as the WHEN Condition for the script:


Homee INSTAR Cameras



Homee INSTAR Cameras


You can name your web hook and copy the complicated looking URL at the bottom - it should look something like this:

https://yourhomeeid.hom.ee/api/v2/webhook_trigger?webhooks_key=yourwebhookkey&event=OfficeCam_LocalWebhook

This is the path for your homee web hook - we can later test it by copying it into the address bar of our web browser and loading it. Whatever we will define in the next step as the THEN Condition of our script will be triggered by this URL.


Homee INSTAR Cameras


After saving those settings, we can now click on THEN to select our ABUS siren as the action we want to be triggered.


Homee INSTAR Cameras


Click on Device and pick the siren from the list below.


Homee INSTAR Cameras


When the web hook is triggered, we want the siren to switch on without a delay - click on Done to save those changes. Then repeat those steps - but define a switch off with a short delay (to prevent the siren from going off indefinitely!):

https://yourhomeeid.hom.ee/api/v2/webhook_trigger?webhooks_key=yourwebhookkey&event=OfficeCam_LocalWebhook

Homee INSTAR Cameras


We can now add the web hook URL to the Alarm Server settings our camera. But we are not going to use the web URL that we were given but use the local IP of our homee base station with the port 7681 instead - e.g. 192.168.2.49:7681:


Homee INSTAR Cameras


The server path is always /api/v2/webhook_trigger, the webhooks_key is the yourwebhookkey from the webhook URL above and event is the name you have given your webhook.

When triggern an alarm on your camera you should now see an entry inside your camera log that the alarm server (in this case the homee base station) was contacted. The siren should be triggered shortly afterwards.








INSTAR IP Cameras and external Z-Wave Motion Sensors

We now are able to contact the homee gateway with our camera in case of an alert. Let's do the opposite now. Whenever the Z-Wave Fibaro Motion Sensor is triggered I want to send an CGI command to my camera that triggers it to move to a different position. E.g. I have a camera that primarily is used to watch the entrance door. But when a person enters the room from the side entrance the motion sensor is triggered and should move into that direction while starting to record a video.

Again we start with writing a Homeegram and defining a WHEN Condition for the script:


Homee INSTAR Cameras


This time we need to select the Motion Sensor from the list:


Homee INSTAR Cameras


Select Motion Alarm and that you want to be alarmed when a motion is recorded:


Homee INSTAR Cameras


Next we need to define what we want to happen when our motion sensor is tripped:


Homee INSTAR Cameras


Here you need to choose the Webhook and use the CGI command as URL that sends your camera to the stored position 1:

192.168.2.116/param.cgi?cmd=preset&-act=goto&-number=1&-usr=admin&-pwd=instar

Here 192.168.2.116 is the IP address of the camera, admin is the user name for the administrator account on the camera and instar the corresponding password - change those accordingly.


Homee INSTAR Cameras


I refined the script a little bit by adding two further web hooks that are triggered with a delay of 5s and 15s. The first one triggers an alert on my camera that in turn triggers all active Alarm Actions. The second one makes it return to the original position once the entering persion was recorded:

192.168.2.116/param.cgi?cmd=pushhostalarm&-usr=admin&-pwd=instar

192.168.2.116/param.cgi?cmd=preset&-act=goto&-number=0&-usr=admin&-pwd=instar

Homee INSTAR Cameras









Day/Night Position

We now set up our camera to interact with both Z-Wave devices - we trigger alerts on our camera, when the external motion sensor is tripped and trigger the external siren, when our camera raises an alarm. But homee also offers us scheduled tasks, like triggering events at specific times of the day or at sunrise and sunset adjusted to our geo location.

This can be used to change the direction our camera is looking in based on the time of day. E.g. you want your camera to watch the front gate as long as it is bright outside. But once it is getting dark swing it towards the carport and keep an eye on car instead? Ok, let's start writing a Homeegram for that:


Homee INSTAR Cameras


As the WHEN Condition we now have to choose Sun Position (or choose Time if you need specific times) and select Sunrise first:


Homee INSTAR Cameras


On Sunrise our camera should be pointed towards the front gate:


Homee INSTAR Cameras


The front gate is stored as position one that can set to be the park position of our camera with the following command:

192.168.2.116/param.cgi?cmd=settimerpreset&-timerpreset_index=1&-usr=admin&-pwd=instar

Homee INSTAR Cameras


The script to move our camera to the Day Position is set. Now repeat those steps for the Night Position for Sunset using the following command to change the park position to stored position 3:

192.168.2.116/param.cgi?cmd=settimerpreset&-timerpreset_index=3&-usr=admin&-pwd=instar

Homee INSTAR Cameras


Make sure that you activated the Park Position inside your cameras PTZ Settings and adjust the time it should remain in a place before returning to the position with the slider below:


Homee INSTAR Cameras


Every time our camera is now moved it will automatically return to the park position after a while. And the park position will now change according to the time of day.








Deactivate Alarm when you are Home

Beside time schedule you can also use the provided Mode System to trigger scripts on your homee gateway. I want to create two scripts that activate the alarm schedule for my camera, when I set my homee to Away and to deactivate the schedule again, when I arrive back home and set it to Home.

Let's start with the Deactivate Alarm when I am Home script:


Homee INSTAR Cameras


The used CGI command for this web hook is:

192.168.2.116/param.cgi?cmd=setscheduleex&-ename=md&-week0=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN&-week1=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN&-week2=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN&-week3=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN&-week4=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN&-week5=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN&-week6=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN&-usr=admin&-pwd=instar

Now to the Activate Alarm when I am Away script:


Homee INSTAR Cameras


192.168.2.116/param.cgi?cmd=setscheduleex&-ename=md&-week0=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP&-week1=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP&-week2=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP&-week3=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP&-week4=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP&-week5=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP&-week6=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP&-usr=admin&-pwd=instar

Homee INSTAR Cameras


Those two scripts will completely wipe the alarm schedule - not allowing alarms to be triggered - when your homee is set to Home. And once you set it to Away the schedule will be filled for a 24/7 surveillance:


Homee INSTAR Cameras