🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Controlling 12v solenoid

    Scheduled Pinned Locked Moved Modules
    4 Posts 3 Posters 4.8k Views
    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.
    • R Offline
      richm
      last edited by

      I want to use an M5 to switch a 12v DC solenoid valve. I was hoping the GoPlus2 which takes a 12v input, but only outputs the motor voltage at 5v.
      Is there an 'off the shelf' solution?

      1 Reply Last reply Reply Quote 0
      • K Offline
        ksprayberry
        last edited by

        I don't know that the Goplus2 module would work. Could you maybe not use a relay module triggered from one of the GPIO on the M5 to operate the relay and then feed 12 volts to the solenoid valve that way? If you're using the goplus2 module in addition, you could just maybe split the 12 volt power off and route one leg through the relay so that when you make and break that relay you energize your solenoid valve.

        R 1 Reply Last reply Reply Quote 0
        • R Offline
          richm @ksprayberry
          last edited by

          @ksprayberry That's a good suggestion, bit I should have mentioned that I may need to 'pwm' the output at 20-30Hz so a relay won't last long.

          1 Reply Last reply Reply Quote 0
          • D Offline
            Dario
            last edited by

            If you need to PWM the output, you can use a mosfet module. You can find a cheap one on eBay or AliExpress.

            0_1610017280844_4cf5d38c-ba95-4ae3-886d-db7c5321ab59-image.png

            1 Reply Last reply Reply Quote 0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            • First post
              Last post