send alert from sensor
-
Hello, i build a sensor and i want to send alert to gateway if problem is detected.
How to send a variable to gateway?
In my mind, i send a variable to gateway and use lua to treat (send a mail for example).
Thank you for your help.
-
@nico What sort of sensor is it, could you not just use a lua script on the data it is already sending. Another option could be to add a switch (S_BINARY) to the sensor and have your node turn it on if a problem is detected. You could then have your lua code attached to the switch on change event.
-
it's a door sensor, the sensor test 3 times to activate relay and if nothing happen a variable(alert) is put to 1. I want to send this variable(for example) and generate an alert in lua. If you have another idea..
Thanks
-
I was wondering about this but currently don't have any nodes that need to report errors. I thought though I would wrap the error in a string including a prefix as well as importance of the error and send it back to the controller via S_VAR
I use MQTT gateway and I would have NodeRed listen out for any string with the prefix and send me an alert or log the event depending on the importance.
Just an idea at the moment but might help you.
Suggested Topics
-
Arduino Celebrates 10 years (Malmö/Sweden)
Announcements • 29 Mar 2014, 17:08 • hek 29 Mar 2014, 17:08 -
Home Assistant/MySensors quirks
Development • 24 days ago • OldSurferDude 24 days ago -
PJON and Minicore not working
Development • 19 days ago • Trand 19 days ago -
Adding Listen only device to my system.
Development • 26 Feb 2025, 00:39 • dpcons 26 Feb 2025, 06:26 -
Gateway without a radio
Development • 12 Jan 2025, 23:19 • OldSurferDude 14 Jan 2025, 22:07 -
Sending offset to node
Development • 31 Jan 2025, 00:59 • bsl88k 4 Feb 2025, 12:14