My circuit works as expected, until I plug my solenoid into the breadboard. I am using a Raspberry Pi Pico to flip a FQP30N06 mosfet to actuate a basic 12v 300mA solenoid. I have the pico powered through the 5v rail on my breadboard and the solenoid on the other power rail with a 12v power supply capable of 4A. I have a common ground between them.
With the solenoid NOT plugged in to the breadboard, everything works as expected. I get 12v from my power supply, 12v through the mosfet when it's triggered, 12v across the flyback diode, continuity through the mosfet when it's triggered and none when it is not.
However, with the solenoid plugged in, I get no voltage or continuity across the mosfet, the Pico doesn't seem to be triggering the mosfet when the solenoid is plugged in. I still get the 12v from the power supply. I have verified that the solenoid can actuate when powered directly from the 12v power supply and I have tried switching the wires on the solenoid but it makes no difference.
Connecting and disconnecting the solenoid while the circuit is operating, yields no different results.
Hi,
Can you please forget the "CAD" diagram and draw your circuit by hand by using battery/power supply symbols and naming your components and labeling ALL pins, including the G, D, and S of the MOSFET.
What is R2 for?
While researching my problem, I saw a couple forum posts saying there should be a resistor between the gate and source. R2 was supposed to be that, but I drew it between D and S. It has been corrected in my schematic, it was correct on my breadboard.
jremington and LarryD were also right, I need to exchange these mosfets for the logic level version.
Hi,
Great schematic.
R2 can actually be increased to 10K, and moved to between PG6 and gnd.
Where it is at the moment it creates a potential divider with R1 and this means the gate voltage is less than the output voltage from GP6.
As the old saying goes, "You can't believe everything you read" and never more true on the Internet. Which includes the Arduino fora.
The conceptual problem here is that the FET gate does not "need to be pulled down".
The reason for the pull-down resistor is that until initialised, the microcontroller does not control its output pin. The microcontroller is the problem, not the FET, so the pull-down resistor goes at the microcontroller output, not the FET gate.
Though if you have it already wired up, give it a try.
R1 and R2 do form a voltage divider. But realistically, at 220 ohms and 10k, it will make no real difference.
In a voltage divider configuration, if the voltage at the pin is 5V, the voltage at R1-R2 junction will be 4.89V. At 10% resistor tolerance, with max on R1 and min on R2, it will be 4.87V.
Please do the calculation yourself to confirm.