Maker Pro
Maker Pro

Solenoid Circuit Help

Skyman

Feb 17, 2015
22
Joined
Feb 17, 2015
Messages
22
Wasn't sure whether to post this in "Microcontrollers and Programming" or here so I posted it here as well.I'm new to Arduino and programming so I need some advice. My goal is simple: control a solenoid with an Arduino by using a MOSFET. I'll send a digital signal to the MOSFET, turning it on, allowing high voltage (+30V) to be applied to the solenoid. I'm using a TDK Lambda power converter that converts AC to DC. I'm not sure if my schematic is correct or not. Im confused about the difference between the Ground on the Power converter and the GND (Ground) on the Arduino. Also wasn't sure about the -V on the power converter and whether or not this connection along with the ground connection on the Arduino was correct. Any help would be greatly appreciated. I want to make sure my wiring has no errors.Scan 47.jpeg
 

Minder

Apr 24, 2015
3,478
Joined
Apr 24, 2015
Messages
3,478
I assume you are powering the arduino separately?
And if so the power common (-ve) for each supply has to be connected together.
If that was your question.
One problem with N.A. terminology, GND (chassis) is also used for (Earth) GND.

M.
 

Skyman

Feb 17, 2015
22
Joined
Feb 17, 2015
Messages
22
Maybe the question I'm trying to ask is if it is okay to have the Solenoid Coil going to the Ground of the Arduino. As in, when the Mosfet allows the high voltage to go from its drain to source, is it okay that it will go to the Ground of the Arduino like in my diagram? Is there a limit of voltage/current the Arduino can take for its ground pin? Is this a logical question to ask or is having a common ground (to the Arduino) the right thing to do?
 

Minder

Apr 24, 2015
3,478
Joined
Apr 24, 2015
Messages
3,478
Yes, when combining two separately sourced devices they both require a common reference point, in this case the 0v side of each supply, or GND if you like.
IOW both supply gnd's are connected. The solenoid current does not flow through the Arduino.
M..
 

Skyman

Feb 17, 2015
22
Joined
Feb 17, 2015
Messages
22
Yes, when combining two separately sourced devices they both require a common reference point, in this case the 0v side of each supply, or GND if you like.
IOW both supply gnd's are connected. The solenoid current does not flow through the Arduino.
M..

Thanks for the reply, I know it was a very novice question but I'm just learning about electronics so any advice will help. In regards to your first reply is yes I plan on supplying the Arduino with another external supply of 5V to its 5V pin. It's my understanding that this external power source cannot surpass 6V or so if connected to the Arduino 5V pin because it is unregulated. Also if I were to use the jack to power the arduino I would need anywhere from 7 to 12V. Just making sure, is this correct? (I don't have an arduino yet but plan on buying one for a pinball machine project)
 

CDRIVE

Hauling 10' pipe on a Trek Shift3
May 8, 2012
4,960
Joined
May 8, 2012
Messages
4,960
Wasn't sure whether to post this in "Microcontrollers and Programming" or here so I posted it here as well.I'm new to Arduino and programming so I need some advice. My goal is simple: control a solenoid with an Arduino by using a MOSFET. I'll send a digital signal to the MOSFET, turning it on, allowing high voltage (+30V) to be applied to the solenoid. I'm using a TDK Lambda power converter that converts AC to DC. I'm not sure if my schematic is correct or not. Im confused about the difference between the Ground on the Power converter and the GND (Ground) on the Arduino. Also wasn't sure about the -V on the power converter and whether or not this connection along with the ground connection on the Arduino was correct. Any help would be greatly appreciated. I want to make sure my wiring has no errors.View attachment 20795

As an aside I don't think this is a solenoid or even a DC to AC converter at all. This circuit looks more like a DC relay coil closing a circuit on AC Mains.

Chris
 

Skyman

Feb 17, 2015
22
Joined
Feb 17, 2015
Messages
22

CDRIVE

Hauling 10' pipe on a Trek Shift3
May 8, 2012
4,960
Joined
May 8, 2012
Messages
4,960
OK, I see now that the AC socket you have there is just the mains input to your Lambda power supply.

It's good practice (SOP) to place a 10Ω - 33Ω resistor between the output pin of the uC and the Gate of the MOSFET; to reduce ringing.

FYI: The resistor between GND and the Gate is not a "pullup" resistor. Pullup's connect to the + rail.

Chris
 

Skyman

Feb 17, 2015
22
Joined
Feb 17, 2015
Messages
22
OK, I see now that the AC socket you have there is just the mains input to your Lambda power supply.

It's good practice (SOP) to place a 10Ω - 33Ω resistor between the output pin of the uC and the Gate of the MOSFET; to reduce ringing.

FYI: The resistor between GND and the Gate is not a "pullup" resistor. Pullup's connect to the + rail.

Chris

Thanks for the advice and the clarification with the resistor. So in my drawing the resistor is considered a "pull down" resistor? Just want to make sure. Also you say that adding a small resistor (10 - 33 ohms) between the gate and controller pin will reduce ringing. What is ringing?
 

CDRIVE

Hauling 10' pipe on a Trek Shift3
May 8, 2012
4,960
Joined
May 8, 2012
Messages
4,960
Thanks for the advice and the clarification with the resistor. So in my drawing the resistor is considered a "pull down" resistor? Just want to make sure.
Actually that's a very good question. I've always just called it the "Gate Resistor" or "Gate - Source Resistor". Since the input resistance of the gate is near infinity the resistor can be considered to be a very light load on the signal source supplying the signal. I believe most of us would refer to the series (Anti-Ringing" resistor as the "Damping Resistor".

Chris
 
Top