Node-Red Mobile Sized Status Dashboard for Duet

  • I've been running a simple node-red mobile/small screen sized 3d printer status dashboard form some time, which I recently updated to work with the Duet API after upgrading my printers.

    Its not very sophisticated - I am posting here in case it is of use to anyone else.


    The repo has two flows :

    The "universal" flow just requires the duet IP and webcam IP, it will ping the network, and when the printer is turned on check the Duet API version, and start updating the dashboard. Once the printer stops responding to ping it will stop updating the dashboard. The flow has been designed to be easy to follow. It could be significantly more optimised, should it be required. I would recommend reducing the polling frequency once you have it working (currently set for every 5 seconds), it does not need to be real time!

    The "example" flow is abstracted from my home automation dashboard, which includes MQTT calls and other automation stuff. It is provided as a reference example. This flow only updates the dashboard when the 3d printer is turned on via MQTT wifi socket.

    I wanted to be able to view both my 3d printers at a glance, control my enclosure temperature, and integrate the power control of my printers through my existing node-red home automation dashboard . Both of my printers are in my garage with external access only, hence I came up with this. It does not replace DWC. But I found status monitoring in DWC is not ideal for mobile/small screen and multiple printers.

    How I use the dashboard:

    Hope someone finds this useful!

  • Great Work!

    @dc42 Something for the community page?

  • Moderator

    @PCR said in Node-Red Mobile Sized Status Dashboard for Duet:

    Great Work!

    @dc42 Something for the community page?

    I'm on it!

  • great work. is it possible to include how long it takes to finish print and output via telegram maybe?

  • @ErwinH78 The Whole object model is available for you to get values from. It should be here: [job][timesLeft][file] (value is in seconds remaining).

    It would require adding a new node after "GET DUET STATUS" to get the value from the object model and route it to a telegram node. There are pre-built telegram nodes available in the Palette Manage of node-red.

    I'm currently working on something a little more advanced for users running v3.1+ with SBC's :

    Its a python script which runs on the SBC and can monitor the Object Model for value changes and send mqtt msgs directly to a broker. It's completely configurable so that you can select which values to monitor, and what msgs to send, plus it can react to specially formatted M117 commands.

    If your running 3.1+ with an SBC it might be worth a look (its very alpha though)...

    (edit: updated link)

  • @MintyTrebor
    I'am currently working on a flow to remote switch the printer.
    Realised over a Shelly 2.5.
    The Shelly only starts the boot sequence. Shutdown only is possible by sending G-Code . So it's self locking after a print is started.
    That also gives the possibility to auto switch off at the end of printing.
    As a beginner in node red it was a challenge to realise the logic of the buttons....They are getting active in relation to the state of the relay and the flow itself.
    But I have learned a lot, even to control the duet over html....


  • @MintyTrebor
    Just checked the flow chart.....amazing clean👍
    I wish I could do it rudimentarily that way...

  • @MintyTrebor
    node-red-contrib-looptimer2 ---> node-red-contrib-looptimer

    "node-red-contrib-stoptimer" is missing in the description

  • Thanks for the info. I did not include in the readme all the nodes used in the "example" dashboard, just the nodes in the "Universal" dashboard. I have made it clearer in the readme.

    Node-red-contrib-looptimer2 is a node available in palette manager and was used in the "universal" dashboard.

    I have also updated the notes to reflect the changes required to use the updated API object model used in the recent beta firmware(s). Its just a simple path change, nothing major.

    Edit: I have updated the Duet Dashboard Universal Flow:
    Updated to show how to get all three types of status updates from API V1.
    Included example of how to process Remaining Job Time
    Added alternative Object Model API Paths for Firmwares V3.1+

Log in to reply