IpCamera: New IP Camera Binding

It may not be anything your doing wrong but two things:

  1. When openhab starts up controls are UNDEF not off so the first alarm will be missed by that rule. Consider changing to remove the “from OFF”.
  2. Instar currently wont send more than 1 alarm per 60 seconds, I have been in contact and this will be adjustable in the next firmware and then you can set this to what you wish. So until then…

Instar just released MQTT features which I have not used but should also be a way to get the alarms into Openhab, since it is ‘Homie’ based it should be a breeze to setup. It also looks to be far more comprehensive on what you can do via MQTT.

1 Like

Two new features open for feedback before coding starts. Have a better idea, feel free to suggest on github:

Pre-recording will be certainly be nice! And also keeping the native format of the stream by remuxing to e.g. mkv.
I have some cameras recording 24/7 with xeoma, and so maybe it might be useful to already now consider continuous recording with event markers on e.g. motion. Maybe your binding eventually will make xeoma/shinobi etc unneeded.
Great job so far!

Hi,

first of all, thank you for your answer. I’ve adjusted the rule. However, I still don’t get an alarm from the camera for Openhab. In the logfile it looks like the created item for the channel “pirALARM” is not addressed at all.

Hi @matt1
I have just downloaded the binding, and tried to install it on my Rpi4, with fresh OH 2.5 Stable Rasbian Buster installed.
This is what happens when I add the files to the addons:

2020-01-11 17:39:12.178 [WARN ] [org.apache.felix.fileinstall        ] - Error while starting bundle: file:/usr/share/openhab2/addons/netty-handler-4.1.42.Final.jar
org.osgi.framework.BundleException: Could not resolve module: io.netty.handler [269]
  Unresolved requirement: Import-Package: sun.security.util; resolution:="optional"
  Unresolved requirement: Import-Package: sun.security.x509; resolution:="optional"
  Unresolved requirement: Import-Package: org.eclipse.jetty.npn; version="[1.0.0,2.0.0)"; resolution:="optional"
  Unresolved requirement: Import-Package: org.eclipse.jetty.alpn; version="[1.0.0,2.0.0)"; resolution:="optional"
  Unresolved requirement: Import-Package: io.netty.channel; version="[4.1.0,5.0.0)"
	at org.eclipse.osgi.container.Module.start(Module.java:444) ~[org.eclipse.osgi-3.12.100.jar:?]
	at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:383) ~[org.eclipse.osgi-3.12.100.jar:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1260) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1233) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316) [bundleFile:3.6.4]
2020-01-11 17:39:12.208 [WARN ] [org.apache.felix.fileinstall        ] - Error while starting bundle: file:/usr/share/openhab2/addons/netty-codec-4.1.42.Final.jar
org.osgi.framework.BundleException: Could not resolve module: io.netty.codec [265]
  Unresolved requirement: Import-Package: com.google.protobuf; version="[2.6.0,3.0.0)"; resolution:="optional"
  Unresolved requirement: Import-Package: com.google.protobuf.nano; resolution:="optional"
  Unresolved requirement: Import-Package: com.jcraft.jzlib; resolution:="optional"
  Unresolved requirement: Import-Package: com.ning.compress; version="[1.0.0,2.0.0)"; resolution:="optional"
  Unresolved requirement: Import-Package: com.ning.compress.lzf; version="[1.0.0,2.0.0)"; resolution:="optional"
  Unresolved requirement: Import-Package: com.ning.compress.lzf.util; version="[1.0.0,2.0.0)"; resolution:="optional"
  Unresolved requirement: Import-Package: io.netty.channel; version="[4.1.0,5.0.0)"
	at org.eclipse.osgi.container.Module.start(Module.java:444) ~[org.eclipse.osgi-3.12.100.jar:?]
	at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:383) ~[org.eclipse.osgi-3.12.100.jar:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1260) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1233) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316) [bundleFile:3.6.4]
2020-01-11 17:39:12.212 [WARN ] [org.apache.felix.fileinstall        ] - Error while starting bundle: file:/usr/share/openhab2/addons/netty-codec-http-4.1.42.Final.jar
org.osgi.framework.BundleException: Could not resolve module: io.netty.codec-http [266]
  Unresolved requirement: Import-Package: com.jcraft.jzlib; resolution:="optional"
  Unresolved requirement: Import-Package: io.netty.channel; version="[4.1.0,5.0.0)"
	at org.eclipse.osgi.container.Module.start(Module.java:444) ~[org.eclipse.osgi-3.12.100.jar:?]
	at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:383) ~[org.eclipse.osgi-3.12.100.jar:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1260) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1233) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365) [bundleFile:3.6.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316) [bundleFile:3.6.4]

Any ideas why? Seems like there are something missing somewhere.

Yes this keeps the CPU load very low and I plan to use MP4 container as Openhab seems to support this through the UIs more??? I have not tried it yet so not sure what container is best so if anyone has experience they can share it would save me time.

Great idea, I like it but not sure how to present this using Openhabs UI in a clean and easy way. I usually come up with the way a user will interact with a feature before coding it. Perhaps in Openhab 3 this will be easier as one of the main goals is to make it easier for people to contribute to the UI and that sounds like it will need someone who is willing to add new features to the UI. A “Timeline” item type that can have red lines displayed and clicked AFAIK this does not exist.

No I never plan/aim to do that as making a nice UI is too much work, those packages are great for reviewing footage from multiple cameras. For those that don’t want to record and review and only use a camera in automations then yes hopefully the binding removes the need to have a system that is more complex then it needs to be.

@Thomas1509

That is because it is “pirAlarm”

@Kim_Andersen
Does restarting Openhab solve it? Openhab 2.5 seems to need everything created in its cache so the first time it starts it creates the cache and the second time it works, whenever you clear the cache and tmp folders you get weird things happening until a second start and I guess it may happen if it is the first time Openhab has ever started up with the files added. If it is not that then it is something new I have not seen. Let me know if a restart solves it.

Hi, i have 2 ip cams. One is a dahua china clone which can show mjpeg-stream, this is working in my basic-ui sitemap diretcly.

My second cam is a cheap china cam which only gives me a rtsp-stream. But with ffmpeg i was able to produce some files in my tmpfs-directory. There is a gif, m38u and many ts-files.

Is there a way to show the ffmpeg output in my sitemap in basic ui? I tried http://ip:port/ipcamera.gif and m38u, but i only get a blank box without any video. Also on my android phone, i can´t see any live video.

I used the standard values in most of my thing-files settings.

As there are ts-files and a gif-file, i can see that ffmpeg is working in general…

Any ideas how to solve my problem?

Yes, restarting OH seems to get it to run… Will try play with it today to see if I can get the lastest binding to work with my Reolink cam. (It runs using HTTPonly on my main setup using an older version of the binding).

1 Like

The gif should work everywhere, if the file is created then not much can go wrong. The m38u aka HLS is another story as some browsers need a plugin or an update to support the format otherwise a blank box or a box with a play/pause control is common.
If the hls files are being created this shows your server-port is correct and triggering the creation and ffmpeg is working clearly, not sure what it could be. As always you should check the DEBUG logs and if that does not turn something up check the TRACE level.

Hi @matt1
I know you´re busy with coding new stuff etc… But I´m just wondering.
What would it take for the binding to support the ONVIF for Reolink cameras?
As far as I understand, ONVIF is, a global open standard for the interface of physical IP-based security products.
So I wonder how come some ONVIF cameras doesnt work?
Is there some info you need from my Reolink in order to make it work. Perhaps I can provide it then?

I just tried setting it up for Generic ONVIF. But it fails.
Without setting an SNAP_SHOT URL override, I get this warning:

2020-01-12 12:55:52.182 [WARN ] [ing.ipcamera.handler.IpCameraHandler] - We got an ONVIF error400:<?xml version="1.0" encoding="UTF-8"?>

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://www.w3.org/2003/05/soap-envelope" xmlns:SOAP-ENC="http://www.w3.org/2003/05/soap-encoding" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsdd="http://schemas.xmlsoap.org/ws/2005/04/discovery" xmlns:wsa5="http://www.w3.org/2005/08/addressing" xmlns:xmime="http://tempuri.org/xmime.xsd" xmlns:xmime5="http://www.w3.org/2005/05/xmlmime" xmlns:xop="http://www.w3.org/2004/08/xop/include" xmlns:wsrfbf="http://docs.oasis-open.org/wsrf/bf-2" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:wstop="http://docs.oasis-open.org/wsn/t-1" xmlns:wsrfr="http://docs.oasis-open.org/wsrf/r-2" xmlns:ns1="http://www.onvif.org/ver10/actionengine/wsdl" xmlns:tev="http://www.onvif.org/ver10/events/wsdl" xmlns:ns10="http://www.onvif.org/ver10/events/wsdl/PullPointBinding" xmlns:ns11="http://www.onvif.org/ver10/events/wsdl/CreatePullPointBinding" xmlns:ns12="http://www.onvif.org/ver10/events/wsdl/PausableSubscriptionManagerBinding" xmlns:ns13="http://www.onvif.org/ver10/network/wsdl/RemoteDiscoveryBinding" xmlns:ns14="http://www.onvif.org/ver10/network/wsdl/DiscoveryLookupBinding" xmlns:tdn="http://www.onvif.org/ver10/network/wsdl" xmlns:ns3="http://www.onvif.org/ver20/analytics/wsdl/RuleEngineBinding" xmlns:ns4="http://www.onvif.org/ver20/analytics/wsdl/AnalyticsEngineBinding" xmlns:tan="http://www.onvif.org/ver20/analytics/wsdl" xmlns:ns5="http://www.onvif.org/ver10/events/wsdl/PullPointSubscriptionBinding" xmlns:ns6="http://www.onvif.org/ver10/events/wsdl/EventBinding" xmlns:ns7="http://www.onvif.org/ver10/events/wsdl/SubscriptionManagerBinding" xmlns:ns8="http://www.onvif.org/ver10/events/wsdl/NotificationProducerBinding" xmlns:wsnt="http://docs.oasis-open.org/wsn/b-2" xmlns:ns9="http://www.onvif.org/ver10/events/wsdl/NotificationConsumerBinding" xmlns:tad="http://www.onvif.org/ver10/analyticsdevice/wsdl" xmlns:tds="http://www.onvif.org/ver10/device/wsdl" xmlns:timg="http://www.onvif.org/ver20/imaging/wsdl" xmlns:tls="http://www.onvif.org/ver10/display/wsdl" xmlns:tmd="http://www.onvif.org/ver10/deviceIO/wsdl" xmlns:tptz="http://www.onvif.org/ver20/ptz/wsdl" xmlns:trc="http://www.onvif.org/ver10/recording/wsdl" xmlns:trp="http://www.onvif.org/ver10/replay/wsdl" xmlns:trt="http://www.onvif.org/ver10/media/wsdl" xmlns:trv="http://www.onvif.org/ver10/receiver/wsdl" xmlns:tse="http://www.onvif.org/ver10/search/wsdl" xmlns:ter="http://www.onvif.org/ver10/error" xmlns:tns1="http://www.onvif.org/ver10/topics" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"><SOAP-ENV:Body><SOAP-ENV:Fault SOAP-ENV:encodingStyle="http://www.w3.org/2003/05/soap-encoding"><SOAP-ENV:Code><SOAP-ENV:Value>SOAP-ENV:Sender</SOAP-ENV:Value><SOAP-ENV:Subcode><SOAP-ENV:Value>ter:NotAuthorized</SOAP-ENV:Value></SOAP-ENV:Subcode></SOAP-ENV:Code><SOAP-ENV:Reason><SOAP-ENV:Text xml:lang="en">Sender not Authorized</SOAP-ENV:Text></SOAP-ENV:Reason></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>

When inserting an snap_shot URL override, it turns to ONLINE, but I get this warning:

2020-01-12 12:43:14.606 [WARN ] [ing.ipcamera.handler.IpCameraHandler] - !!!! Camera has closed a channel 	URL: Cause reported is: {}
java.lang.ArrayIndexOutOfBoundsException: 224984
	at org.openhab.binding.ipcamera.handler.IpCameraHandler$CommonCameraHandler.channelRead(IpCameraHandler.java:709) ~[?:?]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) [bundleFile:4.1.42.Final]
	at io.netty.channel.ChannelInboundHandlerAdapter.channelRead(ChannelInboundHandlerAdapter.java:93) [bundleFile:4.1.42.Final]
	at org.openhab.binding.ipcamera.internal.MyNettyAuthHandler.channelRead(MyNettyAuthHandler.java:239) [bundleFile:?]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) [bundleFile:4.1.42.Final]
	at io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:438) [bundleFile:4.1.42.Final]
	at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:328) [bundleFile:4.1.42.Final]
	at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:302) [bundleFile:4.1.42.Final]
	at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:253) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) [bundleFile:4.1.42.Final]
	at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:287) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) [bundleFile:4.1.42.Final]
	at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1422) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:931) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:163) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:700) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:635) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:552) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:514) [bundleFile:4.1.42.Final]
	at io.netty.util.concurrent.SingleThreadEventExecutor$6.run(SingleThreadEventExecutor.java:1044) [bundleFile:4.1.42.Final]
	at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [bundleFile:4.1.42.Final]
	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [bundleFile:4.1.42.Final]
	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_222]

This is the standard port settings of the Reolink setup, (I believe its standard in all Reolink devices incl NVR supporting ONVIF):

Ohh, forgot to mention.
I have this Reolink RCL 410 camera running on my main setup (Main Rpi3) using HTTPonly and an older version of the Ipcamera binding. It works fine for basic stuff. I havn´t had time to play with ffmpeg yet, as I wanted to use my Rpi4 insted, ie my new test up, which I´m playing with atm).

@Kim_Andersen Can you not add it as a generic onvif camera?
Http cam doesn’t do any onvif I don’t think

Sorry didn’t read properly you tried onvif

1 Like

The error you posted had this in plain English, please read the logs before posting as they are there to tell you what is wrong. Possibly your user/pass is wrong or perhaps you use a non standard character in your password that does not play nicely with the onvif library’s code.

The issue is anyone can self certify their own product as being onvif compatible, no independent 3rd party does the testing. PLUS they often pass basic tests with version 1.x of the spec and then advertise they are ONVIF leaving out which version they passed the test with, when it is at least 2.4 now.

I am not saying this applies in your case and to your brand of camera, this is just a general statement. I have just changed the entire ONVIF library to a new one and had to write a lot of the onvif support myself from scratch. There could be bugs or things with the new library I am not aware of, but with my own cameras it is working far better than ever. DEBUG level log is needed to really look at what is going on with onvif as now the Reponses back from the camera get added to the logs.

If you think the camera has an issue then test it with Onvif Device Manager. If your camera does not have PTZ ability then just forget about onvif.

I did read the log, and also made sure the username/pw is correct.

My wondering was just why this happened. It may be just a bad vendore, as they only seem to have one device which had been licensed Onvif. (not my model though)

@matt

I have setup the camera to use httponly… It goes online fine.
As soon I enter a (working) URL in the SNAPSHOT_URL_OVERRIDE I get this in my logfile:
PS. I´m setting this up from PaperUI atm.

2020-01-12 16:46:41.711 [WARN ] [ing.ipcamera.handler.IpCameraHandler] - !!!! Camera has closed a channel 	URL: Cause reported is: {}
java.lang.ArrayIndexOutOfBoundsException: 206977
	at org.openhab.binding.ipcamera.handler.IpCameraHandler$CommonCameraHandler.channelRead(IpCameraHandler.java:709) ~[?:?]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) [bundleFile:4.1.42.Final]
	at io.netty.channel.ChannelInboundHandlerAdapter.channelRead(ChannelInboundHandlerAdapter.java:93) [bundleFile:4.1.42.Final]
	at org.openhab.binding.ipcamera.internal.MyNettyAuthHandler.channelRead(MyNettyAuthHandler.java:239) [bundleFile:?]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) [bundleFile:4.1.42.Final]
	at io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:438) [bundleFile:4.1.42.Final]
	at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:328) [bundleFile:4.1.42.Final]
	at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:302) [bundleFile:4.1.42.Final]
	at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:253) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) [bundleFile:4.1.42.Final]
	at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:287) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) [bundleFile:4.1.42.Final]
	at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1422) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [bundleFile:4.1.42.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) [bundleFile:4.1.42.Final]
	at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:931) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:163) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:700) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:635) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:552) [bundleFile:4.1.42.Final]
	at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:514) [bundleFile:4.1.42.Final]
	at io.netty.util.concurrent.SingleThreadEventExecutor$6.run(SingleThreadEventExecutor.java:1044) [bundleFile:4.1.42.Final]
	at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [bundleFile:4.1.42.Final]
	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [bundleFile:4.1.42.Final]
	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_222]

It´s the same URL I use on my main setup (Rpi3 with OH 2.5 Stable release) with an older version of the binding. I have checked twice, the url works fine from a browser.

@Kim_Andersen I have the same problem with the ReoLink RCL 420 camera…

I also get this error every 4 seconds in the log…

2020-01-12 19:18:15.464 [WARN ] [ing.ipcamera.handler.IpCameraHandler] - !!! Camera has closed a channel URL: Cause reported is: {}

java.lang.ArrayIndexOutOfBoundsException: null

I would need trace level of what happens to know more. The reply back from the camera especially the headers is used are needed.

Maybe this will help you.

2020-01-12 21:17:58.713 [hingStatusInfoChangedEvent] - 'ipcamera:ONVIF:KGV' changed from INITIALIZING to ONLINE

==> /var/log/openhab2/openhab.log <==

2020-01-12 21:17:58.716 [DEBUG] [ing.ipcamera.handler.IpCameraHandler] - We sucessfully connected to a ONVIF SERVICE:be.teletask.onvif.models.OnvifServices@793e46a3

2020-01-12 21:17:58.718 [DEBUG] [ing.ipcamera.handler.IpCameraHandler] - Fetching the number of Media Profiles this camera supports.

2020-01-12 21:17:58.757 [WARN ] [ing.ipcamera.handler.IpCameraHandler] - We got an ONVIF error400:<?xml version="1.0" encoding="UTF-8"?>

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://www.w3.org/2003/05/soap-envelope" xmlns:SOAP-ENC="http://www.w3.org/2003/05/soap-encoding" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsdd="http://schemas.xmlsoap.org/ws/2005/04/discovery" xmlns:wsa5="http://www.w3.org/2005/08/addressing" xmlns:xmime="http://tempuri.org/xmime.xsd" xmlns:xmime5="http://www.w3.org/2005/05/xmlmime" xmlns:xop="http://www.w3.org/2004/08/xop/include" xmlns:wsrfbf="http://docs.oasis-open.org/wsrf/bf-2" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:wstop="http://docs.oasis-open.org/wsn/t-1" xmlns:wsrfr="http://docs.oasis-open.org/wsrf/r-2" xmlns:ns1="http://www.onvif.org/ver10/actionengine/wsdl" xmlns:tev="http://www.onvif.org/ver10/events/wsdl" xmlns:ns10="http://www.onvif.org/ver10/events/wsdl/PullPointBinding" xmlns:ns11="http://www.onvif.org/ver10/events/wsdl/CreatePullPointBinding" xmlns:ns12="http://www.onvif.org/ver10/events/wsdl/PausableSubscriptionManagerBinding" xmlns:ns13="http://www.onvif.org/ver10/network/wsdl/RemoteDiscoveryBinding" xmlns:ns14="http://www.onvif.org/ver10/network/wsdl/DiscoveryLookupBinding" xmlns:tdn="http://www.onvif.org/ver10/network/wsdl" xmlns:ns3="http://www.onvif.org/ver20/analytics/wsdl/RuleEngineBinding" xmlns:ns4="http://www.onvif.org/ver20/analytics/wsdl/AnalyticsEngineBinding" xmlns:tan="http://www.onvif.org/ver20/analytics/wsdl" xmlns:ns5="http://www.onvif.org/ver10/events/wsdl/PullPointSubscriptionBinding" xmlns:ns6="http://www.onvif.org/ver10/events/wsdl/EventBinding" xmlns:ns7="http://www.onvif.org/ver10/events/wsdl/SubscriptionManagerBinding" xmlns:ns8="http://www.onvif.org/ver10/events/wsdl/NotificationProducerBinding" xmlns:wsnt="http://docs.oasis-open.org/wsn/b-2" xmlns:ns9="http://www.onvif.org/ver10/events/wsdl/NotificationConsumerBinding" xmlns:tad="http://www.onvif.org/ver10/analyticsdevice/wsdl" xmlns:tds="http://www.onvif.org/ver10/device/wsdl" xmlns:timg="http://www.onvif.org/ver20/imaging/wsdl" xmlns:tls="http://www.onvif.org/ver10/display/wsdl" xmlns:tmd="http://www.onvif.org/ver10/deviceIO/wsdl" xmlns:tptz="http://www.onvif.org/ver20/ptz/wsdl" xmlns:trc="http://www.onvif.org/ver10/recording/wsdl" xmlns:trp="http://www.onvif.org/ver10/replay/wsdl" xmlns:trt="http://www.onvif.org/ver10/media/wsdl" xmlns:trv="http://www.onvif.org/ver10/receiver/wsdl" xmlns:tse="http://www.onvif.org/ver10/search/wsdl" xmlns:ter="http://www.onvif.org/ver10/error" xmlns:tns1="http://www.onvif.org/ver10/topics" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"><SOAP-ENV:Body><SOAP-ENV:Fault SOAP-ENV:encodingStyle="http://www.w3.org/2003/05/soap-encoding"><SOAP-ENV:Code><SOAP-ENV:Value>SOAP-ENV:Sender</SOAP-ENV:Value><SOAP-ENV:Subcode><SOAP-ENV:Value>ter:NotAuthorized</SOAP-ENV:Value></SOAP-ENV:Subcode></SOAP-ENV:Code><SOAP-ENV:Reason><SOAP-ENV:Text xml:lang="en">Sender not Authorized</SOAP-ENV:Text></SOAP-ENV:Reason></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>

2020-01-12 21:17:58.970 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpResponse(decodeResult: success, version: HTTP/1.1)

HTTP/1.1 200 OK

Server: nginx/1.6.2

Date: Sun, 12 Jan 2020 20:17:58 GMT

Content-Type: image/jpeg

Content-Length: 79456

Connection: keep-alive

2020-01-12 21:17:58.972 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 874, cap: 874/874, unwrapped: PooledUnsafeDirectByteBuf(ridx: 1024, widx: 1024, cap: 1024)), decoderResult: success)

2020-01-12 21:17:58.975 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 16384, cap: 16384)), decoderResult: success)

2020-01-12 21:17:58.977 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16384, widx: 16384, cap: 16384)), decoderResult: success)

2020-01-12 21:17:58.980 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 31797, cap: 65536)), decoderResult: success)

2020-01-12 21:17:58.982 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16384, widx: 31797, cap: 65536)), decoderResult: success)

2020-01-12 21:17:58.984 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 24576, widx: 31797, cap: 65536)), decoderResult: success)

2020-01-12 21:17:58.987 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 7221, cap: 7221/7221, unwrapped: PooledUnsafeDirectByteBuf(ridx: 31797, widx: 31797, cap: 65536)), decoderResult: success)

2020-01-12 21:17:58.989 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 27448, cap: 65536)), decoderResult: success)

2020-01-12 21:17:58.991 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16384, widx: 27448, cap: 65536)), decoderResult: success)

2020-01-12 21:17:58.994 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 24576, widx: 27448, cap: 65536)), decoderResult: success)

2020-01-12 21:17:58.996 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 2872, cap: 2872/2872, unwrapped: PooledUnsafeDirectByteBuf(ridx: 27448, widx: 27448, cap: 65536)), decoderResult: success)

2020-01-12 21:17:58.999 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultLastHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 2953, cap: 2953/2953, unwrapped: PooledUnsafeDirectByteBuf(ridx: 2953, widx: 2953, cap: 65536)), decoderResult: success)

2020-01-12 21:18:05.706 [DEBUG] [ing.ipcamera.handler.IpCameraHandler] - Sending camera: GET: http://192.168.178.21/cgi-bin/api.cgi?cmd=Snap&channel=0&user=admin&password= #####&width=1024&height=768&rs=WWdwNmACQ56HLBkC&token=ea567f4943cbe09

2020-01-12 21:18:05.910 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpResponse(decodeResult: success, version: HTTP/1.1)

HTTP/1.1 200 OK

Server: nginx/1.6.2

Date: Sun, 12 Jan 2020 20:18:04 GMT

Content-Type: image/jpeg

Content-Length: 79719

Connection: keep-alive

2020-01-12 21:18:05.912 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 4194, cap: 4194/4194, unwrapped: PooledUnsafeDirectByteBuf(ridx: 4344, widx: 4344, cap: 65536)), decoderResult: success)

2020-01-12 21:18:05.913 [WARN ] [ing.ipcamera.handler.IpCameraHandler] - !!!! Camera has closed a channel 	URL: Cause reported is: {}

java.lang.ArrayIndexOutOfBoundsException: null

2020-01-12 21:18:07.706 [DEBUG] [ing.ipcamera.handler.IpCameraHandler] - Sending camera: GET: http://192.168.178.21/cgi-bin/api.cgi?cmd=Snap&channel=0&user=admin&password= #####&width=1024&height=768&rs=WWdwNmACQ56HLBkC&token=ea567f4943cbe09

2020-01-12 21:18:07.987 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpResponse(decodeResult: success, version: HTTP/1.1)

HTTP/1.1 200 OK

Server: nginx/1.6.2

Date: Sun, 12 Jan 2020 20:18:07 GMT

Content-Type: image/jpeg

Content-Length: 79365

Connection: keep-alive

2020-01-12 21:18:07.989 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 874, cap: 874/874, unwrapped: PooledUnsafeDirectByteBuf(ridx: 1024, widx: 1024, cap: 1024)), decoderResult: success)

2020-01-12 21:18:07.991 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 15445, cap: 16384)), decoderResult: success)

2020-01-12 21:18:07.993 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 7253, cap: 7253/7253, unwrapped: PooledUnsafeDirectByteBuf(ridx: 15445, widx: 15445, cap: 16384)), decoderResult: success)

2020-01-12 21:18:07.996 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 19264, cap: 65536)), decoderResult: success)

2020-01-12 21:18:07.998 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16384, widx: 19264, cap: 65536)), decoderResult: success)

2020-01-12 21:18:08.000 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 2880, cap: 2880/2880, unwrapped: PooledUnsafeDirectByteBuf(ridx: 19264, widx: 19264, cap: 65536)), decoderResult: success)

2020-01-12 21:18:08.002 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 21656, cap: 65536)), decoderResult: success)

2020-01-12 21:18:08.004 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16384, widx: 21656, cap: 65536)), decoderResult: success)

2020-01-12 21:18:08.006 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 5272, cap: 5272/5272, unwrapped: PooledUnsafeDirectByteBuf(ridx: 21656, widx: 21656, cap: 65536)), decoderResult: success)

2020-01-12 21:18:08.008 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 16368, cap: 65536)), decoderResult: success)

2020-01-12 21:18:08.010 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8176, cap: 8176/8176, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16368, widx: 16368, cap: 65536)), decoderResult: success)

2020-01-12 21:18:08.013 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultLastHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 5758, cap: 5758/5758, unwrapped: PooledUnsafeDirectByteBuf(ridx: 5758, widx: 5758, cap: 65536)), decoderResult: success)

2020-01-12 21:18:09.706 [DEBUG] [ing.ipcamera.handler.IpCameraHandler] - Sending camera: GET: http://192.168.178.21/cgi-bin/api.cgi?cmd=Snap&channel=0&user=admin&password= #####&width=1024&height=768&rs=WWdwNmACQ56HLBkC&token=ea567f4943cbe09

2020-01-12 21:18:09.893 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpResponse(decodeResult: success, version: HTTP/1.1)

HTTP/1.1 200 OK

Server: nginx/1.6.2

Date: Sun, 12 Jan 2020 20:18:08 GMT

Content-Type: image/jpeg

Content-Length: 79461

Connection: keep-alive

2020-01-12 21:18:09.895 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 2746, cap: 2746/2746, unwrapped: PooledUnsafeDirectByteBuf(ridx: 2896, widx: 2896, cap: 32768)), decoderResult: success)

2020-01-12 21:18:09.898 [WARN ] [ing.ipcamera.handler.IpCameraHandler] - !!!! Camera has closed a channel 	URL: Cause reported is: {}

java.lang.ArrayIndexOutOfBoundsException: null

2020-01-12 21:18:11.706 [DEBUG] [ing.ipcamera.handler.IpCameraHandler] - Sending camera: GET: http://192.168.178.21/cgi-bin/api.cgi?cmd=Snap&channel=0&user=admin&password= #####&width=1024&height=768&rs=WWdwNmACQ56HLBkC&token=ea567f4943cbe09

2020-01-12 21:18:11.967 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpResponse(decodeResult: success, version: HTTP/1.1)

HTTP/1.1 200 OK

Server: nginx/1.6.2

Date: Sun, 12 Jan 2020 20:18:11 GMT

Content-Type: image/jpeg

Content-Length: 79626

Connection: keep-alive

2020-01-12 21:18:11.968 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 874, cap: 874/874, unwrapped: PooledUnsafeDirectByteBuf(ridx: 1024, widx: 1024, cap: 1024)), decoderResult: success)

2020-01-12 21:18:11.970 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 7261, cap: 7261/7261, unwrapped: PooledUnsafeDirectByteBuf(ridx: 7261, widx: 7261, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.973 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 2896, cap: 2896/2896, unwrapped: PooledUnsafeDirectByteBuf(ridx: 2896, widx: 2896, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.975 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 13472, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.977 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 5280, cap: 5280/5280, unwrapped: PooledUnsafeDirectByteBuf(ridx: 13472, widx: 13472, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.979 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 16368, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.981 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8176, cap: 8176/8176, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16368, widx: 16368, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.984 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 16368, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.986 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8176, cap: 8176/8176, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16368, widx: 16368, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.988 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8192, cap: 8192/8192, unwrapped: PooledUnsafeDirectByteBuf(ridx: 8192, widx: 16368, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.990 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 8176, cap: 8176/8176, unwrapped: PooledUnsafeDirectByteBuf(ridx: 16368, widx: 16368, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.992 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 4088, cap: 4088/4088, unwrapped: PooledUnsafeDirectByteBuf(ridx: 4088, widx: 4088, cap: 16384)), decoderResult: success)

2020-01-12 21:18:11.995 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultLastHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 1931, cap: 1931/1931, unwrapped: PooledUnsafeDirectByteBuf(ridx: 1931, widx: 1931, cap: 8192)), decoderResult: success)

2020-01-12 21:18:13.706 [DEBUG] [ing.ipcamera.handler.IpCameraHandler] - Sending camera: GET: http://192.168.178.21/cgi-bin/api.cgi?cmd=Snap&channel=0&user=admin&password= #####&width=1024&height=768&rs=WWdwNmACQ56HLBkC&token=ea567f4943cbe09

2020-01-12 21:18:13.884 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpResponse(decodeResult: success, version: HTTP/1.1)

HTTP/1.1 200 OK

Server: nginx/1.6.2

Date: Sun, 12 Jan 2020 20:18:12 GMT

Content-Type: image/jpeg

Content-Length: 79669

Connection: keep-alive

I am now certain that your cameras states the content length and then pumps out way more data which is breaking the http convention. The content header length does not add up to all the packets CAP sizes. I could look at making a change to allow for this but if a camera is breaking this standard then you should report it to the manufacturer as a bug. The binding does have an error to display for when this occurs but java throws the error before it reached that line of code. So I will change something even if it is to get a nicer message to display.

@Kim_Andersen
@Desmond206x

Check if your camera has a newer firmware as this is 100% a bug in the cameras firmware.

I´m using the very same (physically) camera at my main setup, but with an older ipcamera binding.