they are 3.8W each under 12V, does the arduino able to send sufficient power the E-M or must I make the arduino control a power relay which will give the power to the E-M ?
I would like to power a maximum of 12 Electro-Magnets.
Thanks for your help and advise if you have a better solution
Sorry, i'm not really experienced in electronics, but i must use this application for an Artistic project which is more my domain .
Thanks
Choose the transistor or MOSFET to suit the current that will flow. And make sure to place a diode backwards across the coil, to prevent inductive spikes damaging the transistor/MOSFET at the moment of switch-off.
Also, don't use the 5V from the Arduino to power the transistor and electromagnet coil combination. Use a separate supply, with it's ground connected to that of the Arduino.
If you're still unsure about the circuit, you could check out this article I wrote on driving electromagnets and other loads with Arduino. It covers how to choose a base resistor for your transistor as well as the advantages of MOSFETs over BJTs (normal transistors), or why you'll probably want to use logic level MOSFETs instead of 'normal' ones.
Also take a look at the diode (flyback diode) in the schematic: you need it because an electromagnet is an inductive load: when you turn off the transistor, the magnetic field will collapse, so current will keep on flowing in the coil, but it can't flow to ground because the transistor is closed. This results in a very high voltage (several hundreds of volts) at the transistor's collector/drain. This is lethal: the transistor will die if this happens too often.
PieterP:
If you're still unsure about the circuit, you could check out this article I wrote on driving electromagnets and other loads with Arduino. It covers how to choose a base resistor for your transistor as well as the advantages of MOSFETs over BJTs (normal transistors), or why you'll probably want to use logic level MOSFETs instead of 'normal' ones.
Also take a look at the diode (flyback diode) in the schematic: you need it because an electromagnet is an inductive load: when you turn off the transistor, the magnetic field will collapse, so current will keep on flowing in the coil, but it can't flow to ground because the transistor is closed. This results in a very high voltage (several hundreds of volts) at the transistor's collector/drain. This is lethal: the transistor will die if this happens too often.
You're misleading people a bit in that article you wrote.
You don't use a voltage divider to apply just the right voltage to switch a given current with a MOSFET.
You say:-
Take a look at the image for the schematic. You can use the formula for voltage dividers to calculate R1 and R2.
For example, if I want to drive a 12v 17A load with a BUZ11, I'll need a gate voltage of 6v (see graph).
6v is 12v/2, so R1 = R2. They could be 47kΩ, for example.
6V is the minimum voltage required. For lowest 'on' resistance, in a 12V circuit, you would apply 12V, not 6V.
PieterP:
Thanks for the feedback, I'll change it right away!
Excellent. I was going to suggest that.
It's really also better to recommend a series gate resistor, again just so you're promoting good practices. Then the pulldown resistor should go from the Arduino pin to ground, not from the gate to ground, otherwise it becomes another voltage divider.
Thanks for responding so well to my suggestion Pieter.
I thought that was to prevent high currents because of the capacitive effect of the gate when PWM'ing, is that correct? Or are there other reasons as well?
OldSteve:
Thanks for responding so well to my suggestion Pieter.
Always happy to learn something, or to gain some new insights .
PieterP:
I thought that was to prevent high currents because of the capacitive effect of the gate when PWM'ing, is that correct? Or are there other reasons as well?
Not just when using PWM. Any time a MOSFET is turned on or off, a high current flows into/out of the gate initially, until the gate capacitance is charged/discharged. After that, virtually no current flows.
You can effectively view the gate of a MOSFET as a capacitor. Because of the gate capacitance RC time constant when in combination with a series resistor, it does pay to keep series resistance to a minimum, but some resistance is a good idea. A 220 ohm resistor will limit the inrush current from the Arduino pin to about 23mA.