Breadboarding: Connecting a Relay to the Microcontroller (with Transistor, Resistor and Diode)

The pin of the microcontroller is connected to a transistor that will switch on the current that will fire the coil of the relay so the relay can switch on. The pin of the microcontroller has a resistor to the base lead of the transistor. A protection diode is connected to the two leads of the relay coil to protect the transistor from a current spike from the relay coil. The diode is a signal diode 1N4001.



Back to blog

Leave a comment

Please note, comments need to be approved before they are published.