{"action":"closed","issue":{"url":"https://api.github.com/repos/Skinah/IpCamera/issues/41","repository_url":"https://api.github.com/repos/Skinah/IpCamera","labels_url":"https://api.github.com/repos/Skinah/IpCamera/issues/41/labels{/name}","comments_url":"https://api.github.com/repos/Skinah/IpCamera/issues/41/comments","events_url":"https://api.github.com/repos/Skinah/IpCamera/issues/41/events","html_url":"https://github.com/Skinah/IpCamera/issues/41","id":541342775,"node_id":"MDU6SXNzdWU1NDEzNDI3NzU=","number":41,"title":"Camera stops updating","user":{"login":"lainsan","id":56224339,"node_id":"MDQ6VXNlcjU2MjI0MzM5","avatar_url":"https://avatars0.githubusercontent.com/u/56224339?v=4","gravatar_id":"","url":"https://api.github.com/users/lainsan","html_url":"https://github.com/lainsan","followers_url":"https://api.github.com/users/lainsan/followers","following_url":"https://api.github.com/users/lainsan/following{/other_user}","gists_url":"https://api.github.com/users/lainsan/gists{/gist_id}","starred_url":"https://api.github.com/users/lainsan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lainsan/subscriptions","organizations_url":"https://api.github.com/users/lainsan/orgs","repos_url":"https://api.github.com/users/lainsan/repos","events_url":"https://api.github.com/users/lainsan/events{/privacy}","received_events_url":"https://api.github.com/users/lainsan/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":13,"created_at":"2019-12-21T16:10:49Z","updated_at":"2019-12-27T09:27:11Z","closed_at":"2019-12-27T09:27:10Z","author_association":"NONE","body":"Hi Matt, as usual: thanks for the outstanding job in updating this binding!\r\n\r\nHere' an issue I am encountering currently - not being sure, whether it's binding or camera related.\r\n\r\n**Setup**:\r\n- openHAB 2.5.0-1 (Release Build)\r\n- ipcamera-2019-12-17.zip\r\n- two IP cameras:\r\n   - HIKVISION DS-2CD2T46G1-4I/SL, Frontyard, CAM01, local IP 192.168.1.100\r\n   - HIKVISION DS-2CD2T46G1-4I/SL, Frontyard, CAM02, local IP 192.168.1.101\r\n\r\n**Problem**:\r\nBinding works well (alarms, image channels, evertyhing) for some time, but then seems to be stopping to update at a certain point. There's no obvious message error in the logs (not even when using trace).\r\nI'm noticing when images (e.g. in HABPANEL or in PaperUI>Control) stop updating and alarms no longer work.\r\nWhen trying to trigger Gif creation (sendCommand(ON)) the corresponding switch get's stuck \"ON\" never returning to OFF again.\r\nWhen accessing my camera directly through it's web interface, LiveView is working fine. When looking into my NVR (Synology), live view or continous recording, it's working fine as well.\r\n\r\n**Things config**:\r\nThing ipcamera:HIKVISION:tCam01 \"tCam01\" @ \"Entrance\"\r\n[\r\n    IPADDRESS=\"192.168.1.100\",\r\n    PASSWORD=\"(removed)\",\r\n    USERNAME=\"(removed)\",\r\n    POLL_CAMERA_MS=2000,\r\n    SERVER_PORT=54324,\r\n    ONVIF_PORT=9999,\r\n    IP_WHITELIST=\"DISABLE\",\r\n    IMAGE_UPDATE_EVENTS=1,\r\n    UPDATE_IMAGE=true,\r\n    GIF_PREROLL=3,\r\n    GIF_POSTROLL=18,\r\n    FFMPEG_INPUT=\"rtsp://192.168.1.100:554/Streaming/Channels/101?transportmode=unicast&profile=Profile_1\",\r\n    FFMPEG_OUTPUT=\"/tmpfs/cam01/\"\r\n    ]\r\n\r\nThing ipcamera:HIKVISION:tCam02 \"tCam02\" @ \"Garden\"\r\n[\r\n    IPADDRESS=\"192.168.1.101\",\r\n    PASSWORD=\"(removed)\",\r\n    USERNAME=\"(removed)\",\r\n    POLL_CAMERA_MS=2000,\r\n    SERVER_PORT=54325,\r\n    ONVIF_PORT=9999,\r\n    IP_WHITELIST=\"DISABLE\",\r\n    IMAGE_UPDATE_EVENTS=1,\r\n    UPDATE_IMAGE=true,\r\n    GIF_PREROLL=3,\r\n    GIF_POSTROLL=18,\r\n    FFMPEG_INPUT=\"rtsp://192.168.1.101:554/Streaming/Channels/101?transportmode=unicast&profile=Profile_1\",\r\n    FFMPEG_OUTPUT=\"/tmpfs/cam02/\"\r\n    ]\r\n\r\n**Example**:\r\nToday CAM01 (192.168.1.100) got stuck at 21.12.2019 16:14:01 - here's the last image i received incl timestamp attached:\r\n\r\n![lastimage_cam01_12-21-2019_16-14-01](https://user-images.githubusercontent.com/56224339/71310371-adf95a80-2413-11ea-8ed7-0743b74032bb.jpg)\r\n\r\nI then also noted CAM02 (192.168.1.101) got stuck as well, at 21.12.2019 16:06:29.\r\n\r\nI attached the OH2 log snippet with ipcamera in TRACE mode from 16:00 - 16:16. \r\n\r\n[openhab.zip](https://github.com/Skinah/IpCamera/files/3991556/openhab.zip)\r\n\r\nBoth cameras are stuck in the following loop:\r\n\r\n2019-12-21 16:16:05.863 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 835, cap: 835/835, unwrapped: PooledUnsafeDirectByteBuf(ridx: 835, widx: 835, cap: 4096)), decoderResult: success)\r\n2019-12-21 16:16:05.864 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - HTTP Result back from camera is \t:\\<EventNotificationAlert version=\"2.0\" xmlns=\"http://www.hikvision.com/ver20/XMLSchema\"\\>\r\n\\<ipAddress\\>192.168.1.100\\</ipAddress\\>\r\n\\<portNo\\>80\\</portNo\\>\r\n\\<protocol\\>HTTP\\</protocol\\>\r\n\\<macAddress\\>bc:ba:c2:2e:31:b9\\</macAddress\\>\r\n\\<channelID\\>1\\</channelID\\>\r\n\\<dateTime\\>2019-12-21T16:16:06+01:00\\</dateTime\\>\r\n\\<activePostCount\\>0\\</activePostCount\\>\r\n\\<eventType\\>videoloss\\</eventType\\>\r\n\\<eventState\\>inactive\\</eventState\\>\r\n\\<eventDescription\\>videoloss alarm\\</eventDescription\\>\r\n\\<channelName\\>\\</channelName\\>\r\n\\<Extensions version=\"1.0\" xmlns=\"urn:psialliance-org\"\\>\r\n\\<serialNumber xmlns=\"urn:selfextension:psiaext-ver10-xsd\"\\>DS-2CD2T46G1-4I/SL20190708AAWRD37607327\\</serialNumber\\>\r\n\\<eventPush xmlns=\"urn:selfextension:psiaext-ver10-xsd\"\\>DS-2CD2T46G1-4I/SL20190708AAWRD37607327,2019-12-21T16:16:06+01:00,0,1.0\\</eventPush\\>\r\n\\</Extensions\\>\r\n\\</EventNotificationAlert\\>\r\n:\r\n2019-12-21 16:16:07.010 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 83, cap: 83/83, unwrapped: PooledUnsafeDirectByteBuf(ridx: 83, widx: 83, cap: 1024)), decoderResult: success)\r\n2019-12-21 16:16:07.011 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - HTTP Result back from camera is \t:--boundary\r\nContent-Type: application/xml; charset=\"UTF-8\"\r\nContent-Length: 845\r\n\r\n:\r\n2019-12-21 16:16:07.017 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 512, cap: 512/512, unwrapped: PooledUnsafeDirectByteBuf(ridx: 512, widx: 512, cap: 512)), decoderResult: success)\r\n2019-12-21 16:16:07.018 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - HTTP Result back from camera is \t:\\<EventNotificationAlert version=\"2.0\" xmlns=\"http://www.hikvision.com/ver20/XMLSchema\"\\>\r\n\\<ipAddress\\>192.168.1.101\\</ipAddress\\>\r\n\\<portNo\\>80\\</portNo\\>\r\n\\<protocol\\>HTTP\\</protocol\\>\r\n\\<macAddress\\>bc:ba:c2:2e:31:b2\\</macAddress\\>\r\n\\<channelID\\>1\\</channelID\\>\r\n\\<dateTime\\>2019-12-21T16:16:07+01:00\\</dateTime\\>\r\n\\<activePostCount\\>0\\</activePostCount\\>\r\n\\<eventType\\>videoloss\\</eventType\\>\r\n\\<eventState\\>inactive\\</eventState\\>\r\n\\<eventDescription\\>videoloss alarm\\</eventDescription\\>\r\n\\<channelName\\>\\</channelName\\>\r\n\\<Extensions version=\"1.0\" xml:\r\n2019-12-21 16:16:07.019 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - DefaultHttpContent(data: PooledSlicedByteBuf(ridx: 0, widx: 333, cap: 333/333, unwrapped: PooledUnsafeDirectByteBuf(ridx: 333, widx: 333, cap: 8192)), decoderResult: success)\r\n2019-12-21 16:16:07.020 [TRACE] [ing.ipcamera.handler.IpCameraHandler] - HTTP Result back from camera is \t:ns=\"urn:psialliance-org\"\\>\r\n\\<serialNumber xmlns=\"urn:selfextension:psiaext-ver10-xsd\"\\>DS-2CD2T46G1-4I/SL20190708AAWRD37607320\\</serialNumber\\>\r\n\\<eventPush xmlns=\"urn:selfextension:psiaext-ver10-xsd\"\\>IO&amp;&amp;DS-2CD2T46G1-4I/SL20190708AAWRD37607320,2019-12-21T16:16:07+01:00,1.0\\</eventPush\\>\r\n\\</Extensions\\>\r\n\\</EventNotificationAlert\\>\r\n:\r\n \r\n**Workaround**:\r\nI can change the things configuration (e.g. number of postroll images), save the file and with that apparently force an initialization. I just did that, and it's working well again.\r\n\r\n**Suggestion**:\r\nI'm not sure, this is binding related. It might be my cameras. However, this state is easy to discover in rules in OH2. If there was a function to enforce this re-initialization (what is it doing? reconnect?) i could work around that problem. :-)\r\n\r\n\r\n"}}
{"actor":{"display_login":"lainsan"}}