Go Down

Topic: How to drive 325 Volt driven solenoids with the arduino? (Read 4364 times) previous topic - next topic

bastenhoor

Hello there!

I've been working on a project with solenoids for a while now and I need some help:

First I read the solenoid info on http://www.arduino.cc/playground/Learning/SolenoidTutorial
Then I rebuild the schedule at http://www.arduino.cc/playground/uploads/Learning/solenoid_driver.pdf
I got that all working BUT...
My solenoids are not pulling hard enough to hit my drums (I make drums of every cylindrical object with cow-skins and other).
So I tried putting 6 solenoids in series and give it a lot of power.
Recently I got a 15" monitor and the bridge rectifier reads 325 Volt, there is a fuse for max 4 Ampere.
My multimeter shows 0.42 Ampere when they are powered.
And it works! Really good actually. The solenoids are not even getting warm (with pulses).
So now I would like to drive it with the arduino.

The harware so far:
- 6 x Solenoid (from Central heating system) in series, max rated 28 Volt and 165 mA.

- Among the hardware from the monitor (allready soldered out) are a high power NPN transistor:
  C5129, see the datasheet at: www.tendaji.nl/C5129_npn.pdf
- and a high power diode:
  5TUZ52C, see the datasheet at: www.tendaji.nl/5TUZ52C_diode.pdf

My questions (I would really like to use the PWM functionality from the arduino to vary the hits):

- Can I use the high power NPN transistor and diode from the monitor? And if so, how do I drive them with the arduino.

- If not, what do I do?

- How can I make sure I don't damage the arduino? I've read I don't have to connect the arduino ground to the solenoid power ground, but where do I connect it to?

- I've seen optocouplers with MOSFETs in one package like PS7241E-1A (datasheet: www.tendaji.nl/PS7241E-1A_octo_mosfet.pdf), is that an option?
  I've got a opto-coupler working, to drive a LED on and off, but it can not handle large currents (60mA max).

- Right now the solenoids use 0.42 Ampere, can I do something to make that number grow?

- I've bought 60 (@ 1 euro a piece!) of these solenoids and am planning to make a drum machine ;-)

Thanks in advance!
Bas ten Hoor

RuggedCircuits

Quote
Can I use the high power NPN transistor and diode from the monitor? And if so, how do I drive them with the arduino.


Yes, although the main benefit of that transistor is its high voltage rating (1500V). Other transistors will work "better" (i.e., require less current from the Arduino because of higher gain, and dissipate less power because of lower saturation voltage), although your transistor should function.

You can also use the diode from the monitor, but again its special quality is its high voltage rating and other, cheaper, diodes should work just as well (regular 1N4004) for the currents and voltages you will be using.

Quote
How can I make sure I don't damage the arduino? I've read I don't have to connect the arduino ground to the solenoid power ground, but where do I connect it to?


Don't allow high voltages to reach it! You haven't mentioned what you are using for a power supply for the solenoids. If you use the basic solenoid schematic interface you listed in your post you should be OK.

Quote
I've seen optocouplers with MOSFETs in one package like PS7241E-1A (datasheet: www.tendaji.nl/PS7241E-1A_octo_mosfet.pdf), is that an option?


Yes, but not likely required for the currents (0.42A) you are dealing with (I'm also assuming a reasonably-low voltage -- waiting to hear on the actual number!)

The optocoupler can be used to turn the switching transistor on or off, it won't be able to switch the solenoids by itself.

Quote
Right now the solenoids use 0.42 Ampere, can I do something to make that number grow?


Use higher voltage. But be careful to not exceed the power rating of the solenoid else it will be destroyed.

--
Beat707: MIDI drum machine / sequencer / groove-box for Arduino

retrolefty

#2
Jul 17, 2011, 07:55 pm Last Edit: Jul 17, 2011, 07:59 pm by retrolefty Reason: 1
The harware so far:
- 6 x Solenoid (from Central heating system) in series, max rated 28 Volt and 165 mA.

- Among the hardware from the monitor (allready soldered out) are a high power NPN transistor:
 C5129, see the datasheet at: www.tendaji.nl/C5129_npn.pdf
- and a high power diode:
 5TUZ52C, see the datasheet at: www.tendaji.nl/5TUZ52C_diode.pdf

My questions (I would really like to use the PWM functionality from the arduino to vary the hits):

- Can I use the high power NPN transistor and diode from the monitor? And if so, how do I drive them with the arduino.
Yes, it seems to have voltage and current specifications well above you stated requirements. You drive them like any NPN transistor, arduino output pin to a series wired current limiting resistor and then on to the base terminal of the transistor. Grounds must be wired between the arduino and the negative of the high voltage source for this to work.

- If not, what do I do?

- How can I make sure I don't damage the arduino? I've read I don't have to connect the arduino ground to the solenoid power ground, but where do I connect it to?

Unless you use a opto-isolator between the arduino output pin and the switching transistor, you MUST connect the high voltage negative terminal to a arduino ground pin. Considering the high voltage you are switching I think the use of a opto-isolator is a very good idea.

- I've seen optocouplers with MOSFETs in one package like PS7241E-1A (datasheet: www.tendaji.nl/PS7241E-1A_octo_mosfet.pdf), is that an option?
 I've got a opto-coupler working, to drive a LED on and off, but it can not handle large currents (60mA max).

It doesn't need to be able to handle the total solenoid current value, as the switching transistor is a current amplifier, so the opto-isolator output only needs to able to supply enough base current that the transistor requires, 10 millamps of base current should be more then enough.

- Right now the solenoids use 0.42 Ampere, can I do something to make that number grow?

The solenoid current is determined by the coil resistance of the solenoid, You can change the coil resistance only by adding or removing turns of wire from the solenoid's coil.  you can increase the current drawn by the solenoid by raising the high voltage value you are driving the solenoids with. There is a limit to how high a voltage you can use with your solenoids, dictated by the coil wire voltage insulation value and current carrying limit of the wire size gauge used in the coil winding.

- I've bought 60 (@ 1 euro a piece!) of these solenoids and am planning to make a drum machine ;-)

Nice price, and good luck with your experimenting with them. Work safe, high voltage can harm.

Lefty


bastenhoor

Hi, thx for replies!

@ RuggedCircuits:
I'm using 325 Volt from an old monitor. It doesn't damage the solenoids, altough they get warm, but I'm using pulses and not
constant power. Below is a table with some data when the solenoids are in series, from about 4 they don't get warm any more.


@ retrolefty:
I've been working on the octocoupler circuit. Because I'm new to this I've started with a npn driven motor circuit that was
connected directly to the arduino, then I put in the octocoupler and a seperate power supply, see
www.tendaji.nl/motor_motor_octocoupler.jpg for my final and working schematic.
The questions here:
- Is the schematic correct?
- Why is R1 only 10 Ohm when I use the octocoupler and 2.2K without?
- I've put in a 7805 to get a constant 5 Volt, but without the capacitators, is that OK?

So now I've also made the same schematic with the solenoid (see www.tendaji.nl/solenoid_solenoid_octocoupler.jpg).
First the original circuit that worked fine. And below it a schematic
with optocoupler and seperate power supply. As you can see I've put in a question mark for the connection from the power supply
(+) to the collector of the octocoupler. I'm guessing I need to make a voltage divider/resitor to get the voltage between 30 and 5
volts so my 7805 will generate a constant 5 volts. I'm also guessing that I need a resistor that can dissipate more than 0.25
Watts.
The questions here:
- Am I guessing right? ;-) If not, what should be in place of the question mark?
- If so, how many resistors do I need to make the voltage division? And how to calculate te resistance?

Some more questions about the transistor (C5129):
- The datasheet says it has a very low saturation voltage (3V), I'm trying to give it 5V, is that too much?
- If the solenoids take 0.42A, how much current is going to the base of the transistor? How do I influence that? Or better: how
much current does the base need to make the solenoids get 0.42A?
- Would you recommend another transistor?

I've also made a table with solenoid information:
Each solenoid says: max 28V and max 165mA

Provided with 325V:



















#Solenoids in series   Amps used   Resitance
11.63124
21.17245
30.75382
40.59505
50.48635
60.42728
70.36858
80.31985
90.281114
100.251236
110.231363
120.211490


Again, thanks in advance!

Grumpy_Mike

#4
Jul 24, 2011, 08:58 pm Last Edit: Jul 24, 2011, 09:16 pm by Grumpy_Mike Reason: 1
Quote
I've put in a 7805 to get a constant 5 Volt, but without the capacitators, is that OK?

No.

Quote
As you can see I've put in a question mark for the connection from the power supply
(+) to the collector of the octocoupler. I'm guessing I need to make a voltage divider/resitor to get the voltage between 30 and 5
volts so my 7805 will generate a constant 5 volts.


Don't use a potential divider. Use another mains PSU that output 10 to 20V.

Quote
Why is R1 only 10 Ohm when I use the octocoupler and 2.2K without?

Stupid error? I don't know, but it is defiantly wrong.

Quote
- The datasheet says it has a very low saturation voltage (3V), I'm trying to give it 5V, is that too much?

The saturation voltage is the voltage you get when the transistor is on. This is nothing to do with "giving it" anything.

Quote
If the solenoids take 0.42A, how much current is going to the base of the transistor?

As much as you give it.

Quote
How do I influence that?

Use a series base resistor.
Quote
how
much current does the base need to make the solenoids get 0.42A?

Base current needs to be at least collector current times transistor gain.

Seriously if I knew as little as you appear to know then tackling a project with 324V is the last thing I would do, unless I had a suicidal tendency.

bastenhoor

OK guys, your warnings taken very seriously, I've made another schedule,
see www.tendaji.nl/solenoid_solenoid_octocoupler_v2.jpg.

I've used a PSU of 48V and put the solenoids in parallel, added the capacitors for the 7805.

Questions:
- Is the scheme correct?
- The GNDs of PSU1 and PSU2 are connected, this is OK?
- In the original scheme R1 = 1K or 2.2K, that's going to be the case too?
- How to calculate the transistor Q1?

Thanks again!
Bas

MarkT

Just to add to the safety warning - high voltage DC is even more lethal than AC as it switches all your muscles full on so you can't let go. That voltage will kill you if you make a mistake - is it worth the risk?
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

Magician

Agree with K7GKP, get rid of second psu and 7805. But you have to change transistor to get  higher h21, TIP120 darlingtons would be nice, as optocoupler can't supply more than 50 mA, and more important power rating is too limited.

To calculate more precisely value of base resistor and currents, please clear your data:
Quote
I've also made a table with solenoid information:
Each solenoid says: max 28V and max 165mA

Provided with 325V:
#Solenoids in series      Amps used      Resitance
1   1.63   124
2   1.17   245
3   0.75   382


V = I x R = 1.63 x 124 = 202.12 V  ---->>>   that isn't 325V
My guess, your table of measurements is wrong, as you didn't take in account that power supply voltage drops significantly under the load. Monitor voltage 325V, I think from video amplifier, is low power as all monitor <90 W, so it can't provide current more than ~300 mA.
But it's o'k if you don't use it anymore.
Measure resistance of the solenoids, so you'd know current for sure under 48V.
Calculate base resistor: Rb = 48 x h21 / Is.



Magician

Just underline one more reason not use high voltage power supply, in most cases it's low current, not good even for one(!) solenoid.

Go Up