Transistors
Transistors are 3 terminal devices, with a source, gate, and drain. Current goes in the source and out the drain.
pMOS should connect Vdd (at source) to lower voltages (at drain). They turn on if gate is connected to ground and off if gate is connected to Vdd.
nMOS should connect ground (at source) to higher voltages. They turn on if the gate is connected to Vdd and off if the gate is connected to ground.
Apparently there are two types of transistors: BJT (bi-polar junction) and MOFSET (metal oxide field effect). In class we used MOFSETs, but the tutorial at sparkfun goes over BJT.
So the bi-polar junction transistor (BJT) has three pins: collector, base, emitter. Transistors are like two diodes with their cathodes (anodes) tied together. But that isn't how they actually work.
Transistors = three different semi-conductor layers stacked together.
n-type semi-conductors have extra electrons (they're "doped", and negative).
p-type semi-conductors have electrons removed. They're positive.
Basically we have Collector-Base-Emitter, each being a layer. NPN is when the Collector and Emitter are n-type and the base is p-type. PNP is the other way around.
References:
https://learn.sparkfun.com/tutorials/transistors













