MQTT value from zmeventnotification

Forum for questions and support relating to the 1.34.x releases only.
Post Reply
Jamieeburgess
Posts: 24
Joined: Mon Jan 06, 2020 3:48 pm

MQTT value from zmeventnotification

Post by Jamieeburgess »

Hi everyone,
So wonder if someone could help me modify WHAT is sent from the zmeventnotification service (or at least where I can change it).

I’ve got dlandon’s docker all set up and person detection is working well with tiny-yolo. However using node-red to interpret the results I would like to pull out what is detected without a lot of extra code to look at the “name” portion of the MQTT value.

Current is “ [s] detected: person : 76% : Motion : mudroom”
The rest of the MQTT value is JSON that can be used easily.

Is there a way to break out the above to something like:
{
“name” : “mudroom”,
“detected” : “person”
}
For example?
Not sure if it’s in the detect script or the start scripts, but hoping someone can point me in the right direction.

Thanks
User avatar
asker
Posts: 1553
Joined: Sun Mar 01, 2015 12:12 pm

Re: MQTT value from zmeventnotification

Post by asker »

This has been a TBD for a long time. As of now, you can write your own small parser but it really should be done by the detection engine.
The system was originally designed to push notifications to phones, which is why it returns a string. I'll work on it. Please keep track of https://github.com/pliablepixels/zmeven ... issues/206
I no longer work on zmNinja, zmeventnotification, pyzm or mlapi. I may respond on occasion based on my available time/interest.

Please read before posting:
How to set up logging properly
How to troubleshoot and report - ES
How to troubleshoot and report - zmNinja
ES docs
zmNinja docs
Post Reply