12VDC .17A Solenoid Controller

Discussion in 'The Projects Forum' started by Adunn, Jul 9, 2010.

  1. Adunn

    Thread Starter New Member

    Jul 9, 2010
    Hi all I am a Mechanical Engineering student with limited electronics experience. I am building a simple device using a pneumatic air cylinder and a solenoid controlled air valve and while all the mechanical parts are done I can not seem to find and easy inexpensive way to control the system. The goal is once plugged in the cylinder will just cycle between extended and retracted indefinitely.

    My thought was to use and alternating relay and an AC-DC converter to from the 110VAC in the wall down to the 12VDC required at the solenoids. My issue is I can not seem to find any 12VDC relays which I believe would mean converting after the relays therefore needing 2 converters instead of one which gets pricier.

    If anyone can direct me to some parts that would accomplish this or even a better system I am very open to suggestion.

    Thanks for any help,

  2. Dx3


    Jun 19, 2010
  3. retched

    AAC Fanatic!

    Dec 5, 2009
    You can get yourself a wall wart, to get you from your wall voltage to 12vDC for your relays.
    That is the safe way. The transformer in the wall wart will protect you from the mains voltage if anything goes awry.

    And a search will give you thousands or results on 12v relay
  4. John P

    AAC Fanatic!

    Oct 14, 2008
    I don't think you need a relay, just a transistor plus a freewheeling diode. And if you simply want the device to cycle back and forth, the easiest way to do it is with an LM555 timer set up as an oscillator. The frequency would be set by a resistor, and if you build it with a variable resistor, you could adjust it.

    And yes, for power supply you should be able to find a cheap, safe, simple wall wart.
  5. SgtWookie


    Jul 17, 2007
    Tell us about the solenoid valve that you're using. Is it a 5-port valve?
    You'll need one in order to reverse the direction of airflow in the cylinder.

    Trying to use timers on a pneumatic cylinder will be somewhat frustrating, as the travel of the cylinder is dependent on the load, the input air pressure, and friction/stiction in the cylinder itself. I suggest that microswitches are a convenient way to determine the absolute position of the ram. This naturally involves some fabrication work on your part to design and implement a mount for the switches, and a method for the ram to trip the switches without mangling them should a failure occur. A simple washer on the ram secured by a couple of jam nuts would be an adequate switch trip device. You could mount the switches to some fairly rigid aluminum angle; this is available at Big Orange and Big Blue hardware stores.

    Radio Shack carries these lever-action microswitches that have a roller:
    You will see that type of switch widely used in automotive and manufacturiing applications, so it will benefit you to get some experience with them.

    You can use these microswitches as a NO (normally open), NC (normally closed) or as a SPDT (single-pole, double-throw) switch. You use them to control the coils of relays or solenoids, rather than driving an actual load.

    Automotive parts stores carry lots of Bosch-type relays. You can get them in both SPST N.O. and SPDT configurations. The SPDT relays can be identified by having an 87a blade for a total of 5 spade connections; SPST relays will only have 4 spade connections. Either should work, but if your air switch has three terminals, you will probably need a SPDT relay.

    Here is a latching relay circuit that you can use to cause the ram to cycle - that is, if your air valve reverses the air flow by energizing or de-energizing the solenoid:


    Position one switch at the extended ram travel position, the other at the retracted travel position. Don't let the ram "slam" home; this is like using a big hammer on it.

    One simple way to keep the ram's speed manageable is to use a restrictive orfice at either the pressure port or exhaust port. If you use the orfice at the exhaust, it can also help to reduce the noise level. I made some "mufflers" using 1/2" brass tubing and flat brass stock soldered on one end, and a brass fitting soldered to the other end. I drilled rows of 1/16" holes in the tubing.

    With a typical 5-port spool valve, one side of the body will have two ports, the other side three. The two ports get connected to either end of your pneumatic ram. The side with three ports, you connect the center to either pressure or atmosphere, and the other two to atmosphere or pressure (opposite of what you connected the center port to).
  6. Adunn

    Thread Starter New Member

    Jul 9, 2010
    Thank you that has been very helpful. Yes I am using a 5 port valve, and I have flow control valves on the exit ports to control the speed. The only thing I am confused on, and again pardon my inexperience, but wouldn't the toggle washer on the ram hit it once as it passes in extension and then immediately hit it again as it start to travel back there by sending it right back into extension? I have not used such a switch and I am not sure on the the mechanics of it.

    Would the easiest way be to use a SPDT toggle switch that would just get flipped between energizing the two solenoids by one washer that hits the toggle at extension and another washer that hits the toggle at contraction?

  7. SgtWookie


    Jul 17, 2007
    OK, good.
    That will allow you to control the extension and retraction velocities separately.
    You adjust the position of the switch so that when the washer contacts the roller, the switch is actuated and the ram reverses direction immediately. Of course, if your ram is travelling at a high rate of speed, a washer will not allow adequate time for all the mechanical switching to occur. In that case, you might consider using something like a cylinder that has a conical taper at each end. The rollers would be smoothly actuated by the tapered ends of the cylinder. Of course, this involves some machine work, unless you could find a ready-made substitute.

    Ahh, you have two solenoids? :confused:

    You need to provide a more complete description of your valve and solenoid.

    A datasheet is preferred, as that eliminates many questions.