0
\$\begingroup\$

I have wired the following diagram.

schematic

simulate this circuit – Schematic created using CircuitLab

My understanding of transistors is relatively poor, and thus I am assuming it has to do with the voltage threshold of the transistor not being met.

I have set both pins in the Diagram to high yet the LED does not turn on; however, when I remove the transistor and simply bridge the gap between the LED and GND the LED does turn on. I have check the voltage going to the Base of the Pin and it is 4.98V while the collector pin of the transistor is recieving 3.3V (roughly). Why is the transistor not working?

\$\endgroup\$
7
  • \$\begingroup\$ Are you sure you are using the 2N3904? Also remember that in this configuration, while the voltage is related, a BJT is what most would generalize as a current controlled switch. allaboutcircuits.com/vol_3/chpt_4/2.html \$\endgroup\$
    – Funkyguy
    Sep 8, 2014 at 19:50
  • \$\begingroup\$ It's actually 2N3906, if that changes anything \$\endgroup\$ Sep 8, 2014 at 20:38
  • 3
    \$\begingroup\$ Yes, of course it does. A 2N3906 is a PNP transistor, not the NPN you have shown. \$\endgroup\$
    – Dave Tweed
    Sep 8, 2014 at 20:46
  • \$\begingroup\$ Yea that makes a massive difference \$\endgroup\$
    – Funkyguy
    Sep 8, 2014 at 20:47
  • \$\begingroup\$ So, what difference does it make? \$\endgroup\$ Sep 8, 2014 at 23:13

1 Answer 1

0
\$\begingroup\$

I suspect that the emitter of the transistor is not connected to the Arduino ground. If you see 5 volts between the base and emitter, the transistor is definitely dead!

You also need resistors to limit the current through the LED, and to limit the base current into the transistor.

\$\endgroup\$
6
  • \$\begingroup\$ How do I determine the value of these resistors and why is this necessary, and yes it is connected to the arduino ground \$\endgroup\$ Sep 8, 2014 at 20:05
  • \$\begingroup\$ The value of the resistor in series with the LED is not critical, but should be somehere around 390 ohms. The base resistor should be 1 - 2K. \$\endgroup\$ Sep 8, 2014 at 20:07
  • \$\begingroup\$ Can you explain why? \$\endgroup\$ Sep 8, 2014 at 20:09
  • \$\begingroup\$ The voltage across a conducting diode (LED or otherwise) is determined by the composition of the diode - for common LEDs it is about 2 volts. If you apply a higher voltage to the LED, it will conduct as much current as the supply can provide. Fortunately, the outputs of a microcontroller cannot provide unlimited current, but the LED will still draw more current than the microcontroller pin is designed to deliver - the series reesistor limits the current to a safe value. The base-emitter junction on a transistor is also a diode, but its voltage will only be about 0.7 volts. \$\endgroup\$ Sep 8, 2014 at 22:37
  • \$\begingroup\$ The thing is, the way I have it now if I simply connect the LED to GND then the LED lights up, the problem I am having is that the Transistor (2N3906) is not allowing voltage through. I am measuring 2.5 V across the transistor (collector-emitter) and the base is recieving 4.98 V but It will not bridge the connection. \$\endgroup\$ Sep 9, 2014 at 17:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.