IpCamera: New IP Camera Binding

Embarrassingly, it was a typo in the sitemap. Thanks for all your help.

1 Like

this seems exactly my same problem.


Is there a limit on how many presets you can have? In my camera (Dahua - DH-SD1A203T-GN-S2) has 6 presets configured, and working in the app of the camera itself. But in openhab, I can only use the first 3?

This is my sitemap:

Switch item=CamSerOnvifPreset2 mappings=[1=Algemeen]
Switch item=CamSerOnvifPreset2 mappings=[2=Inkom]
Switch item=CamSerOnvifPreset2 mappings=[3=Bureau]
Switch item=CamSerOnvifPreset2 mappings=[4=Trap]
Switch item=CamSerOnvifPreset2 mappings=[5=Bar]
Switch item=CamSerOnvifPreset2 mappings=[6=Kelder]```

The binding does have a limit, guessing it is around 25 from memory and that is easily increased if people request it. The binding only fetched the presets when the binding starts so any added after it has started won’t work until you restart the binding. Onvif has tokens which means you can’t send a gopro preset 4 as the binding has to ask and store the token before it can be sent. I could look at changing a number of things with preset use so feel free to give some feedback.


The mission - find a doorbell IP camera that works with this binding, but that does not have to “phone home” in order to work. It is acceptable if the camera needs to connect to the Internet to be configured initially, but after that, I want this camera, and all of my other IP cameras, to operate on a closed network with no connection to the outside world. (Why? Because I don’t trust any of these devices from a security standpoint farther than I can throw them.)

Success thus far - none. I am hoping you can help.

I have spent the last two days working with a Hikvision DS-HD1 and an Amcrest AD110. While these cameras are different mechanically (the Hikvision seems to be better built), they are running very similar software. Neither camera seems to offer up a configuration web page. Both cameras require you to download an app on your mobile device. Both cameras set up a temporary hot-spot. Both configuration apps require that your mobile device be connected to the Internet via WiFi. The app seems to move the mobile device over to the camera’s hotspot and then transfer the Internet WiFi credentials to the doorbell. After that, the doorbell moves to your Internet WiFi, pulls a DHCP address, and phones home. The app moves your mobile device back to your Internet network as well. From there, you continue the configuration process.

It is hard to know what happens after that, but I can guess from some of the Wireshark captures I have of the process. It seems that, as you move through the configuration process, TLS-encoded messages from the app go to some cloud-based servers, and then encrypted configuration information is sent to the camera.

nmap scans show two open ports running http - port 80 and port 8000. RTSP appears to be running on port 554. From what I can tell, an HTTP server is running on port 80, but it does not serve up a home page, and I get no responses when I try some queries from a Hikvision API document I found on the web.

Once the cameras were configured, I scanned the network with nmap and found their IP addresses. I disconnected the Internet and powered everything back up. Seems the cameras got upset that they could no longer phone home. Also, there is no web page where you can assign the cameras a static IP address. When I powered them back up, they had pulled new DHCP addresses.

I have not checked the Hikvision yet, but it appears that the Amcrest is not running ONVIF.

I have a lab running at the moment and am happy to run any captures or perform other experiments.

Has anyone had any luck using either of these products, or any other video doorbell of any kind? Any help would be greatly appreciated.

There are a number of cameras that are all the same which you can flash the firmware from another brand onto them to get ONVIF. Google the hikvision as it is one of them and by using the wrong firmware you can get onvif support if it does not have it directly. Big note on them is that you can not get notified when the button is pushed, more on this in a linked thread below for a hack/ work around to get the button push using reed switch in a buzzer/bell.

Short answer is there are no cheap ready made solutions. But look at these to see if any offer a different way to look at a front door camera.

Consider using the Dahua IPC-HDBW4231E-ASE or similar models and you can connect any doorbell push button up to the ALARM io to get the notifications into openhab. The alarm output can also trigger a bell/buzzer. There is also a second way in this post…

There is also a esp32 cam that can be used to make your own, but the picture quality is low as is the price, no night vision and due to no h264 you can not cast them.

Another model to look at would be the INSTAR IN-6001HD as you could surface mount that very easily and fit a zwave or other button next to it.

Lastly Doorbird make a range and the doorbird API is implemented as well as having a stand alone binding for Openhab.

It did the trick, a simple restart of the binding (sounds like windows :wink: ), and all presets can be used.

I run a Ezviz db1, which is a Hikvision clone. I have it connected to a Hikvision NVR, hence it works perfectly fine with this binding. (I guess it would work straight from the doorbell as well, since it is rtsp compatible). I have connected an ac relay to it, instead of a mechanical doorbell. On the “dc side” of the relay, I have fitted a cheap xiaomi aqara Zigbee pushbutton. That way I can set up time based rules for the indoor chime (low volume in the evening and off during the night) and push images/streams from the doorbell. The only thing that doesn’t work using this setup are notifications from the PIR sensor.

@Daniel_Linder using the Hikvision NVR, does your configuration require that the devices on the network be able to communicate with Hivision’s servers on the Internet, or once the initial configuration is done, can you disconnect the Internet and have the system still function? I have not yet looked into the Hikvision NVR.

@matt1thanks very much for this. I have time and am willing to put some effort into this to help the OH community, as this seems to be a pretty common issue. If there are specific things I can test in order to contribute to your work, please let me know.

I will look into the links and will also check into flashing the Hikvision doorbell with a different version of software. Back in a bit after I do a little reading.

Please I need your help.
I’m trying to understand what I’m wrong, but I can’t get out of it.

This is my items:

Switch GiardinoPostGif "Create animated GIF" { channel="ipcamera:HIKVISION:GiardinoPost:updateGif" }
Dimmer GiardinoPostLED "IR LED [%d]" { channel="ipcamera:HIKVISION:GiardinoPost:enableLED" }
Switch GiardinoPostAutoLED "Auto IR LED" { channel="ipcamera:HIKVISION:GiardinoPost:autoLED" }
String GiardinoPostTextOverlay "Text to overlay" { channel="ipcamera:HIKVISION:GiardinoPost:textOverlay" }
String GiardinoPostAPIAccess "Access the API" { channel="ipcamera:HIKVISION:GiardinoPost:apiAccess" }
String GiardinoPostStreamUrl "Mjpeg Stream" { channel="ipcamera:HIKVISION:GiardinoPost:streamUrl" }
String GiardinoPostHlsStreamUrl "HLS Stream" { channel="ipcamera:HIKVISION:GiardinoPost:hlsUrl" }
String GiardinoPostRTSPStreamUrl "RTSP Stream" { channel="ipcamera:HIKVISION:GiardinoPost:rtspUrl" }
Switch GiardinoPostStartHLS { channel="ipcamera:HIKVISION:GiardinoPost:startStream" }
Switch GiardinoPostEnableMotionAlarm "MotionAlarm on/off" { channel="ipcamera:HIKVISION:GiardinoPost:enableMotionAlarm" }
Switch GiardinoPostMotionAlarm "Motion detected" { channel="ipcamera:HIKVISION:GiardinoPost:motionAlarm" }
Switch GiardinoPostEnableLineAlarm "LineAlarm on/off" { channel="ipcamera:HIKVISION:GiardinoPost:enableLineCrossingAlarm" }
Switch GiardinoPostLineAlarm "Line Alarm detected" { channel="ipcamera:HIKVISION:GiardinoPost:lineCrossingAlarm" }

my thing file:

Thing ipcamera:HIKVISION:GiardinoPost "GiardinoPost" @ "Cameras"


My sitemap:

        Text label="Cameras Mjpeg Stream" icon="camera"{Video url="" encoding="mjpeg"}
        Text label="Snapshot 1FPS Stream" icon="camera"{Video url="" encoding="mjpeg"}
        Text label="autofps Stream" icon="camera"{Video url="" encoding="mjpeg"}
        Text label="HLS Video Stream" icon="camera"{Video url="" encoding="hls"}
        Text label="HLS Webview Stream" icon="camera"{Webview url="" height=15}
        Text label="Image using jpg method" icon="camera"{Image url="" refresh=1000}

My log file:
log.pdf (41.5 KB)

I downloaded JAR file from:
Changed the log level

I thank you if you want to help me


Your sitemap URLs are wrongly using the ip of the camera. Change to using the ip of your openhabs server. The binding has string channels that contain the URLs for you if the ip is not static.

TnX matt1.
Now I have:
1FPS = working
autofps = I have a still picture
JPG method = working

All the other are still not working.


I dont understand your sitemap at all. It contains no items, but insted it contains urls in curly brackets… I dont see how this is possible… Or is it a not documented feature of sitemaps?

I posted only the rows concerning the camera binding.
The documentation concerning the Binding is here:


Youre right… Its the same as the binding docs… I wonder how come this isn´t listed in the official openhab doc for sitemaps:

Good day matt, can I add the option to disable channel polling?
I will explain why this is necessary - if you connect the link to the hikvision NVR, it will start reading the input and output channels for each connected camera to the nvr.
This, firstly, creates an additional load on the server, and secondly, NVR inputs and outputs are not always used.

Are you talking about polling the snapshot? If so IMAGE_UPDATE_EVENTS=0 will do that. Otherwise give more information or extract of the logs showing what traffic you are talking about? What URL is being polled?

I am referring to the survey of alarm entrances.

I connected the intercom camera to the nvr and these errors started appearing. because the intercom simply does not have such entrances.

The binding should auto stop polling that if the camera replies the camera does not support alarm IO. Can you tell me what the camera replies when you manually enter that URL into a browser? The log probably has it in there if you have more of it…

There are two other issues that I see from your logs that are marked as warnings. It appears the binding is opening many channels to request the same URL. Does that happen when you don’t have the intercom connected?

Lastly I have heard the hikvision nvr’s have a mode where each camera can be exposed separately on different ports. Does yours have that ability?