MyRoboPathOpen Robotics Lab
All cheatsheets
ElectronicsQUICK REFERENCE

Transistors / MOSFETs

Switch a larger DC load with a low-side transistor circuit.

GPIO → loadMyRoboPath / Robotics field notes
Download PDF

01N-channel MOSFET

Connections
Supply + → load → drain; source → GND; MCU GND → supply GND.
Gate
GPIO → small series resistor (~100 ohm) → gate; ~10 kohm gate-to-source pull-down.
Selection
Choose a logic-level part with RDS(on) specified at your actual 3.3 V or 5 V gate drive.

02NPN alternative

Connections
Load to collector; emitter to GND; base driven through a calculated resistor.
Base resistor
Estimate sufficient base current for saturation, then Rbase = (Vgpio − VBE) / Ibase. Respect GPIO limits.
Dissipation
Check current, voltage and thermal ratings; a small signal transistor cannot drive every motor.

03Inductive loads

Flyback diode
Across load: cathode at supply +, anode at transistor drain/collector.
Power loss
MOSFET conduction loss ≈ I² × RDS(on), plus switching loss.
Startup
Pull-down keeps the load off while GPIO floats at reset.

Datasheets & further reading

SparkFun transistor guide