Comparing two circuits for amplifying a signal to turn on LEDs (NPN vs PNP transistors)

AlbertHall

Joined Jun 4, 2014
12,345
no matter where I put the capacitor, they only way it fades on and off is I use a huge capacitor. http://everycircuit.com/circuit/6159582916771840
Two things about your simulation circuit:
You need a resistor in series with each row of LEDs. At the moment you have one resistor inparallel.
There is supposed to be a 5k resistor between the capacitor and the base of the transistor driving the LEDs. This will help with the timing.
 

Thread Starter

seanspotatobusiness

Joined Sep 17, 2016
210
Two things about your simulation circuit:
You need a resistor in series with each row of LEDs. At the moment you have one resistor inparallel.
There is supposed to be a 5k resistor between the capacitor and the base of the transistor driving the LEDs. This will help with the timing.
Thanks. I was pretty sure I had tried that resistor between the capacitor and the transistor driving the LEDs without success but I've added it now and it's working.

The resistor in parallel with the LEDs is just to increase the current draw. The simulation software is not very user friendly and the only way to make space for adding more rows of LEDs is if I manually move each component individually. You can't select more than one component at a time.

I think this is the final circuit I will use. I removed the 10 K resistor at the top because it doesn't seem to make a difference to the performance.



Simulation: http://everycircuit.com/circuit/6159582916771840
 
Last edited:

hobbyist

Joined Aug 10, 2008
892
The performance of the LED's lighting up, removing the 10K resistor will not affect that, however the reason for the 10K, is to act as a pullup resistor, to keep the base emitter of the PNP around cutoff, because any leakage current through the input transistor during zero input conditions, could flow into the PNP causing it to turn on, remember how sensitive the circuit becomes to the smallest amount of input currents, the 10K helps to shunt any leakage current away from the PNP base input.
 

crutschow

Joined Mar 14, 2008
34,281
Thanks, I get it now. But how does the PNP transistor get around this? Is it because it's tapping into the 15 V to satisfy the bias?
.................................
I've changed my simulation to the PNP circuit and no matter where I put the capacitor, they only way it fades on and off is I use a huge capacitor. http://everycircuit.com/circuit/6159582916771840

Incidentally, is the 10 K resistor needed? When I change the value in the simulation or even remove it completely, it seems to have no effect on the function.
...................
The PNP transistor doesn't get around it, but as you noted, it's just that Vbe is now between the +15V and the first transistor's collector, so it has no effect on the required input voltage.

The fade period is related to the RC time-constant of the parallel value of the two 5kΩ resistors (2.5kΩ) and the capacitor so requires a large capacitor for a noticeable fade time.

No, the 10k resistor is not normally needed.
It's only purpose would be to shunt away any leakage currents at high temperature.
 

Thread Starter

seanspotatobusiness

Joined Sep 17, 2016
210
Is that a different component called a MOSFET?

I've built the original cricuit in breadboard, including the 10K shunt resistor but it doesn't work as expected; the circuit is always on, even if I disconnect the signals from the PIR sensors and connect the diodes to ground instead. I've taken voltage readings put some values on the schematic - some fluctuated so I put a range. Are there any other values (voltage, current or resistance) that I could measure which could inform a fix for the circuit?

 

AlbertHall

Joined Jun 4, 2014
12,345
Remove the leakage shunt from where it is and connect a 1k resistor across the base and emitter of the 2N2907.

[EDIT] You might also connect the now unused 10K across the base and emitter of the first 2N2222 (leftmost in your diagram).
 

Thread Starter

seanspotatobusiness

Joined Sep 17, 2016
210
Remove the leakage shunt from where it is and connect a 1k resistor across the base and emitter of the 2N2907.

[EDIT] You might also connect the now unused 10K across the base and emitter of the first 2N2222 (leftmost in your diagram).
Unfortunately the modifications didn't help; the circuit remains lit despite connecting the diodes to ground. Sometimes the voltage at the base of the first transistor was 0.30-0.40 but I'm not sure why.

 

AlbertHall

Joined Jun 4, 2014
12,345
If the supply voltage is less than 15.5V then there is a problem with the '2907 or its connections.
If the supply voltage is more than that then there is a problem with the leftmost '2222 or its connections.

Can you post a picture of the actual circuitry, please.
 

Thread Starter

seanspotatobusiness

Joined Sep 17, 2016
210
If the supply voltage is less than 15.5V then there is a problem with the '2907 or its connections.
If the supply voltage is more than that then there is a problem with the leftmost '2222 or its connections.

Can you post a picture of the actual circuitry, please.
I'm not sure the pictures can be properly interpretted due to the density of components. My multimeter doesn't have a function for testing transistors but I may have access to one this evening.

Edit: The supply is set to 15.0 V but actually provides 14.9 V according to my meter which I believe to be accurate based on comparison with a well-calibrated power supply (not mine).





 
Last edited:

AlbertHall

Joined Jun 4, 2014
12,345
No, you're right, I can't see enough.
Can you measure the voltage on the positive of the capacitor, please.

Check carefully the connections from the '2907 collector, 10k resistor, capacitor, 4k resistor, and the base of the '2222.
Check not only that those components are connected to each other correctly, but also that nothing else is connected to those points and look to see if any of the component leads are touching each other.
 

Thread Starter

seanspotatobusiness

Joined Sep 17, 2016
210
No, you're right, I can't see enough.
Can you measure the voltage on the positive of the capacitor, please.

Check carefully the connections from the '2907 collector, 10k resistor, capacitor, 4k resistor, and the base of the '2222.
Check not only that those components are connected to each other correctly, but also that nothing else is connected to those points and look to see if any of the component leads are touching each other.
Unfortunately the connection tested by continuity on component legs are sound and none are touching each other. The voltage on the capacitor is 2.4 V. There's this thing in my city on Tuesday evenings I can go to and maybe get help diagnosing the circuit. Failing that, I can throw it at a wall and see if it sticks! :mad: Thanks a lot for your help AlbertHall!

Edit: It works as expected when the input voltage is set lower, like 10 V, but I happen to have a 15 V supply I wanted to use.

 
Last edited:

Thread Starter

seanspotatobusiness

Joined Sep 17, 2016
210
Unfortunately I have a problem when trying to transfer the circuit to perfboard. I'm certain the transistors are inserted in the correct orientation but the circuit does not illuminate when the PIR sensor activates.

I took voltage measurements for the circuit in breadboard and in perfboard and the values are fairly close until the second transistor.


 

Alec_t

Joined Sep 17, 2013
14,280
The 2N2907 may be fried. You are pushing nearly 15mA through its base. You could increase its base resistor to at least 10K (likewise for the first 2N2222).
If the second 2N2222 has a Vbe of 6.3V then that transistor is either dead or has a bad connection.
 
Top