Switching 555 ground and transistor questions

Discussion in 'The Projects Forum' started by Pencil, Apr 7, 2010.

  1. Pencil

    Thread Starter Active Member

    Dec 8, 2009
    271
    38
    Hey all,
    I am trying to make a simple circuit to indicate the
    status of two switches with one LED.
    I have attached the circuit for review.

    Operation desired is as follows:
    SW2 grounded, SW1 open; LED on continous.
    SW1 grounded, SW2 open; LED flashing.
    SW1 grounded, SW2 grounded; LED flashing.

    I have simulated and breadboarded it as shown and it
    seems to work as needed, but was wondering if I have
    made any errors that would be the cause of unreliability
    or shorten the lifespan of any of the components.

    I am particularly wondering about:
    1. switching the 555 timer on and off using ground.
    2. using Q1 to keep Q3 from turning on.
    3. connecting emmitters of Q2 and Q3.

    I'm inexperienced at circuit design so to get any advice would
    be an honor for me.

    Thanks for looking.

    P.S. Love the AAC e-books and all the advice given here.
     
    Last edited: Apr 7, 2010
  2. Wendy

    Moderator

    Mar 24, 2008
    20,765
    2,536
    You have a truth table:

    S1 S2 555
    .0...0...Flash
    .0...1...On
    .1...0...Flash
    .1...1...??? What do you want for this condition?

    Looking at it it looks OK, though I haven't traced the function. Want to see how I would do it?
     
    Last edited: Apr 8, 2010
  3. Pencil

    Thread Starter Active Member

    Dec 8, 2009
    271
    38
    Bill M,

    I would love to see how you would
    analyze this circuit.

    About the "truth table", I may not be
    understanding, but the switch positions are
    "grounded" and "open". My (as seen by you) logic 1 is actually "no connection" to ground or anything.

    Or am I confused?

    The answer the question about Logic 1,1 would be [LED off]

    I'll be back later.

    Thanks.

    P.S I love your Blogs and tutorials.
     
    Last edited: Apr 8, 2010
  4. Wendy

    Moderator

    Mar 24, 2008
    20,765
    2,536
    The first thought that occurred to me is what happens if you connect the LED to the positive side to the 555, instead of the negative side to the 555. The LED would then normally be on.

    I'm assuming you have some kind of sensors going to ground for this problem, so that is not amiable to change. Otherwise you could have the switch going to anywhere.

    So now the truth table is:

    .S1......S2.....555 LED
    .Gnd....Gnd.....Flash
    .Gnd...Open.....On
    Open...Gnd.....Flash
    Open..Open.....Off

    Thing that jumps out is if S2 is Gnd it flashes, S1 turns the LED on and off.

    Look like an accurate summation?
     
  5. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Pencil,
    I see you're using LTSpice, and their "ideal" NE555 timer.
    I uploaded a model of an LM555 with a .sym file that's a bit more convenient than the actual pin layout.

    Look at post #14 in this thread:
    http://forum.allaboutcircuits.com/showthread.php?t=36456

    You will notice that a component model 555 has somewhat different characteristics than the "ideal" model that LTSpice includes; one of the big differences is that the output (pin 3) won't get much higher than Vcc-1.3v.

    Instead of switching the ground of the 555, have you considered using a pull-up resistor (say, 1k-5k) from Pin 4 (reset) to Vcc, and switching that pin's ground?
     
  6. Pencil

    Thread Starter Active Member

    Dec 8, 2009
    271
    38
    SGT Wookie,

    Thanks for looking.

    I saw the 555 you posted the other day. I downloaded it, but
    haven't tried it yet. I also "borrowed" the pot that you posted
    (in the same thread?). I tried the pot, but couldn't figure out how
    to change the wiper position (it may be over my head).

    About the 555 Reset pin, I'll have to think about/try it but my first
    inclination is that I'm trying to turn timer ON when ground is connected.
    and OFF when ground is disconnected, pulling reset pin to ground
    will have the opposite effect (timer OFF when ground is connected).
    I'll have to think about this one a bit (and check Datasheet).

    I will try to "get my head around this".

    I am open to any suggestions.

    I'm posting a better description of what I'm trying to do.

    Thanks
    P.S. I read this forum alot, even if I don't understand most of it.
    You guys are amazing.
     
  7. Pencil

    Thread Starter Active Member

    Dec 8, 2009
    271
    38
    Okay I'll try to give a more detailed description of the circuit's operation.

    SW1 is a limit switch.
    SW2 is an operator push button to move a machine slide.

    1. Initial condition SW1 open SW2 open, LED OFF

    2. When SW2 is closed machine slide moves, LED is ON continuous
    Q3 turned on through SW2 being grounded, this turns on LED continuous.
    555 has Vcc but no ground,
    Q1 has NC on base,
    Q2 is off due to fact that 555 cannot
    sink current due to fact that it is NC to ground.

    3. SW2 still closed, SW1 closed as slide hits limit switch. LED Flashing.
    Q1 turned on through SW1,
    555 is grounded through SW1.
    Q2 being turned on and off by 555 this flashes LED.
    Q3 off because Q1 is holding its base to Vcc.

    4. SW2 is released (open), SW1 closed. LED Flashing
    Q1 is turned on through SW1.
    Q3 base held to Vcc by Q1
    555 is grounded through SW1.
    Q2 being turned on and off by 555 this flashes LED.

    5. Slide is moved off of Limit switch, SW2 closed, SW1 open. LED on continuous.
    See #2.

    6. SW2 released (open), SW1 also open.
    See #1

    This how I believe the circuit is working. The circuit does work.
    I hope I explained it correctly.

    Truth table:
    SW1 SW2 LED
    OPEN OPEN OFF
    OPEN GRND ON
    GRND GRND FLASH
    GRND OPEN FLASH

    SW1 to Ground = Flash, irrespective of SW2 condition.

    The original questions were:
    1. switching the 555 timer on and off using ground.
    (will this damage the IC?)

    2. using Q1 to keep Q3 from turning on.
    (condition #4 puts Vcc on base of Q3, but no path for current from Q1 due to fact that SW2 is NC)

    3. connecting emmitters of Q2 and Q3.
    (one transistor is ON while other is OFF, any damage to transistors?)

    4. Any other possible errors.

    I am trying to switch ground because one side of switch can be conveniently connected to machine base (frame) and requires only 1 wire back to control that if "shorted" will not affect power to rest of control.
    Rule #1: Do No Harm.

    I really appreciate any input, I am still learning.

    BTW this is my own concoction, this is why the uncertainty.

    I know you guys are busy and solving other people's puzzles takes time.

    I am patient (and humble).

    I think I just wrote a book.

    Thanks
     
  8. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Give it a spin. I think you'll like it. The NE555 model provided with LTSpice will run faster in a simulation, but it is more like a Superman-version of a CMOS model than either the BJT or CMOS.

    It's easy to change it. Just double-click on where it says:
    "Rtot=10k, wiper=.5"
    and change the total resistance to what the total pot value you want;
    typically values like 100, 200, 500, 1k, 2k, 5k, 10k, 20k, etc.
    and change the "wiper" value to anything between roughly 0.001 to 0.999.
    If wiper=.5 then the wiper's voltage will be exactly half-way between whatever is applied to the two "end" terminals.

    Checking the Datasheet is always a good idea.
    If you want to invert the function of the Reset pin, you could use a PNP transistor to do that.

    Instead of a pull-up resistor on the Reset pin, use a pull-down resistor.

    Connect the collector of a PNP transistor connected to the Reset pin.
    Connect the emitter to +V
    Connect the base to +V using a 5k resistor.
    Connect the base to your switch-to-ground using a 1k resistor.

    It's just that we've been at it a couple weeks longer than you have ;)
     
  9. Pencil

    Thread Starter Active Member

    Dec 8, 2009
    271
    38
    SGT Wookie

    I was rolling around the inverting idea around, then you posted
    and blew me away that we had the same idea (see I do pay attention).

    Anyway, according to Datasheet, output goes low if RESET is taken
    low. This would turn on my Q2, making LED on ON when SW1 is open.
    (RESET pin pulled down by pulldown resistor).

    I'm still thinking.

    You are giving me a work out.......I like it.
     
  10. rjenkins

    AAC Fanatic!

    Nov 6, 2005
    1,015
    69
    The first thing I'd do is add 1K or 2K2 resistors between base and emitter on Q2 and Q3 so they definitely off when there is no intentional base supply.

    As shown, both are floating when supposed to be off.
     
  11. Pencil

    Thread Starter Active Member

    Dec 8, 2009
    271
    38
    rjenkins

    Pull up bases like I have added ?

    How about Q1?

    Thanks
     
  12. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    I don't know if I just plain missed it or if you edited the post after I'd responded.

    After re-reading the posts preceding mine, I now realize that you want to control a machine with your circuit.

    You need to consider whether there will be any safety implications if and when any part of your circuit fails. If you do not take the time to do this, you may have some serious problems in the future.

    "Safety is no accident."
     
  13. Wendy

    Moderator

    Mar 24, 2008
    20,765
    2,536
    I get the feeling this is a simulation more than a machine. Am I wrong?
     
  14. Pencil

    Thread Starter Active Member

    Dec 8, 2009
    271
    38
    SGT Wookie

    You posted while I was typing.
    No worries on safety. It really is just an indicator.
    Also see below.

    Bill M.

    You are not totally wrong. I was/am pursuing a least likely solution to
    getting an indicator light working. The original operator panel had this
    indication but has long since quit working properly. The other options
    are, replace panel ($$$) or repair board (downtime). So, I'm off on a
    tangent and if it looks like it might work and not pose any risk to the
    operation of machine I'll throw the idea out there. And who knows, I
    might learn something (I already have).

    Thanks
     
  15. rjenkins

    AAC Fanatic!

    Nov 6, 2005
    1,015
    69
    You could add a 22K if you wanted just to be sure, but all the indirect connections to that go back to the positive supply when the switch is off, so it's less likely to cause problems.
     
  16. Wendy

    Moderator

    Mar 24, 2008
    20,765
    2,536
    OK, here is how I would do it. The RESET pin is fairly sensitive, I've had it consider 0.8V high, so diode gates don't work well for it. My solution was to go for a dual 555, which removes any uncertainty.

    [​IMG]

    The first circuit, the 555 provides a reliable 1Hz 50% cycle. The circuit U1B is also 1Hz, but not quite 50% cycle rates. It won't work with lower voltages, but 6V is OK.

    I don't think using a 556 is cheating, but maybe it is. :D
     
    Last edited: Apr 11, 2010
  17. Pencil

    Thread Starter Active Member

    Dec 8, 2009
    271
    38
    Thanks Bill,

    I just wanted to post so you would know I saw your version.

    I will try it out in a few days. I'm working on a "government job"
    that is due APRIL 15 (if you know what I mean) for the next few
    days.

    Thanks
     
Loading...