Maker Pro
Maker Pro

Flickering flame simulation with PIR motion sensor - mostly need help with transistor, I think

seanspotatobusiness

Sep 11, 2012
193
Joined
Sep 11, 2012
Messages
193
It is right yes

You need to place the leds between the 6v rail to the collector of the transistor exactly like the way i did it in my circuit i posted

Well slap my head and call me Sally! I didn't realise that was how it worked!

This also doesn't make sense though! Now when I increase the voltage to the base of the transistor, the LEDs get dimmer. That's the opposite of what it should be?

uzi15HE.png
 
Last edited:

cjdelphi

Oct 26, 2011
1,166
Joined
Oct 26, 2011
Messages
1,166
You only have 1 transistor, there's simply not enough current flowing, add 2 transistors like in the schematic i posted, copy the darlington pair
 

seanspotatobusiness

Sep 11, 2012
193
Joined
Sep 11, 2012
Messages
193
You only have 1 transistor, there's simply not enough current flowing, add 2 transistors like in the schematic i posted, copy the darlington pair
But it doesn't make sense - a low voltage means a smaller current yet the LEDs are lighting up more. It's backwards!
 

cjdelphi

Oct 26, 2011
1,166
Joined
Oct 26, 2011
Messages
1,166
That's because lower the voltage the less saturated and less current flows from base to emitter allowing more current to flow from collector to emitter...

EveryCircuit is a good learning aid

(Limit the current via a 1k resistor to base)
 

seanspotatobusiness

Sep 11, 2012
193
Joined
Sep 11, 2012
Messages
193
That's because lower the voltage the less saturated and less current flows from base to emitter allowing more current to flow from collector to emitter...

EveryCircuit is a good learning aid

(Limit the current via a 1k resistor to base)

Oh I see. I was not aware of this either.

I made a modification to your circuit which you can see here: http://everycircuit.com/circuit/6111272301494272 - I added a resistor to make the capacitor charge more slowly but it does not affect the speed that the LED turns on. Can you tell why?

Edit: Actually it works but needs a really big resistor, like 2 Mohm.
 

seanspotatobusiness

Sep 11, 2012
193
Joined
Sep 11, 2012
Messages
193
Here's my circuit which uses a lower voltage to represent the PIR output. It's 2.6 V after 0.7 V drops on the diodes. The problem is that the light takes about six seconds to start coming on and once it starts, it's at full brightness in about a second.

Also, do you know how different the Every Circuit transistors are from 2N2222s? Thanks again.

http://everycircuit.com/circuit/4523679919112192
 

cjdelphi

Oct 26, 2011
1,166
Joined
Oct 26, 2011
Messages
1,166
Better to take a screenshot, make your circuit public, so others can help you, from my mobile i can't view your circuit as it loads the browser version
 

seanspotatobusiness

Sep 11, 2012
193
Joined
Sep 11, 2012
Messages
193
Better to take a screenshot, make your circuit public, so others can help you, from my mobile i can't view your circuit as it loads the browser version
Sorry about that. I thought the circuits would be shareable across platforms.

The second switch on this circuit is just to reset it without having to wait for the slow fade. The first switch simulates the PIR sensor circuit.

w06gw0J.png




When I add more sets of LEDs in parallel, the current gets shared across them and they don't get very bright.

OO0rzXh.png
 
Last edited:

cjdelphi

Oct 26, 2011
1,166
Joined
Oct 26, 2011
Messages
1,166
Make the circuit public, i'll load it up and take a look, your usernane is the same as here?

(@cjdelphi into the search box to find my circuits)

I'll modify it to make it do what you need
 

cjdelphi

Oct 26, 2011
1,166
Joined
Oct 26, 2011
Messages
1,166
Yeah the circuits are shareable, but android launches the browser and not the app (he needs an intent filter)
 

cjdelphi

Oct 26, 2011
1,166
Joined
Oct 26, 2011
Messages
1,166
The good news is i redesigned your circuit to do what you asked

The bad news, unless you switch to two leds in series to reduce the voltage drop, you're simply not going to get the current needed for 20ma

So i used a higher voltage, will that be a problem?


If so you can only use 2 leds in series per row, up to you....

Screenshot_2016-04-06-14-48-04.png

http://everycircuit.com/circuit/5336705198981120
 
Last edited:

seanspotatobusiness

Sep 11, 2012
193
Joined
Sep 11, 2012
Messages
193
Thanks a lot, cjdelphi! The voltage increase is fine - I can just get a different power supply or, the one I'm thinking of getting lets you set it at various voltages including 6, 7.5 and 9.

Can you tell me whether 2N2222 or BC337 is suitable for the NPN transistors? And what about the PNP transistor?

Does the transistor arrangement you used have a name (like the Darlington pair) so I can maybe read a bit more about it?

Thanks again!
 

cjdelphi

Oct 26, 2011
1,166
Joined
Oct 26, 2011
Messages
1,166
2n2222/bc337 is fine

Any pnp that is capable of total current is ok as well

Only the 2 npns out of emitter into base are in a darlington configuration...

I don't think it has a name for what i did in the circuit
 

seanspotatobusiness

Sep 11, 2012
193
Joined
Sep 11, 2012
Messages
193
I added an extra transistor to increase the current I could get through more strings of LEDs. I will probably use 15-18 LEDs. I just need to order the PNP transistor and I'll be set. Thanks again. I'll post some videos in a few weeks if I get it working.

Edit: Damn, I just noticed that adding that extra transistor causes it to switch on almost instantly and take way longer to turn off. Adding a resistor has at least slowed down the fading on, albeit increasing the time to fade off.
 
Last edited:
Top