Electronic – Help needed… NPN current flow with 0v at Base

npn

I'm having a head scratcher:

schematic

simulate this circuit – Schematic created using CircuitLab

In my mind this should work flawlessly. The 5v/GND through R1 to the base of Q1 is controlled by a microcontroller (but for testing I am literally connecting to a 5v source or GND by hand)

Applying 5v… The Relay closes, great… but upon applying GND to the base the relay remains closed, meaning there is still a current flow. Only upon disconnecting GND from the Emitter of Q1 does the relay open again.

What am I doing wrong? I thought my theory was sound.

Best Answer

Try connecting the base directly to the emitter.

If that doesn't open the relay, then either you got the pinout wrong or the transistor is faulty.

If it does open the relay, then there's a problem with your ground.

Update:

As others have pointed, you should put a flyback diode accross the relay.

This will prevent the relay coil from creating a spike of overvoltage on the collector when the transistor is turned off fast.

If the transistor is faulty, that might be what killed it.