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

    Controlling general purpose solenoids

    Scheduled Pinned Locked Moved Solved
    General Discussion
    3
    7
    305
    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.
    • jwiloundefined
      jwilo
      last edited by

      I need to control a simple low current solenoid on/off, without PWM control with a Duet 3 Mini 5+.

      I have connected it to OUT_5, and configured OUT_5 using

      M950 P5 C"solenoid"
      

      And attempted to switch it on/off using

      M42 P5 S1
      

      and

      M42 P5 S0
      

      But the solenoid does not energise. I can confirm 24V (my VIN voltage) is present on OUT5+, and that the solenoid works when powered with 24V on the bench, so it must just be something to do with my configuration.

      Hope somebody can help, many thanks.

      droftartsundefined 1 Reply Last reply Reply Quote 0
      • dc42undefined
        dc42 administrators @jwilo
        last edited by

        @jwilo I think he meant:

        M950 P5 C"out5"
        

        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

        jwiloundefined 1 Reply Last reply Reply Quote 0
        • droftartsundefined
          droftarts administrators @jwilo
          last edited by droftarts

          @jwilo said in Controlling general purpose solenoids:

          M950 P5 C"solenoid"

          'solenoid' isn't a valid pin name.

          Try M950 P5 C"solenoid".

          Try M950 P5 C"out5".
          See https://docs.duet3d.com/User_manual/Reference/Gcodes#m950-create-heater-fan-spindle-or-gpioservo-pin

          Ian

          Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

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

            @droftarts Thanks Ian, not sure I understand your reply. The bit I don't understand, if "solenoid" is not a valid pin name, why does your example use it too?

            I've read the docs for M950, but must not be wrapping my head around it.

            dc42undefined droftartsundefined 2 Replies Last reply Reply Quote 0
            • dc42undefined
              dc42 administrators @jwilo
              last edited by

              @jwilo I think he meant:

              M950 P5 C"out5"
              

              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

              jwiloundefined 1 Reply Last reply Reply Quote 0
              • jwiloundefined
                jwilo @dc42
                last edited by

                @dc42 Perfect! Thank you, that's the key I was missing. I thought the P value referred to which output you're using, and the name was a name you wanted to assign to the pin.

                I see now that P refers to the output you're creating, i.e. P1 is some solenoid, P2 might be a light etc, and the name is the name of the pin you want to map it to, great - all working now, thanks!

                1 Reply Last reply Reply Quote 0
                • jwiloundefined jwilo marked this topic as a question
                • jwiloundefined jwilo has marked this topic as solved
                • droftartsundefined
                  droftarts administrators @jwilo
                  last edited by

                  @jwilo said in Controlling general purpose solenoids:

                  if "solenoid" is not a valid pin name, why does your example use it too?

                  Sorry! Copy/paste failure on my phone!

                  Ian

                  Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

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

                    @droftarts No problem, thank you!

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