Secondary Menu

Arduino/Microcontroller MOSFET

The IRF540N is a great MOSFET to start turning bigger loads on and off. With three components you can turn on and off just about any DC load you have.

Turn loads on and off with your Arduino! Use 5V to control up to 100V. Add a motor, solenoid, or get creative!

Super Simple Arduino Load Driver V2.0 will be live on Kickstarter.com 7/13/2015. This is a breakout board for comonly used MOSFETs. The board is ready to use with screw terminals.

Step 1: Components You Will Need

The IRF540N is a great MOSFET to start turning bigger loads on and off. With three components you can turn on and off just about any DC load you have.

Components needed

1 N-Channel MOSFET is a IRF540N

1 Diode 1n4004

1 1K ohm Resister

Step 2: Wire Up the MOSFET

The MOSFET should be wired as shown in the picture.

Step 3: Code

Use the Arduino blink sketch to get started. This will turn the motor on for 1 second and then off for 1 second.

void setup() { // initialize digital pin 13 as an output. pinMode(13, OUTPUT);}// the loop function runs over and over again forevervoid loop() { digitalWrite(13, HIGH); // turn the LED on (HIGH is the voltage level) delay(1000); // wait for a second digitalWrite(13, LOW); // turn the LED off by making the voltage LOW delay(1000); // wait for a second}

Guys need some help here . Im using a irf830 power mosfet to control a dc light , but for some reason i can't control the mosfet via the gate . The light turns on automatically without even supplying signal to the gate . I connected the source terminal to the negative of the battery , one side of the light is connected to the battery and the other is connected to the drain of the mosfet . I tried the same connection using a transistor and it worked fine . totally confused . need some help PLZ

The IRLI520NPBF is a better choice over the IRF540N but the IRL540 is better yet with an Rds of 0.077 ohms that's 1/3 of the IRLI520NPBF Rds. Plus the IRL540 can handle a bit more amps. Also the NDP6020P is a true logic level P-channel MOSFET, the IRF5210 is not.

What Kickstarter project? I'd be interested to know more. Regarding your Instructable I'm interested in trying it with a latching circuit I designed being placed between the Arduino and your circuit. Then I'll use an infrared remote to turn my circuit on/off, thereby turning your circuit and load on/off.