Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
I want to control the gate or base of a transistor by either a MCU gpio or push button. Can link gate to both the push button and MCU so I can choose which to use. What is best way to do this?
You can or them into the base like this...
simulate this circuit – Schematic created using CircuitLab
Or simply put the switch in parallel with the transistor.
simulate this circuit
Required, but never shown