Pages: [1] 2   Go Down
Author Topic: Transistor Issue Plagues Me  (Read 2397 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 31
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello,

I have spent about 2 weeks trying to figure out what should be a very simple problem. I'm trying to control a solenoid with my Arduino Mega 2560 using a transistor. I'm desperate for assistance.

When I connect the solenoid and Arduino to the transistor, the solenoid does not turn on at all. When connected directly to my DC power source, the solenoid opens & closes just fine. Here's what I discovered:

My DC power supply sits at 16.6V / 1.8Amps. When I read the voltage across the transistor, the voltage is a correct 16.6 volts. However, the amperage is a measly 20mA. As a test, I tried connecting a 7.2V battery to the system and got the same results- 7.2V reading with the multimeter but only 20mA for the amperage. When I use the Arduino's 3.3V power supply as the source voltage, I can control an LED flawessly (but this is because the LED can noticeably illuminate at 20mA). Just so you know, I have tried switching around wires connected to Drain/Source pins just to see if anything would happen but.......nothing.

Quick question about the circuit diagram I included below: Why is there a "ground" and a "solenoid supply ground"? Aren't they the same thing? There's only two power sources- the arduino digital pin on/off and the solenoid's power supply, both of which connect to common ground.

I want to provide some data:

MOSFET Transistor Data Sheet
http://www.onsemi.com/pub_link/Collateral/NDF05N50Z-D.PDF

Circuit Diagram
http://arduino.cc/playground/uploads/Learning/solenoid_driver.pdf

Blurry Picture of my Circuit (Ask if Unclear)
http://i1176.photobucket.com/albums/x334/raccoonking1/Random%20Uploads/DSC_0309.jpg


Power supply: 16.6V, 18A
Arduino control pin: 13

-PRESTON
Logged

UK, Southwest
Offline Offline
Full Member
***
Karma: 5
Posts: 138
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The circuit diagram is for a NPN Junction Transistor, that is not the same as a MOSFET.  They do not work in the same way.

A NPN transistor will turn on with a current flowing from the base to emitter.  This will allow a bigger current to flow from the collector to emitter.  The base-emitter voltage will not get much bigger than 0.7V, so an Arduino output pin through a resistor will drive it.

A MOSFET will turn on when the voltage Gate to Source gets above the threshold voltage.  From your datasheet, it gives a figure for the threshold voltage of between 3 and 4.5 volts - depending on each device.  You may just not have enough voltage from a 3.3 V Arduino output pin to turn your device on.  The datasheet shows the device needs 10V to turn full on.

You need an intermediate transistor (NPN or a MOSFET that can be driven by a logic voltage) between the arduino and the power transistor; or change to a power NPN transistor as per the circuit diagram.
Logged

Offline Offline
Edison Member
*
Karma: 56
Posts: 2182
Now, More Than Ever
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

It's a "logic level" MOSFET, Vgs(th) is about 4V, which may be marginal.
But, Onward.

Quote
Why is there a "ground" and a "solenoid supply ground"? Aren't they the same thing?
If the arduino and the solenoid have separate power supplies, their ground/return should be connected together.

So, what happens if you touch/connect the 1K resistor to arduino's +5 (instead of a digital output)?

Quote
Just so you know, I have tried switching around wires connected to Drain/Source pins just to see if anything would happen but.......nothing.
In this case you probably just forward biased that "internal diode".  But, don't do stuff like that.
« Last Edit: May 05, 2012, 07:36:05 pm by Runaway Pancake » Logged

"Hello, I must be going..."
"You gotta fight -- for your right -- to party!"
Don't react - Read.
"Who is like unto the beast? who is able to make war with him?"

Offline Offline
Newbie
*
Karma: 0
Posts: 31
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Runaway Pancake,

The Arduino digital pin should be connected to the Base of the transistor. Does the Arduino's ground need to be connected to anything then?
Logged

Offline Offline
Edison Member
*
Karma: 56
Posts: 2182
Now, More Than Ever
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The Arduino digital pin should be connected to the Base of the transistor. Does the Arduino's ground need to be connected to anything then?
The arduino ground and the solenoid power supply ground should be connected together.

When I suggested:
Quote
So, what happens if you touch/connect the 1K resistor to arduino's +5 (instead of a digital output)?
I was trying to get you to check the MOSFET circuit by applying the arduino 5V to the Gate.
Can you try that?
Logged

"Hello, I must be going..."
"You gotta fight -- for your right -- to party!"
Don't react - Read.
"Who is like unto the beast? who is able to make war with him?"

Offline Offline
Newbie
*
Karma: 0
Posts: 31
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ah. Yes, I tried that with no response.

It appears that the transistors I have will not open up completely with the Arduino's voltage. I wanted to use Darlington arrays for simplicity, but the current I'm driving is too high for most of those.
Logged

Offline Offline
Edison Member
*
Karma: 56
Posts: 2182
Now, More Than Ever
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Fair enough.



* * *  Note that with this circuit the solenoid is "on" with a digitalWrite LOW, and "off" with a digitalWrite HIGH.
If that's not a constant duty solenoid get that digitalWrite HIGH done straight away.  OK?
« Last Edit: May 05, 2012, 09:23:08 pm by Runaway Pancake » Logged

"Hello, I must be going..."
"You gotta fight -- for your right -- to party!"
Don't react - Read.
"Who is like unto the beast? who is able to make war with him?"

Offline Offline
Newbie
*
Karma: 0
Posts: 31
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'd use that circuit if it weren't for the fact that I need to power 37 solenoids. I'm thinking that I will just buy a set of new transistors and sell the old ones. I really need to get a second opinion on this next purchase.

http://skory.z-net.hu/alkatresz/irfz44.pdf

Think these will work with the Arduino pins?
Logged

SouthEast UK
Offline Offline
Jr. Member
**
Karma: 0
Posts: 65
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I have used IRL640PBF mosfets to drive fair size motors with an arduino.
These are logic level drive devices. Take a look at the gate threshold voltage in the datasheet, this gives a good clue to their suitability for low voltage use.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 31
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

According to the datasheet for those mosfets, the maximum threshold voltage is 2V. You didn't experience any problems with the 3.3V from the Arduino pins?
Logged

Manchester (England England)
Offline Offline
Brattain Member
*****
Karma: 505
Posts: 31343
Solder is electric glue
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Take a look at the gate threshold voltage in the datasheet, this gives a good clue to their suitability for low voltage use.
NO!!!

The gate threshold voltage is NOT the voltage to turn on the FET, it is the voltage when the FET JUST STARTS to turn on. The IRFZ44 needs 10V on the gate to fully turn it on.
It is the gate voltage quoted with the Ron figure that tells you if it is a logic level FET.
« Last Edit: May 06, 2012, 11:38:37 am by Grumpy_Mike » Logged

United Kingdom
Offline Offline
Tesla Member
***
Karma: 220
Posts: 6587
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Can you tell us the current requirement of each solenoid? Without knowing that, it's difficult to make a recommendation for a logic level mosfet to use.
Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Offline Offline
Newbie
*
Karma: 0
Posts: 31
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

current requirement: 1.86A
Logged

United Kingdom
Offline Offline
Tesla Member
***
Karma: 220
Posts: 6587
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Assuming you want a through-hole component, something like this http://uk.farnell.com/stmicroelectronics/std17nf03l-1/mosfet-n-ch-30v-17a-ipak/dp/1752020 would be adequate and economical. If you are making a PCB and can use SMD devices, then there are lots of smaller and cheaper alternatives.
Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Offline Offline
Newbie
*
Karma: 0
Posts: 31
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello. I see that the gate threshold is 1-2.2 volts, but the gate to source voltage is 16V.
Logged

Pages: [1] 2   Go Up
Jump to: