IRF520 MOSFET Switching Module, 0–24 V DC
Product details
Features:
- Operating voltage: 0-24V DC
- Maximum load: 5A
- Switching frequency: 100kHz
- Connections: screw terminals
- Dimensions: 33x24mm
Applications:
- DC motor control
- Pump control
- Solenoid control
- Lighting control
- Control of other electrical devices
Usage:
The module is simple to use. Connect the power supply to the module, then connect the load to the module output. Control it using a microcontroller or another digital device. A simple digital output is sufficient: when set to 3.3 V or 5 V, the MOSFET turns on; when set LOW, the module switches off the load (or reduces the output voltage).
Package contents:
- 1 × 0–24 V IRF520 MOSFET module
Note:
The module has no overload protection. Make sure not to exceed its maximum load of 5A. Overloading may damage the module. (For loads above 1 A, please use a heatsink.)
Simple Arduino test code for the MOSFET module: (switching the MOSFET on and off every second)
Copy the code and test it directly in the Arduino IDE. No additional libraries are needed.
// Definujte pin, ku ktorému je pripojený MOSFET
const int mosfetPin = 9;
void setup() {
// Nastavený pin ako výstup
pinMode(mosfetPin, OUTPUT);
}
void loop() {
// Zapnutie MOSFET na 1 sekundu
digitalWrite(mosfetPin, HIGH);
delay(1000);
// Vypnutie MOSFET na 1 sekundu
digitalWrite(mosfetPin, LOW);
delay(1000);
}
Simple PWM code:
This code gradually decreases and increases the MOSFET output voltage using PWM (pulse-width modulation) at 10-millisecond intervals. You can adjust the value 255 to your needs.
// Definujte pin, ku ktorému je pripojený MOSFET
const int mosfetPin = 9;
void setup() {
// Nastavte pin ako výstup
pinMode(mosfetPin, OUTPUT);
}
void loop() {
// Znižujte napätie postupne
for (int i = 255; i >= 0; i--) {
analogWrite(mosfetPin, i);
delay(10);
}
// Zvyšujte napätie postupne
for (int i = 0; i <= 255; i++) {
analogWrite(mosfetPin, i);
delay(10);
}
}
Wiring example:

Reviews
No reviews yet.



























































