Home     Contact     Forum     Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science     RSS     Terms of services     Privacy policy  
   
 Home     Forum     Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science   

Author Topic: switch 2 led with 2 pnp and 1 signal  (Read 23242 times)

0 Members and 2 Guests are viewing this topic.

cheerio

  • Sr. Member
  • ****
  • Posts: 306
switch 2 led with 2 pnp and 1 signal
« on: May 31, 2012, 00:32:52 AM »
Hi, i am a little bit confused how to do this.
The circuit i use so far is not very satisfying as the red led is never switched off completely on some bc557 series.

I want to use as few elements as possible. The Signal cannot provide any more current @VCC, but it can still sink 40mA @GND.
 

Can you give me a hint for a better design?
« Last Edit: May 31, 2012, 00:37:20 AM by cheerio »

kam

  • Administrator
  • Hero Member
  • *****
  • Posts: 1849
Re: switch 2 led with 2 pnp and 1 signal
« Reply #1 on: May 31, 2012, 12:15:25 PM »
What exactly are you trying to do with this circuit?
The reason why red LED do not turn off completely is because you do not completely saturate the right-side transistor. But what exactly are your specifications???

cheerio

  • Sr. Member
  • ****
  • Posts: 306
Re: switch 2 led with 2 pnp and 1 signal
« Reply #2 on: May 31, 2012, 12:44:08 PM »
if the signal is GND the Green LED should be lit. if the signal is VCC the Red LED should be lit.

kam

  • Administrator
  • Hero Member
  • *****
  • Posts: 1849
Re: switch 2 led with 2 pnp and 1 signal
« Reply #3 on: May 31, 2012, 15:42:08 PM »
Oh i see! You want to make something like a "logic probe". There are tons of probes in the internet with cmos and ttl ICs. If you want to go with transistors, then you need a NPN and PNP. Check out the attached file.  I have not test it so excuse me if i made a mistake, but this is the way you need to go...



EDIT:
I just noticed the subject once more and saw "with 2 pnp"... Is this a limitation?
« Last Edit: May 31, 2012, 15:44:04 PM by kam »

cheerio

  • Sr. Member
  • ****
  • Posts: 306
Re: switch 2 led with 2 pnp and 1 signal
« Reply #4 on: May 31, 2012, 16:53:35 PM »
unfortunately it is. I cannot draw anymore current from the signal :(
and the 2 LED are in one package with common GND.

cheerio

  • Sr. Member
  • ****
  • Posts: 306
Re: switch 2 led with 2 pnp and 1 signal
« Reply #5 on: May 31, 2012, 17:36:42 PM »
i think i try this with pnp, npn mosfet. they draw no current and do the job...

kam

  • Administrator
  • Hero Member
  • *****
  • Posts: 1849
Re: switch 2 led with 2 pnp and 1 signal
« Reply #6 on: May 31, 2012, 17:37:03 PM »
unfortunately it is. I cannot draw anymore current from the signal :(
and the 2 LED are in one package with common GND.

What is the signal current limitation? And the voltage? A darlington pair transistor can provide your 30mA with as low as 3.5 micro amperes. So if your signal is 5 volts, you can use easily a 1Mohm base resistor...
3.5 uA is nothing!

On the other hand, if you really cannot provide those 3.5uA, then consider using a fet transistor instead which has (theoretically) zero current

cheerio

  • Sr. Member
  • ****
  • Posts: 306
Re: switch 2 led with 2 pnp and 1 signal
« Reply #7 on: May 31, 2012, 17:39:28 PM »
oh boy... i totally forgot about those darlingtons :)
thx kam this should solve the problem.

Sir N

  • Newbie
  • *
  • Posts: 26
Re: switch 2 led with 2 pnp and 1 signal
« Reply #8 on: June 23, 2013, 04:08:56 AM »
Hi,

if the signal is GND the Green LED should be lit. if the signal is VCC the Red LED should be lit.
I know it's a little late for your need, but others may find it of use (and the attached png-files are all broken), so here's a clean way of doing it.
If the Vcc=red could be changed to Vcc=green, Q1 and R2 can be removed and R1 is then connected directly to the base of Q2.

It works on the fact that a red LED has got a voltage drop some 200mV+ lower than a green LED.

When Q2 is on (conducting), the combined voltage drop of Q2ce and the red LED will be lower than what the green LED needs.
Only when Q2 is off, current can flow in the green LED2.


Gee... An almost unreadable Captcha AND a ridicuolous pop quiz...
  "what is the name of the longest snake in the world?:"
Not being on a first name basis with any snakes, any guess should do, but it won't accept "Osvald".

If this is an ongoing event, this may be a very short brush, as I don't intend to spend more time on paranoid anti-bot devices, than on the actual content.

kam

  • Administrator
  • Hero Member
  • *****
  • Posts: 1849
Re: switch 2 led with 2 pnp and 1 signal
« Reply #9 on: June 24, 2013, 09:24:24 AM »
Gee... An almost unreadable Captcha AND a ridicuolous pop quiz...
  "what is the name of the longest snake in the world?:"
Not being on a first name basis with any snakes, any guess should do, but it won't accept "Osvald".

hehehehe! No it is not "Osvald"! About half a year ago, i had an extreme attack from spam bots. For over two weeks, the site was down once every two days. The provider eventually suspended my account and i had to transfer a 5Gb website from the old servers to new servers. I reconfigured hundreds of php scripts to match the new server. I kept the forum closed (which was the spam-bot backdoor) for a week or so. This is why old attachments are lost (as you noticed in another post of yours). We only have a forum because a site member (Cheerio) offered me a separated server to host the forum (which explains the different URL of the forum). It was not an easy decision to use so strange questions for new members, but i have to protect the site... For some one has to google for the answer...

Sir N

  • Newbie
  • *
  • Posts: 26
Re: switch 2 led with 2 pnp and 1 signal
« Reply #10 on: June 24, 2013, 19:19:12 PM »
Hi,

[...] i had to transfer a 5Gb website from the old servers to new servers.
A real PITA, I know, but don't you keep a backup at home?
I always do, even on pro-hosting with daily backup, just in case...


We only have a forum because a site member (Cheerio) offered me a separated server to host the forum (which explains the different URL of the forum).
How nice of him :)
You mean that spammers actually hacked other parts of your site through the forum?


It was not an easy decision to use so strange questions for new members, but i have to protect the site... For some one has to google for the answer...
I understand your concern, but I'd believe that the Captchas would be plenty protection and if spammerss can crack a Captcha, the pop-quiz would be small potatoes in comparison.

I seriously believe that some users will be put off and never submit their first post, due to having to spend as much time Googling for answers. Well I guessed Python and was let through, although a Googling indicated that the Anaconda is larger - but I don't really have any interest in snakes and few of your visitors will (pure statistics), so why not make relevant electronics questions at least? That way people might learn something in the process.

Adding to that, the "moderator approval" takes it so far off anything I have ever experienced on the 19 years existanve of the web, where the mantra is "it all happens this instant" rath than going back to snail-mail timing ;)


I just see tthat you removed it - Thanks :)


BTW. Do you have a loose estimate of how long before comments on the regular pages sift through?
(I wrote a comment to Giorgos Lazaridis on Long_Range_IR_Beam_Break_Detector) to offer some help and advice.

kam

  • Administrator
  • Hero Member
  • *****
  • Posts: 1849
Re: switch 2 led with 2 pnp and 1 signal
« Reply #11 on: June 26, 2013, 02:01:37 AM »
This is how it began. Spam-bots were regularly signing up fake users with spam emails. I had like 30.000 spam users. That kept for a year or more. Maybe two years. Then one day, they began the attack. More than 100 requests per minute for spam forum messages with advertisements for tools, cars, underwear, viagra, porn sites and whatever your mind can think of. The attack was so brutal that the hosts had to recover the server a few times 9especially this mysql).

You want my opinion about Captchas ??? crap!

For the comments, it depends on the number of comments and my free time (kam=Giorgos Lazaridis=Site owner). I reply from the oldest to the newest. It can take from a day to a week. Time is so valuable this month because i have to design a special circuit for big US manufacturer and time is running out (literally).

I've been working for him since November 2012 and this is why there is little or no new posts in my site. O promise i will come back with excellent new material for mosfets op-amps and transistors hopefully before the end of this summer.

Sir N

  • Newbie
  • *
  • Posts: 26
Re: switch 2 led with 2 pnp and 1 signal
« Reply #12 on: June 27, 2013, 13:41:32 PM »
Hi,

(kam=Giorgos Lazaridis=Site owner).
Oh OK, Kammenos, Lazardis, so which is your secret super hero alias?  ;D


Time is so valuable this month because i have to design a special circuit for big US manufacturer and time is running out (literally).
If I can be of any assistance, I'll gladly lend you a hand with that.
Right now I'm on a mini-vacation (with only a net-book PC and an Android phone), but I'm back home tomorrow, where I'm better equipped.

kam

  • Administrator
  • Hero Member
  • *****
  • Posts: 1849
Re: switch 2 led with 2 pnp and 1 signal
« Reply #13 on: June 27, 2013, 13:49:09 PM »
Giorgos is my name, Lazaridis my surname and Kammenos my Alias. Thank you Sir N for your offer to help, i'll sure keep it in mind!