Notification via Pushover or other service
-
Pushbullet is another option that is free
https://docs.pushbullet.com/ -
would it be possible to have some gcodes that hit the url required to submit a message directly from the duet?
I'm particularly after a way to send a notification to my phone at the end of a print.
-
This is a similar request that could be fulfilled at the same time
-
FYI, I am developing a telegram bot (in testing phase) to the purpose that can easily run on a RPI Zero. I will keep you posted as soon as the code is stable I will opensource it.
-
Any solution should not be locked to a single proprietary service. Some kind of standard should be used so it can be integrated with anything.
E.g rest, json and oauth would be nice. Maybe something simpler and we could make a proxy-service for reaching out to other services.
-
A REST API would still require you to run some process on a PC or RPi etc. to send the notification. Any solution that sends the notification directly from the Duet would need to be configured to use a particular service. To be service-independent, there would have to be a standard interface to push services, that requires just a few details to be configured such as the URL and authentication details.
-
Why bother with authentication? The DWC is insecure as it is. If some process is needed on a PC or RPi, then let it handle the auth.
So.. my idea on this:
Keeping in mind that whatever notification is sent from the duet (and not from DWC), I'd imagine it would have to be extremely small/tight. That being said, and trying to imagine how I'd implement this as simply as possible, can the duet simply open a TCP socket and perform the equivalent of an HTTP GET?
So, there'd be hard coded notification types. Perhaps "printing", "paused", "stopped", "done", "error", etc (Or just notification numbers. 1, 2, 3, etc - each number having some meaning.)
Then a user configures a simple string that gets prepended to the notification string. For example:
M1234 P"http://mynotification.server.com?notification="
The duet, when any event occurs, just tries to make the call. Timeouts should be short, no retries, etc. Unless it's in some debug mode, and errors are ignored. Basically, the duet shouts something out and ignores the result (if any.)
Then a RPi, PC, or whatever that is running a "server" on mynotification.server.com gets the notification and decides what to do with it. It might ignore it, might run wget/curl/whatever to get more status info from DWC and/or forward the notification (along with encryption, authentication, etc) to something else.
On the duet side, KISS.
Edit: I don't think the duet has any DNS abilities, so the "URL" string would have to be an IPv4 address and not a name. So, replace the fictional "M1234" command with:
M1234 P"1.2.3.4?notification=" -
FYI, I am developing a telegram bot (in testing phase) to the purpose that can easily run on a RPI Zero. I will keep you posted as soon as the code is stable I will opensource it.
I'm running a Telegram Bot from my other printer so when you are looking for testers with the Duet, put out a request and I'm sure you'll get me (and others) to help test.
-
Have some RPI zeros and love the telegram bot
-
@luca79 said in Notification via Pushover or other service:
FYI, I am developing a telegram bot (in testing phase) to the purpose that can easily run on a RPI Zero. I will keep you posted as soon as the code is stable I will opensource it.
Hi Luca,
any news on the telegrambot? Looking so forward to it
-
I have added Pushover notification support to the firmware work list. I need to get firmware 2.0 released before I implement this or any other new features.