IP Camera Controller (Dahua & HikVision)

User avatar
nayr
Posts: 431
Joined: Tuesday 11 November 2014 19:42
Target OS: Linux
Domoticz version: github
Location: Denver, CO - USA
Contact:

IP Camera Controller (Dahua & HikVision)

Postby nayr » Thursday 18 February 2016 7:37

Goal: Turn your Dahua or Hikvision Security Cameras into Domoticz Motion Detectors, along with Alarm Inputs and Video Tampering.

download/source: https://github.com/nayrnet/domoticz-ipcc

Rebranded Manufacturers that might work: QSee, Swann, Lorex, Foscam, EyeSurv, and more.. many vendors simply rebrand Dahua and HikVision products so do some research to find out who really made your camera.

Event Features:
  • Video Motion Detection
  • Alarm Inputs (Dry Contacts)
  • Video Blank, Video Loss Tamper Devices
What it does: Maintains an open connection to your camera's alarm stream, any alarms that are set off are instantly transmitted to Virtual Motion Detectors and Contact Switches within Domoticz.

How its implemented: NodeJS and MQTT, it also exposes the raw sensor data via generic MQTT (no json) so it can be integrated with other platforms easily as well.

Will it run on Windows?: No, requires a unix tcp sockets to quickly detect a network problem and try to reconnect.

To Do List:
  • ONVIF Profile S Cameras
  • PTZ Commands
  • Alarm Outputs
  • Day/Night Profile Switching
  • Wrap Up HikVision Support
Last edited by nayr on Sunday 21 February 2016 6:36, edited 16 times in total.
Debian Jessie: CuBox-i4 (Primary) w/Static Routed IP and x509 / BeagleBone with OpenSprinkler / BeagleBone Planted Aquarium / 3x Raspbery Pi2b GPIO Slaves
Elemental Theme - node-domoticz-mqtt - Home Theatre Controller - AndroidTV Simple OSD Remote - x509 TLS Auth

User avatar
nayr
Posts: 431
Joined: Tuesday 11 November 2014 19:42
Target OS: Linux
Domoticz version: github
Location: Denver, CO - USA
Contact:

Re: IP Camera Controller (Dahua)

Postby nayr » Friday 19 February 2016 6:54

I dont have any Hikvision cameras but I know they are very popular, so I was scoping out there API docs and it looks like they have an alarm stream much like my Dahua's.. so I am trying to arrange to get access to a Hikvision camera remotely so I can add support for both vendors.
Debian Jessie: CuBox-i4 (Primary) w/Static Routed IP and x509 / BeagleBone with OpenSprinkler / BeagleBone Planted Aquarium / 3x Raspbery Pi2b GPIO Slaves
Elemental Theme - node-domoticz-mqtt - Home Theatre Controller - AndroidTV Simple OSD Remote - x509 TLS Auth

User avatar
BakSeeDaa
Posts: 293
Joined: Thursday 17 September 2015 10:13
Target OS: Raspberry Pi
Domoticz version: beta
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby BakSeeDaa » Friday 26 February 2016 12:50

I must say that I'm very excited about your nice project. While waiting for the Hikvision code to become ready I've prepared a little bit. :lol:

Does the the following MQTT configuration suit for domoticz-ipcc? Thanks!
Untitled.png
Untitled.png (115.09 KiB) Viewed 5165 times
Best wishes

// บักสีดา

User avatar
nayr
Posts: 431
Joined: Tuesday 11 November 2014 19:42
Target OS: Linux
Domoticz version: github
Location: Denver, CO - USA
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby nayr » Friday 26 February 2016 14:07

yep :lol:
Debian Jessie: CuBox-i4 (Primary) w/Static Routed IP and x509 / BeagleBone with OpenSprinkler / BeagleBone Planted Aquarium / 3x Raspbery Pi2b GPIO Slaves
Elemental Theme - node-domoticz-mqtt - Home Theatre Controller - AndroidTV Simple OSD Remote - x509 TLS Auth

User avatar
Minglarn
Posts: 144
Joined: Friday 21 August 2015 19:27
Target OS: Raspberry Pi
Domoticz version: beta
Location: Stockholm / Sweden
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby Minglarn » Friday 26 February 2016 15:50

This is getting better and better!

Keep up the good work nayr! Cant wait for the HikVision code!
When you eliminate the impossible, whatever remains, however improbable, must be the truth.” -Spock in Star Trek VI

User avatar
BakSeeDaa
Posts: 293
Joined: Thursday 17 September 2015 10:13
Target OS: Raspberry Pi
Domoticz version: beta
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby BakSeeDaa » Friday 22 April 2016 22:32

Me too, I'm also waiting. I have 5 of those Hikvision cameras now. :lol:
Best wishes

// บักสีดา

HoLeeShiet
Posts: 64
Joined: Tuesday 18 March 2014 22:19
Target OS: -
Domoticz version:
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby HoLeeShiet » Saturday 23 April 2016 7:30

great! I also have Hikvision cameras and would love to try!
Using Tapatalk

Heisenberg
Posts: 286
Joined: Monday 27 January 2014 15:12
Target OS: Raspberry Pi
Domoticz version:
Location: Netherlands
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby Heisenberg » Saturday 23 April 2016 19:25

Has anyone succesfully use this with Hikvision? Does it matter what model of Hikvision you have?
Is it possible to have Hikvision camera switch on a group of lights when motion detected? If yes, how should the script look like?
Raspberry Pi Type B
Raspberry Pi Type B2
RFXCOMtrx433e

User avatar
BakSeeDaa
Posts: 293
Joined: Thursday 17 September 2015 10:13
Target OS: Raspberry Pi
Domoticz version: beta
Contact:

Re: IP Camera Controller (Dahua)

Postby BakSeeDaa » Wednesday 27 April 2016 17:04

nayr wrote:I dont have any Hikvision cameras but I know they are very popular, so I was scoping out there API docs and it looks like they have an alarm stream much like my Dahua's.. so I am trying to arrange to get access to a Hikvision camera remotely so I can add support for both vendors.


Hi Ryan!

Did You ever get access to a Hikvision camera remotely? Since I have a couple of them, I can set up remote access for You. Please let me know. Please also say if You think there is any other way for us to support this project. I'd be happy to donate a crate of beers or whatever :lol: Your work is worth a lot for me.
Best wishes

// บักสีดา

Thomasdc
Posts: 208
Joined: Wednesday 11 March 2015 20:13
Target OS: Raspberry Pi
Domoticz version: Beta
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby Thomasdc » Friday 06 May 2016 16:18

someone got any progress with this?

im looking for a way to use my cam's for motion detection..

but all my cams are conected to an linux NVR (so the cams are in separated network ) but the nvr is in my network.. i would like to be able to trig a json link or something from the nvr.. so the nvr tells domoticz there was movement at a certain camera (its the camera that tells it to the NVR.. so now i woul like the NVR telling ti to Domoticz .. its linux.. so should be possible no? its an: Hikvision DS-7716NI-SP

In hikvision you have something like 'notify surveillance center' when selecting this its possible to send notification to the hikvison app on your android phone.. wouln't it be possible to make some 'surveillanc' center' on domoticz? and then when you enter the ip of domoticz into the ' notify surveillance center ip alarm' those notifications appears in domoticz (so this way a switch can be linked to an incomming notificaiton from hikvisonà

dilepa
Posts: 4
Joined: Thursday 16 June 2016 6:27
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby dilepa » Thursday 16 June 2016 7:30

Hi,

am a newbie, just followed the instructions, got everything installed.

When i run ./daemon start i get cannot find module 'node-dahua-api'

and gives errors.

Any ideas?

uronito
Posts: 6
Joined: Tuesday 04 October 2016 20:45
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby uronito » Thursday 20 October 2016 23:30

Hi,

Works like a charm!!!!!!!! it's Fantastic!!!!!

Can you implement ptzpresets and night/day profile by mosquito and switches in domotic?

Thanks for your effort!!!!!!!!!

User avatar
proohu01
Posts: 160
Joined: Friday 17 October 2014 12:20
Target OS: Raspberry Pi
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby proohu01 » Friday 02 December 2016 14:30

I've tried to get this working several times now. Still without success. This time I stated with a clean and fresh Jessie Lite.

The installation end with the following error:

Code: Select all

make: Leaving directory '/home/pi/ipcc/node_modules/unix-dgram/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:276:23)
gyp ERR! stack     at emitTwo (events.js:106:13)
gyp ERR! stack     at ChildProcess.emit (events.js:191:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
gyp ERR! System Linux 4.4.35-v7+
gyp ERR! command "/usr/bin/nodejs" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/pi/ipcc/node_modules/unix-dgram
gyp ERR! node -v v7.2.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/unix-dgram):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] install: `node-gyp rebuild`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1


If I try to start the deamon anyway, I get the same error as dilepa. Logical I gues because the installation didn't complete. Am I missing some dependancy?
Last edited by proohu01 on Friday 16 December 2016 20:53, edited 1 time in total.
Pi 2 B | Pi Camera | PiFace 2 | RFXtrx433E (KaKu + Oregon Scientific) | Plugwise (9 Circles) | Aeon Z-Wave stick (Fibaro - dimmers, sockets, RGB, screens/blinds) | RFXMeter (Kwh/water/gaz) | WOL | Onkyo Receiver | RTC | Hikvision | Netatmo | Satel Integra

uronito
Posts: 6
Joined: Tuesday 04 October 2016 20:45
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby uronito » Friday 16 December 2016 19:39

With the last firmware of dahua ip Cam (09/10/2016) Dahua Node Api cant connect to the cam, i think could be by autenthication method.

ipcc for domoticz cant connect to the cam at last firmware.

With the earlier firmware can connect.

In the new firmware, dahua uses digest autenthication, Can you implementing?

Thanks!!!!

Regards

juppiejo
Posts: 2
Joined: Friday 09 December 2016 0:16
Target OS: NAS (Synology & others)
Domoticz version:
Contact:

Re: IP Camera Controller (Dahua & HikVision)

Postby juppiejo » Sunday 29 January 2017 0:25

What would be the direction for the HikVision IPC's to work? I changed node-dahua-api into node-hikvision-api in server.js, but that shortcut didn't do the trick...


Return to “Camera's”

Who is online

Users browsing this forum: No registered users and 2 guests