Has anyone else had luck using Unifi Video? Is there anything in the logs that might explain why this is not working?
Device tracker using Unifi and sensors from mFi work great.
Let me know if more information is needed.
Thanks!
16-09-27 18:15:07 homeassistant.components.camera: Error while setting up platform uvc
Traceback (most recent call last):
File "/home/derick/.homeassistant/deps/uvcclient/nvr.py", line 85, in _uvc_request
return self._uvc_request_safe(*args, **kwargs)
File "/home/derick/.homeassistant/deps/uvcclient/nvr.py", line 107, in _uvc_request_safe
resp = conn.getresponse()
File "/usr/lib/python3.5/http/client.py", line 1197, in getresponse
response.begin()
File "/usr/lib/python3.5/http/client.py", line 297, in begin
version, status, reason = self._read_status()
File "/usr/lib/python3.5/http/client.py", line 266, in _read_status
raise RemoteDisconnected("Remote end closed connection without"
http.client.RemoteDisconnected: Remote end closed connection without response
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/entity_component.py", line 107, in _setup_platform
discovery_info)
File "/usr/local/lib/python3.5/dist-packages/homeassistant/components/camera/uvc.py", line 35, in setup_platform
nvrconn = nvr.UVCRemote(addr, port, key)
File "/home/derick/.homeassistant/deps/uvcclient/nvr.py", line 62, in __init__
self._bootstrap = self._get_bootstrap()
File "/home/derick/.homeassistant/deps/uvcclient/nvr.py", line 123, in _get_bootstrap
return self._uvc_request('/api/2.0/bootstrap')['data'][0]
File "/home/derick/.homeassistant/deps/uvcclient/nvr.py", line 87, in _uvc_request
raise NvrError('Failed to contact NVR')
uvcclient.nvr.NvrError: Failed to contact NVR
Bummer!! I love ubnt and all of their products! HA’s support for Ubiquiti was certainly a driving factor in choosing it. I looked for the last supported Unifi Video on ubnt’s website but couldn’t find it. Needless to say HA and it’s devs are the best and I hope it will be updated soon. Thanks for reminding me to update to the latest UV beta too
Awesome, thanks so much! I’m still going to see if I can get the UniFi component to work but at least this is something for the mean time. Really appreciate it!
Well I don’t have an answer but I’m at least a bit closer to something. I think that the NVR isn’t giving the password to the cameras correctly (or perhaps at all). I modified the camera.py file that’s part of the uvcclient and manually defined the password:
After restarting the service my camera’s came up as expected in the dashboard!
SO all that being said I’ve searched and searched and cannot find anything from Ubiquiti (shocking) that says what this change might be. My only real though at this point (even though it’s a crappy one) is add an additional configuration option for the camera.uvc config to have the camera password listed and use rather than trying to get it from the NVR. Any thoughts?
I have just started up with HA and was hoping to get my cameras in the system but ran into the issue of…
“16-11-17 07:13:03 homeassistant.components.camera.uvc: Unable to login to camera”
being spewed all over my logs.
I checked the store.py (/.homeassistant/deps/uvcclient)in my system but there is no such code (running on PI3 Fabrick installer) - was that the right location?
Thanks for tracking this down… hopefully we can get this working!
pjo
Well now that I think about it there is a login for the NVR but the cameras typically have a different PW when you are using SSH to them. You are probably on to something here. I wish I knew python better!
NVR/Camera PW syncing has had a few kinks lately…
@PtP I know enough Python to be dangerous but that’s about it. You can set a password for all the cameras though in the NVR. I have mine the same as my admin login but really it could be changed to anything. While I hate storing passwords in plain-text config files I cannot think of a better option. It’s really either that or enable anonymous viewing of the images. For me that’s not a big deal, they have their own VLAN with no Internet access, but I imagine it could be a problem for some.
@frelev Not sure then. It was at the very bottom of the file for me under the UVCCameraClientV320 class.