rszimm / sprinklers_pi

Sprinkling System Control Program for the Raspberry Pi
GNU General Public License v2.0
309 stars 100 forks source link

Zone status change report to Telegram bot (help wanted) #183

Open gargamelonly opened 3 years ago

gargamelonly commented 3 years ago

Hi, I see there are options to send log by email in some old threads. Is there a way also to send a message to a Telegram bot when a zone starts/stops irrigation? I know how to setup a bot and get it's key.

Thank you. [running the GreenIQ variant on an RPI]

nhorvath commented 3 years ago

There's an example shell script for sending emails but it's a nightly status report. There's no immediate notification.

gargamelonly commented 3 years ago

Could you please suggest a modified script to send the report via Telegram message instead of email? We could use the following: https://github.com/fabianonline/telegram.sh

nhorvath commented 3 years ago

actually i forgot i implemented something that can intercept zone changes. see this script https://github.com/rszimm/sprinklers_pi/blob/master/scripts/example_zone_script_passthrough.sh

if you still want the report that is in the same directory "report.sh"

gargamelonly commented 3 years ago

Sorry. I don't understand how to use it. Is simply copying the passthrough script to that folder will run it on every change of a GPIO? Do I need to remove the wiringpi command?

nhorvath commented 3 years ago

yes just follow the directions in the comment, replace the echo line with your telegram command. leave wiriginpi or your zones won't actually activate.

On Sat, Jun 12, 2021 at 12:00 PM gargamelonly @.***> wrote:

Sorry. I don't understand how to use it. Is simply copying the passthrough script to that folder will run it on every change of a GPIO? Do I need to remove the wiringpi command?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/rszimm/sprinklers_pi/issues/183#issuecomment-860072840, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABIJXFPZACGJSXSPHWV5ZLTSOADBANCNFSM46SMZAWQ .