Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    MQTT integration in 3.5.0-beta.4_101 working not as should

    Scheduled Pinned Locked Moved
    Beta Firmware
    3
    5
    397
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • paulg4hundefined
      paulg4h
      last edited by paulg4h

      Hello,

      first thank's to bring MQTT into the RRF 3.5 beta firmware, I tried it and it works only limited and not as MQTT could.

      Current:

      • connection during config.g and setup of the one usable topic to publish before connecting to the broker.
      • publish from within GCode using M118 P6 to this topic
      • no LWT*
      • when an other topic is needed, disconnect mwtt set the topic and reconnect.

      Default:

      • while connecting set a LWT*
      • publish with M118 P6 T"devices/rrf-printer/wahtever" S"payload" where T is the topic.

      With this changes the usage of MQTT will be improved a lot, as example:

      • send values like temperatures, status details with daemon.g
      • get the device state when powered off (LWT)
      • use any other MQTT device as example switch a shelly / tasmota device from within GCode (macro or wathever)

      *LWT --> Last will and testament, this is used to tell the broker what to do when the client is disconnected. As Example set the dopic devices/rrf-printer/online with the payload false. And after the connection set the topic devices/rrf-printer/online with payload true will to the following.
      When the printer goes online it sets the topic devices/rrf-printer/online to true and when you power it off the broker sets the devices/rrf-printer/onnline topic to false after 15 to 30 seconds. So you will see when the devices is offline, eventbased without ping or others.

      Many thank's again for all your effort and hard work!

      dc42undefined 1 Reply Last reply Reply Quote 2
      • dc42undefined
        dc42 administrators @paulg4h
        last edited by

        @paulg4h thanks for your input. I've created https://github.com/Duet3D/RepRapFirmware/issues/880.

        dc42 created this issue in Duet3D/RepRapFirmware

        open Improve MQTT functionality #880

        Duet WiFi hardware designer and firmware engineer
        Please do not ask me for Duet support via PM or email, use the forum
        http://www.escher3d.com, https://miscsolutions.wordpress.com

        paulg4hundefined 1 Reply Last reply Reply Quote 0
        • paulg4hundefined
          paulg4h @dc42
          last edited by

          @dc42 many thank's!

          1 Reply Last reply Reply Quote 0
          • misterjtcundefined
            misterjtc
            last edited by

            @paulg4h is this still in the plans for 3.5 release? I am looking forward to having this functionality so I can plug in to home assistant.

            dc42undefined 1 Reply Last reply Reply Quote 1
            • dc42undefined
              dc42 administrators @misterjtc
              last edited by

              @misterjtc this is being worked on, but at this stage I don't know which improvements will be ready in time for the next 3.5 release candidate and hence in 3.5 stable.

              Duet WiFi hardware designer and firmware engineer
              Please do not ask me for Duet support via PM or email, use the forum
              http://www.escher3d.com, https://miscsolutions.wordpress.com

              1 Reply Last reply Reply Quote 0
              • First post
                Last post
              Unless otherwise noted, all forum content is licensed under CC-BY-SA