Integrating node red with event server Notifications

Discussion topics related to mobile applications for ZoneMinder
Post Reply
lorenjz
Posts: 29
Joined: Fri Feb 28, 2020 12:25 am

Integrating node red with event server Notifications

Post by lorenjz » Mon Jan 04, 2021 3:45 am

The more I work on and learn about the Zoneminder/Eventserver system, the more impressed I become with the number of possibilities. I've been wanting to integrate our home automation with Zoneminder but nothing really "fit" right until I was able to get MQTT working today. I think that there is one small piece that can be solved for our situation. I need some input though.

Both my wife and I wear smart watches. I found a script that runs on a raspberry pi that is able to monitor the signal strength of the Bluetooth signal from devices like cell phones and smart watches and broadcast that via MQTT to node red. My plan is to combine the motion detection of Zoneminder/Eventserver with the Bluetooth monitor in node red to decide whether motion is either of us and if so give us some added options for lighting and other automation but also if an event isn't triggered by either us then send a notification via zmninja. That's where the question lies. Is there a method or a way for me to be able to trigger a notification either MQTT or through the api to send a notification after node red has compared the presence or lack there of.

Thougths?

Any input would be appreciated!

Magic919
Posts: 475
Joined: Wed Sep 18, 2013 6:56 am

Re: Integrating node red with event server Notifications

Post by Magic919 » Mon Jan 04, 2021 8:07 am

I'd suggest facial recognition for that task.

In terms of your question, have a look at Home Assistant. It has some presence detection and is commonly combined with Node-RED and MQTT. Node-RED can speak to the ZM API.

Paranoid
Posts: 129
Joined: Thu Feb 05, 2009 10:40 pm

Re: Integrating node red with event server Notifications

Post by Paranoid » Fri Jan 15, 2021 9:23 pm

You could enable zmtrigger and then in Node Red use a TCP in Node to connect to zmtrigger to get the events real time.

EDIT:
I though getting Zoneminder events into my home automation system might prove useful to me so I put together a couple of nodes to do it.
Here they are, you might find them useful.

Code: Select all

[{"id":"b0daf047.a3069","type":"tcp in","z":"912ad38e.7e0d68","name":"","server":"client","host":"cctv","port":"6802","datamode":"stream","datatype":"utf8","newline":"","topic":"","base64":false,"x":110,"y":1120,"wires":[["4f442013.be7ce"]]},{"id":"4f442013.be7ce","type":"csv","z":"912ad38e.7e0d68","name":"","sep":"|","hdrin":"","hdrout":"none","multi":"one","ret":"\\n","temp":"Monitor,State,Time,EventID","skip":"0","strings":true,"include_empty_strings":"","include_null_values":"","x":270,"y":1120,"wires":[["fb9d9087.3bd598"]]},{"id":"fb9d9087.3bd598","type":"mqtt out","z":"912ad38e.7e0d68","name":"","topic":"test/alarms","qos":"","retain":"","broker":"f99a1a94.ce04c8","x":430,"y":1120,"wires":[]},{"id":"f99a1a94.ce04c8","type":"mqtt-broker","name":"Household","broker":"mqtt","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""}]

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest