Support for Security Camera System via NVR - ESeeCloud/dvr163

A lot of the affordable home security systems on the market use an NVR that runs ESeeCloud firmware.

I have an 8 channel wireless system branded Amorvue - but their are wired and wireless 4 channel and 8 channel systems with several different brand names that all use the same NVR software.

I found the web-site for the software development company that makes it - but it is predominantly written in Chinese. Using Google translate, I was able to find an area for “secondary development” which has downloads available - presumably that describe the NVR’s API.

I would really like to be able to view my security video streams within Home Assistant - and have access to any “motion detected” events that the security system generates - and since the NVR software seems to be common to so many different systems - I think that support for this device may help other Home Assistant users also.

Do we have any developers that can read Chinese that could maybe take a look at the website and evaluate the feasibility of creating some kind of support within Home Assistant using the tools/API that they provide?

Main website: http://help.dvr163.com/index.php/首页
Development Docs: http://help.dvr163.com/index.php/二次开发

Google translated main page: https://translate.google.ca/translate?hl=en&sl=zh-CN&u=http://help.dvr163.com/index.php/K9608-2-W&prev=search

The specific device I have is:
Dev name NVR
Dev model K9608-2W
Serial Number M5751206xxxxxx
HW version 2.1.0
SW version 2.7.7.0_22922330

I am not a developer - but I’m willing to assist with any kind of testing that would aid the developers

Thank you in advance for any consideration that is given to this request

Hi @tenly,
I saw the docs, very fair API, better than most of other Chinese products out there.
There is a mix Chinese and English, but Its not so hard to understand.
I believe there are many ways to integrate, for example: Get Stream Channel List, PTZ control or Motion Detection Status so on… For example turn on a light if detection motion, or enable disable DetectionRegion based on time …

Hi @dsz ,

Well - that’s heartening news! Thanks for taking the time to have a look at the API docs - and for your reply!

While I wait for someone to hopefully, possibly tackle a Home Assistant integration that exposes motion events and the other attributes/entities you mentioned look possible - was there anything obvious in the API doc that I might be able to use with the generic camera platform to pull a stream from one of the connected cameras?

If it’s not too much trouble - do you think you could have another quick look and see if you can tell what syntax I would need to use for the url parameter in order to pull a stream locally? I would really, really appreciate it.

I’m updating this thread with some information that it literally took me weeks to track down. I wasn’t able to find it via any search engine - but I was finally able to get the question answered via tech support from the reseller that sold me my system (Amorvue).

It was pretty easy to discover the URL syntax to pull a snapshot through the NVR from any camera connected to the NVR:

But I was unable to find a URL for accessing the live video feed. This is what support provided:

RTSP URL:

  • Main stream is rtsp://ip:port/ch0_0.264
  • Sub stream is rtsp://ip:port/ch0_1.264

Where:

  • IP is IP Address of NVR (ie 192.168.1.150)
  • Port is NVR port (ie 80)
  • ch0 is channel 1, ch1 is channel 2, ch2 is channel 3, etc…

RTSP example

  • Channel 2 main stream
    • rtsp://192.168.1.54:80/ch1_0.264

I haven’t tried to use the RTSP stream within Home Assistant yet however I have tested the still image url and I currently have them configured and working within Home Assistant using the generic camera platform.

Can anyone recommend which platform I should use to leverage this rtsp stream within Home Assistant?

Thanks…

3 Likes

Good info. Ill add on to it, I just found last night after searching forever as well.

this is what worked for me. You can change the channel name to see dif cameras

rtsp://yourip:port/user=username&password=yourpassword&channel=2&stream=0.sdp?real_stream–rtp-caching=100

1 Like

Thanks for posting - but I’ve just tried both your syntax and mine using VLC on OSX - and neither seems to work.
Were you able to test either syntax? Did it work? Tested using VLC - or something else?
What NVR software are you running?

It took me forever to find that one I posted. but yes I tested it on all channels and they worked. I tested with vlc. what brand you working with?

I have an 8 channel wireless setup branded Amorvue. The NVR software they are using reports as:

Model Number: K9608-2W
HW version: 2.1.0
SW version: 2.7.7.0_22922330

I found the SDK docs on a site called dvr163.com and they use a flash based webpage app as their local viewer when connecting directly to the NVR from a computer on my local LAN. For internet viewing, they provide both Android and iOS apps - or you can use the eseecloud.com web-site to sign-in and access your video. I believe the same system is sold under many different brand names and even if the bundled cameras are slightly different, there are many products that all use the same third-party NVR software.

I tested the URL’s with VLC on an iMac running OSX High Sierra.
If you’re not able to help me get my setup working - perhaps you could at least run a quick test on your system using the URL syntax that I posted above (from tech support) - although there doesn’t seem to be a place identified for passing credentials… maybe “user:pass” at the beginning? Or “&u=user&p=pass” at the end? I don’t know. I’m at a loss.

The end goal would be to convince one of the dev’s here to build an integration that would expose video streams, motion events and more - but there doesn’t seem to be as much interest in this as I had hoped.

1 Like

I tired that url and it did not work for me. There so many different things I dont know what to say. I tried all the sites, ispy application and site recommandations. I just happen to stumble upon that in some forum after literally months of looking.

What model number and software version does your NVR report?
Is it the same as mine? Or just similar?

Or maybe I’m using VLC wrong? I don’t normally use it for anything so that’s completely possible.
I just clicked File-> Open Network and then entered the URL you provided - modified with my ip, port and credentials of course… Is that all I should have to do - or did I miss a step?

Did you guys just add these cameras to homeassistant as generic ip cams?

I set them up as a generic camera and just use the “still_image_url” to retrieve periodic still images.

Ok thanks, that’s what I’ve done right now too. I’ve got the same model NVR as you, if I find an actual stream I’ll post an update

Thanks! Please do.

I’d still prefer to have a live stream available - and even more than that - I’d like to be able to subscribe to “motion detected” events from the NVR from within HomeAssistant.

I found it!

http://ip:port/cgi-bin/sp.cgi?chn=0&u=USER&p=PASSWORD

I found it by going to the web interface and opening the network tab in Chrome’s developer tools (F12). You can see the “snapshot” URL in there but not the stream. I noticed the URL for the page was view2.html so I tried view3.html and hit the “play” button. The page got stuck in a refresh loop so I couldn’t do anything but I saw sp.cgi blinking in on the network tab so I went to that instead of snapshot.cgi with the same arguments and voila!

2 Likes

I have never done anything with cameras in HA, does it have motion detection support or do we need to keep digging to find the events being fired from the NVR? I am wanting to do all the same things as OP.

this might help you https://github.com/SaWey/home-assistant-dahua-event

That doesn’t appear to be compatible with the dvr163, it does look useful to copy from though if we wanted to write our own custom component

Are you all connecting these camera and NVR to internet Or just internal Network.

Sad to say but Never put these online(WAN).
If you do they will likely be hack.

I don’t trust the NVR so I configured my router to block the IP so it can’t phone home.

One of the reasons I want the direct feed is so I can host a page to display them and put the page behind a reverse proxy with authentication/encryption. In theory I could also set up a VPN but I don’t know if I want to mess with that.