stacked transistors, to multiply the current gain!
Alternative for SMD mounting:
with a gain of ~1000 only little current is needed from the ATmega to drive the relay, and darlington transistors are common parts, easy to source and cheap.
Ic: 200mA (Relay current)
hFe: 200(min Value from Datasheet)
Ube: 1.6V (from Datasheet)
Ub: 5V (TTL from ATmega)
Ib: 1mA [Ic/hFE] (must be sourced from ATmega)
Rb: 3.4kOm [ (Ub-Ube)/Ib ] (in series from ATmega to Base)
next possible Rb is 3.3k, what will result in 1,03mA = 3,5mW, so every 1/8W or higher will work.
- TIP102baseCircuit.JPG (20.01 KiB) Viewed 24742 times
R1 = 3.3k (see above)
R2 = 100k (makes shure the TIP102 Base is grounded when the ATmega Pin is floating)
T1 = TIP102 Darlington transitor
D1 = 1N4007 (Flyback protection diode)