INSTAR Deutschland GmbH

OpenHAB 2 Home Automation

Introduction

OpenHAB runs on your hardware, doesn't require any cloud service to work, keeps your data privately at home and talks directly to your local devices whenever possible. At the core of our philosophy is that you always remain in control.

In the following paragraphs we want to show you how to connect external wireless sensors through the ioBroker system with your INSTAR IP camera, set up time schedules for your surveillance and optimize your camera operation.

If you are looking for a deep dive into setting up your OpenHAB 2 automation with an INSTAR IP camera, switch to our FULL GUIDE instead.

How does it work

1. Use external Sensors

Triggering an alarm on the camera by an event registered by your home automation system (Full HD models only):

OpenHAB2

/param.cgi?cmd=pushhostalarm&-usr={USERNAME}&-pwd={PASSWORD}



2. Activate Nightvision only when Motion is detected

Activate your cameras night vision according to a schedule or triggered by an external sensor integrated in home automation system:

OpenHAB2

/param.cgi?cmd=setinfrared&-infraredstat=auto&-usr={USERNAME}&-pwd={PASSWORD}
/param.cgi?cmd=setinfrared&-infraredstat=close&-usr={USERNAME}&-pwd={PASSWORD}

The activation of the night vision in case of an alarm is of course only possible if the camera has an internal PIR sensor for motion detection, or if you use the alarm signal of an external sensor in home automation to "focus" the camera. The advantage - the camera is inconspicuous at night and the IR light attracts no insects / spiders. And the power consumption is of course also pressed.




3. Schedule different Positions

Scheduled day and night position - guard the front door when I'm not at home but I turn the camera to my carport when I'm back from work:

OpenHAB2

/param.cgi?cmd=preset&-act=goto&-number=0&-usr={USERNAME}&-pwd={PASSWORD}
/param.cgi?cmd=preset&-act=goto&-number=1&-usr={USERNAME}&-pwd={PASSWORD}



4. Use different Detection Areas for each Position

In combination with the scheduled day and night position (see above) you can also activate different motion detection areas - in the example the areas 1 & 2 are activated during the day and the areas 3 & 4 at night:

OpenHAB2

/param.cgi?cmd=setmdattr&-name=1&-enable=1&cmd=setmdattr&-name=2&-enable=1&cmd=setmdattr&-name=3&-enable=0&cmd=setmdattr&-name=4&-enable=0&-usr={USERNAME}&-pwd={PASSWORD}

/param.cgi?cmd=setmdattr&-name=1&-enable=0&cmd=setmdattr&-name=2&-enable=0& cmd=setmdattr&-name=3&-enable=1&cmd=setmdattr&-name=4&-enable=1&-usr={USERNAME}&-pwd={PASSWORD}



5. Use different Sensitivities for Day & Night

Since there are often different sensitivities needed for the motion detection during day and night conditions, you can also adjust these - in the example to 75% during the day and 25% at night:

OpenHAB2

/param.cgi?cmd=setmdattr&-name=1&-s=75&-usr={USERNAME}&-pwd={PASSWORD}

/param.cgi?cmd=setmdattr&-name=1&-s=25&-usr={USERNAME}&-pwd={PASSWORD}



6. Turn off all Cameras when you arrive home

Either schedule or manually disable all alarm detection areas and the PIR sensor, if you do not want to trigger an alarm:

OpenHAB2

/param.cgi?cmd=setmdattr&-name=1&-enable=0&cmd=setmdattr&-name=2&-enable=0&cmd=setmdattr&-name=3&-enable=0&cmd=setmdattr&-name=4&-enable=0?cmd=setpirattr&-pir_enable=0&-usr={USERNAME}&-pwd={PASSWORD}

/param.cgi?cmd=setmdattr&-name=1&-enable=1&cmd=setmdattr&-name=2&-enable=1&cmd=setmdattr&-name=3&-enable=1&cmd=setmdattr&-name=4&-enable=1?cmd=setpirattr&-pir_enable=1&-usr={USERNAME}&-pwd={PASSWORD}

Please note for the models IN-6014 HD and IN-9020 Full HD, instead of the PIR sensor - setpirattr&-pir_enable=1 - the alarm input must be switched: cmd=setioattr&-io_enable=1. The same applies to cameras where an external PIR sensor is attached to the alarm input.




7. Use external Sensors to turn your Camera when Motion is detected

Let your camera move between positions depending on system variables in home automation system. For example - when the door sensor is tripped, look to the door, when the window sensor is triggered turn towards the window and when the external motion sensor detects a person, turn to the kitchen door:

OpenHAB2

/param.cgi?cmd=preset&-act=goto&-number=0&-usr={USERNAME}&-pwd={PASSWORD}
/param.cgi?cmd=preset&-act=goto&-number=1&-usr={USERNAME}&-pwd={PASSWORD}
/param.cgi?cmd=preset&-act=goto&-number=2&-usr={USERNAME}&-pwd={PASSWORD}

etc.

This can be combined well with the parking position in the camera - the camera then automatically returns to the standard position after x minutes.




8. Use external Sensors to trigger Alarm Recordings

When you set up your camera to turn to a position when triggered by an external sensor, you probably want to start an alarm recording on the internal SD card to catch the intruder. This can be done by starting the manual recording through your home automation system and after a delay following up the stop command. Due to adjustable delay, the length of the alarm video is freely selectable:

OpenHAB2

/param.cgi?cmd=manualrec&-act=on&-time=60&-usr={USERNAME}&-pwd={PASSWORD}

/param.cgi?/cmd=manualrec&-act=off&-usr={USERNAME}&-pwd={PASSWORD}



9. Scan for Noise Sources

For example, when triggering the audio detection on your camera, you probably do not know the location of the source of the noise. Here you can trigger a horizontal (hscan) or vertical (vscan) search scan. This must then be manually stopped again with the desired delay:

OpenHAB2

/param.cgi?cmd=ptzctrl&-step=0&-act=hscan&-usr={USERNAME}&-pwd={PASSWORD}
/param.cgi?cmd=ptzctrl&-step=0&-act=vscan&-usr={USERNAME}&-pwd={PASSWORD}

/ptzctrl.cgi?-step=&-act=stop

Alternatively you can use the tour function to move between pre-defined positions specified in the WebUI to a maximum of 50 times (except for the model IN-9020 Full HD, which will run the programmed tour until you stop it manually):

/param.cgi?cmd=ptzctrl&-step=0&-act=tour&-usr={USERNAME}&-pwd={PASSWORD}



10. Manually deactivate all Alarm functions for all your Cameras

If you have activated more than one alarm trigger in your camera - PIR sensor, alarm areas, audio detection, alarm input - you can activate and deactivate them all at once via the alarm schedule without addressing each trigger individually:

OpenHAB2

/param.cgi?cmd=setscheduleex&-ename=md&-week0=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN NNNN&-week1=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN NNNN&-week2=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN NNNN&-week3=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN NNNN&-week4=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN NNNN&-week5=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN NNNN&-week6=NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN NNNN&-usr={USERNAME}&-/param.cgi?pwd={PASSWORD}

/param.cgi?cmd=setscheduleex&-ename=md&-week0=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP PPPP&-week1=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP PPPP&-week2=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP PPPP&-week3=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP PPPP&-week4=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP PPPP&-week5=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP PPPP&-week6=PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP PPPP&-usr={USERNAME}&-/param.cgi?pwd={PASSWORD}

In this command, week0 - week6 stands for Monday through Sunday and each P is half an hour of the day the alarm schedule is active (48 x 30min = 24h). An N equals a 30-minute period in which it is disabled. The schedule activates / deactivates all alarm actions.