Duet3D Logo

    Duet3D

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • Documentation
    • Order

    Solved Duet Wifi M587 Command

    Duet Hardware and wiring
    2
    7
    486
    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.
    • code7
      code7 last edited by

      I just updated my Duet Wifi to the latest FW. I now receive an error that the "P" parameter is missing in the M587 command. I read in the forum that M587 needs to be sent to the controller with a macro now.

      How do you send the macro if the controller Wifi connection isn't established?

      Can someone send me an example of their M587 macro or let me know if there is a better way to have the controller automatically connect to my computer over Wifi when it is powered ON?

      This is what has worked previously for me prior to updating the FW.

      ; Network
      M587 S"AM LAB"
      M551 P"Z75" ; set password
      M552 S0 ; Turn on Wifi
      ;M552 P192.168.1.0 ; enable network and set static IP - doesn't work, Static IP needs to be setup in Router

      Delta Printer Using a Duet 2 Wifi v1.04c, FW3.4.0beta2, Duet WiFi sever 1.26, Duet Web Control 3.3.0

      droftarts 1 Reply Last reply Reply Quote 0
      • droftarts
        droftarts administrators @code7 last edited by

        @code7 Follow the Getting Connected guide to add an SSID to the remembered networks list (using M587): https://duet3d.dozuki.com/Guide/1.)+Getting+Connected+to+your+Duet/7
        If you want to do it via a macro, you'll have to write the macro in a text editor, save it, and copy it to the SD card, then put the SD card back in the Duet.

        M587 https://duet3d.dozuki.com/Wiki/Gcode#Section_M587_Add_WiFi_host_network_to_remembered_list_or_list_remembered_networks writes the SSID and password to the flash memory of the WiFi module. If it's in your config.g, it's doing this every time you start up, which is not good for the flash memory of the WiFi module. You don't need to do this every time you start up, just once, so it is stored. So in more recent firmware it is ignored in config.g.

        If the SSID is already stored you actually want M552 S1 in config.g to enable the WiFi and connect. If you want it to connect to a specific SSID, you send M552 S1 P"AM LAB".

        Ian

        Cartesian bed-slinger with Duet 3 Mini 5+ WiFi : RRP Fisher Delta v1 with Duet 2 Maestro : TronXY X5S with Duet 2 Wifi (in progress)

        code7 1 Reply Last reply Reply Quote 0
        • code7
          code7 @droftarts last edited by

          @droftarts
          Once the Duet Wifi is connected to the network as verified through sending the M552 S1 P"password" command and receiving a response of "ok", how do I find the IP address that is being used?

          Sending "M552 S1" returns the following:
          Turn off the current WiFi mode before selecting a new one
          ok

          Delta Printer Using a Duet 2 Wifi v1.04c, FW3.4.0beta2, Duet WiFi sever 1.26, Duet Web Control 3.3.0

          droftarts 1 Reply Last reply Reply Quote 0
          • droftarts
            droftarts administrators @code7 last edited by

            @code7 M552 with no parameters reports the current network state and IP address.
            https://duet3d.dozuki.com/Wiki/Gcode#Section_M552_Set_IP_address_enable_disable_network_interface

            Ian

            Cartesian bed-slinger with Duet 3 Mini 5+ WiFi : RRP Fisher Delta v1 with Duet 2 Maestro : TronXY X5S with Duet 2 Wifi (in progress)

            code7 1 Reply Last reply Reply Quote 0
            • code7
              code7 @droftarts last edited by

              @droftarts
              Maybe the picture in step 10 of the Guide is outdated then.

              Sending M552 responds with the following:
              WiFi module is being started
              ok

              Delta Printer Using a Duet 2 Wifi v1.04c, FW3.4.0beta2, Duet WiFi sever 1.26, Duet Web Control 3.3.0

              droftarts 1 Reply Last reply Reply Quote 0
              • droftarts
                droftarts administrators @code7 last edited by

                @code7 No, M552 does report correctly (Duet 2 WiFi on RRF 3.3RC1):

                M552
                WiFi module is connected to access point BT-3HATHX, IP address 192.168.1.134
                

                Your WiFi is reporting that it is still starting up. The 'ok' response is just that the command was accepted. It can take around from 5 to 30 seconds to connect and get IP address. If it's not connecting after that sort of time, I'd expect an error message. Send M122 and post the response, making sure you can see the last part about the WiFi network.

                If you are still having problems, it's possible the firmware update of the WiFi module failed. Connect via USB and send M997 S1 to flash the WiFi firmware to the WiFi module.

                Ian

                Cartesian bed-slinger with Duet 3 Mini 5+ WiFi : RRP Fisher Delta v1 with Duet 2 Maestro : TronXY X5S with Duet 2 Wifi (in progress)

                code7 1 Reply Last reply Reply Quote 0
                • code7
                  code7 @droftarts last edited by

                  @droftarts
                  Thanks - reflashing the WiFi firmware fixed the problem.

                  Delta Printer Using a Duet 2 Wifi v1.04c, FW3.4.0beta2, Duet WiFi sever 1.26, Duet Web Control 3.3.0

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