Author Topic: reverse on/off switch  (Read 11879 times)

0 Members and 1 Guest are viewing this topic.

Offline KlippMannTopic starter

  • Newbie
  • Posts: 5
reverse on/off switch
« on: July 04, 2013, 07:07:31 pm »
I want to have like in picture. normally light is on when i don't press button and when i press button it will go off. and it's just normal button normally off when pressed it's on? Thanks
 

Offline KlippMannTopic starter

  • Newbie
  • Posts: 5
Re: reverse on/off switch
« Reply #1 on: July 04, 2013, 07:09:28 pm »
this is just simplified version but it tell's what i need
 

Offline lewis

  • Frequent Contributor
  • **
  • Posts: 704
  • Country: gb
  • Nullius in verba
Re: reverse on/off switch
« Reply #2 on: July 04, 2013, 07:22:16 pm »
 :-+
I will not be pushed, filed, stamped, indexed, briefed, debriefed or numbered.
 

Offline KlippMannTopic starter

  • Newbie
  • Posts: 5
Re: reverse on/off switch
« Reply #3 on: July 04, 2013, 07:23:43 pm »
Thanks! :)
 

Offline KlippMannTopic starter

  • Newbie
  • Posts: 5
Re: reverse on/off switch
« Reply #4 on: July 04, 2013, 07:31:01 pm »
:-+

can y tell me what is that middle circle thingy :D im too noob with thease things
 

Offline madires

  • Super Contributor
  • ***
  • Posts: 7764
  • Country: de
  • A qualified hobbyist ;)
Re: reverse on/off switch
« Reply #5 on: July 04, 2013, 07:41:58 pm »
can y tell me what is that middle circle thingy :D im too noob with thease things

It's a NPN BJT (bipolar junction transistor). But you could also use a n-channel MOSFET if the light needs a high current. How much current does the light need?
 

duskglow

  • Guest
Re: reverse on/off switch
« Reply #6 on: July 04, 2013, 07:52:20 pm »
Alright, so I'm going to ask a noob question myself, because I think here's where I have always gotten confused about these things.

So I can follow the current flow just fine.  When the switch is open, the current flows through both the bulb and the resistor, energizing the base.  The base then switches the transistor on, and current flows through the bulb.  That's great, I get that.

But when the switch closes, I'm a little confused.  I would have thought that the current would flow BOTH through the switch and the transistor base, energizing the base AND causing current to flow through the switch.  So the transistor would, from that understanding, stay switched on, but the light would just dim because of the current being divided between both paths.  Can you please explain to me why the bulb would extinguish?

I'm actually being serious here...  this is one of the gaps in my knowledge I need to close.
 

Offline kolbep

  • Frequent Contributor
  • **
  • Posts: 598
  • Country: za
    • ShoutingElectronics.com
Re: reverse on/off switch
« Reply #7 on: July 04, 2013, 07:57:39 pm »
Just get a normally closed switch, and put it in series with bttery and bulb
====================================
www.ShoutingElectronics.com Don't just talk about Electronics, SHOUT ABOUT IT! Electronics Blog Site and Youtube Channel
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: reverse on/off switch
« Reply #8 on: July 04, 2013, 07:59:09 pm »
But when the switch closes, I'm a little confused.  I would have thought that the current would flow BOTH through the switch and the transistor base, energizing the base AND causing current to flow through the switch.  So the transistor would, from that understanding, stay switched on, but the light would just dim because of the current being divided between both paths.  Can you please explain to me why the bulb would extinguish?

I'm actually being serious here...  this is one of the gaps in my knowledge I need to close.

The resistor and the closed switch form a voltage divider. If the switch has a resistance of 0.1 ohm, then that gives 12V * (0.1 / 1000.1) = 0.0012V on the base. The threshold voltage is around 0.65, so it doesn't switch on.

It does conduct a tiny bit (picoamps), but that's not enough, considering the gain of the transistor, to switch the lamp on.
« Last Edit: July 04, 2013, 08:02:32 pm by c4757p »
No longer active here - try the IRC channel if you just can't be without me :)
 

duskglow

  • Guest
Re: reverse on/off switch
« Reply #9 on: July 04, 2013, 07:59:42 pm »
It's a NPN BJT (bipolar junction transistor). But you could also use a n-channel MOSFET if the light needs a high current. How much current does the light need?

If you're newbie enough to not know what a transistor is, tell us what kind of power source you're using too (AC vs. DC, and voltage).
 

Offline KlippMannTopic starter

  • Newbie
  • Posts: 5
Re: reverse on/off switch
« Reply #10 on: July 04, 2013, 08:01:06 pm »
Just get a normally closed switch, and put it in series with bttery and bulb

but i need a button it's like "hidden" closing thingy
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: reverse on/off switch
« Reply #11 on: July 04, 2013, 08:03:16 pm »
...what?
No longer active here - try the IRC channel if you just can't be without me :)
 

duskglow

  • Guest
Re: reverse on/off switch
« Reply #12 on: July 04, 2013, 08:04:21 pm »
Also, the current has to flow into the base, not just past it.

I don't understand the difference.  I would have thought that the current would be flowing to the base, though I will study your explanation about the voltage divider.  I'm obviously missing something very fundamental here.  Sigh.

I should have gone to school for EE and not piano.   |O :bullshit:
 

Offline madires

  • Super Contributor
  • ***
  • Posts: 7764
  • Country: de
  • A qualified hobbyist ;)
Re: reverse on/off switch
« Reply #13 on: July 04, 2013, 08:08:26 pm »
So I can follow the current flow just fine.  When the switch is open, the current flows through both the bulb and the resistor, energizing the base.  The base then switches the transistor on, and current flows through the bulb.  That's great, I get that.

But when the switch closes, I'm a little confused.  I would have thought that the current would flow BOTH through the switch and the transistor base, energizing the base AND causing current to flow through the switch.  So the transistor would, from that understanding, stay switched on, but the light would just dim because of the current being divided between both paths.  Can you please explain to me why the bulb would extinguish?

The current going into the base drives the transistor and "enables" the emitter. With the switch opened a low current via the resistor flows into the base and let the transistor pass current for the light. If the switch is closed the small current from the resistor is passed right to ground, i.e. no current into the base and no light. This is the brief version :-)
 

duskglow

  • Guest
Re: reverse on/off switch
« Reply #14 on: July 04, 2013, 08:13:31 pm »
So let me see if I understand this.  When the switch is open, the network is basically R1 and the emitter->base resistance.  So you get enough current to/through the base to switch the transistor on.

When you close the switch, the emitter-base is a higher resistance than the switch, so all that current gets shorted to ground, and there's not enough current to enable the transistor, basically making it an open circuit?
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: reverse on/off switch
« Reply #15 on: July 04, 2013, 08:18:12 pm »
Precisely.
No longer active here - try the IRC channel if you just can't be without me :)
 


duskglow

  • Guest
Re: reverse on/off switch
« Reply #17 on: July 04, 2013, 08:26:36 pm »
So this is why pull-up resistors work too, right?  current will flow through the resistor as long as the transistor is switched off and pulling no current, but once it does, it's much lower resistance than the pull-up so it really doesn't have much of an effect?
 

Offline madires

  • Super Contributor
  • ***
  • Posts: 7764
  • Country: de
  • A qualified hobbyist ;)
Re: reverse on/off switch
« Reply #18 on: July 04, 2013, 08:32:39 pm »
So let me see if I understand this.  When the switch is open, the network is basically R1 and the emitter->base resistance.  So you get enough current to/through the base to switch the transistor on.

Actually there's an intrinsic diode between base and emitter. If the threshold of 0,6V (silicon) is reached the emitter starts to pass current from the collector. The relation between both currents is hfe. If you use a BJT as switch you'll drive it into saturation mode, i.e putting enough current into the base to make it fully conducting.

Quote
When you close the switch, the emitter-base is a higher resistance than the switch, so all that current gets shorted to ground, and there's not enough current to enable the transistor, basically making it an open circuit?

The base is connected to ground and those 0V are lower than the threshold of 0.6V. And of cource no current will flow into the base and the transistor doesn't conduct.
 

Offline madires

  • Super Contributor
  • ***
  • Posts: 7764
  • Country: de
  • A qualified hobbyist ;)
Re: reverse on/off switch
« Reply #19 on: July 04, 2013, 08:38:33 pm »
So this is why pull-up resistors work too, right?  current will flow through the resistor as long as the transistor is switched off and pulling no current, but once it does, it's much lower resistance than the pull-up so it really doesn't have much of an effect?

Are you talking about a pull-up resistor at the base or at the collector? At the base the pull-up resistor switches the transistor on by default. At the collector it will give a "high" signal to the next part of the circuit until the transistor starts to conduct.
 

duskglow

  • Guest
Re: reverse on/off switch
« Reply #20 on: July 04, 2013, 08:45:11 pm »
The base is connected to ground and those 0V are lower than the threshold of 0.6V. And of cource no current will flow into the base and the transistor doesn't conduct.

Ohhh, so it's at ground potential!  So here's how I'm thinking about it in my head, tell me if I'm off (and yes, it's simplified for the sake mf my understanding it).  I see there as actually being two different circuits here that are connected together through the transistor.  The first circuit is a simple light bulb connected via a "switch" (the transistor).

The other circuit is basically the resistor, a diode, and a switch that shorts to ground.

So what happens is, the resistor in the second circuit has the purpose of dropping the current down to just enough to forward bias the diode.  Since the switch is open, the diode basically acts as a near short circuit, and has the side effect of biasing the transistor and turning it on.

When the switch is closed, the entire circuit "south" of the resistor is at ground potential and the resistor becomes the load.  So, since everything's at ground potential, nothing's really flowing, the diode stops conducting, and circuit #1 is switched off.

Sound right?
 

Offline MikeK

  • Super Contributor
  • ***
  • Posts: 1314
  • Country: us
Re: reverse on/off switch
« Reply #21 on: July 04, 2013, 08:58:14 pm »
Yes, but all you really need to know is that closing the switch forces the base to 0V.  The NPN transistor won't switch on until the base is above the threshold voltage.

This is why NPN transistors are said to be low-side switchers.  Some beginners want to put them on the high side of a load and then not understand why the it won't switch on.  Well, whatever voltage is at the emitter, the base has to be about 0.7V above that.
 

Offline madires

  • Super Contributor
  • ***
  • Posts: 7764
  • Country: de
  • A qualified hobbyist ;)
Re: reverse on/off switch
« Reply #22 on: July 04, 2013, 09:05:19 pm »
Ohhh, so it's at ground potential!  So here's how I'm thinking about it in my head, tell me if I'm off (and yes, it's simplified for the sake mf my understanding it).  I see there as actually being two different circuits here that are connected together through the transistor.  The first circuit is a simple light bulb connected via a "switch" (the transistor).

The other circuit is basically the resistor, a diode, and a switch that shorts to ground.

So what happens is, the resistor in the second circuit has the purpose of dropping the current down to just enough to forward bias the diode.  Since the switch is open, the diode basically acts as a near short circuit, and has the side effect of biasing the transistor and turning it on.

The resistor limits the current going into the base, because a high base current would destroy the transistor.

Quote
When the switch is closed, the entire circuit "south" of the resistor is at ground potential and the resistor becomes the load.  So, since everything's at ground potential, nothing's really flowing, the diode stops conducting, and circuit #1 is switched off.

Sound right?

Yes, current is just flowing through the resistor to ground.

You could also swap the transistor with a relay. The selenoid would be connected to the resistor and ground.
 

duskglow

  • Guest
Re: reverse on/off switch
« Reply #23 on: July 04, 2013, 09:11:20 pm »
I think I get it now.  I may have to experiment a bit, but it's making more sense to me.
 

Offline Stonent

  • Super Contributor
  • ***
  • Posts: 3824
  • Country: us
Re: reverse on/off switch
« Reply #24 on: July 04, 2013, 11:09:49 pm »
This is a great video on using transistors to control lights.



« Last Edit: July 04, 2013, 11:15:51 pm by Stonent »
The larger the government, the smaller the citizen.
 

Offline MacAttak

  • Supporter
  • ****
  • Posts: 683
  • Country: us
Re: reverse on/off switch
« Reply #25 on: July 05, 2013, 02:13:34 am »
Closing the switch is effectively the same thing as soldering the base and emitter together. It doesn't matter what else is going on in that circuit - if the base and emitter are connected together, the transistor cannot be "on".
 

duskglow

  • Guest
Re: reverse on/off switch
« Reply #26 on: July 05, 2013, 02:46:57 am »
Thanks all, I really hate asking stupid questions, but there are some pretty big gaps in my knowledge that I need to plug if I want to go anywhere with this.
 

Offline hlavac

  • Frequent Contributor
  • **
  • Posts: 536
  • Country: cz
Re: reverse on/off switch
« Reply #27 on: July 05, 2013, 06:54:43 pm »
Think of NPN BJT like this:
Base-Emitor is a diode in forward direction (anode at base, cathode at emittor).
Like any diode it develops a voltage drop across it before any significant current will pass thru it.

Collector-Base looks like another diode (anode at base, cathode at collector).
This diode is normally reverse biased (current could flow freely from base to collector).

Any current passing thru base-emitor diode will allow up to beta-times more current to pass from collector to emittor. Collector-emittor voltage drop will change to allow this current to flow, subject to minimal voltage drop of about 0.2V between collector and emittor.

PNP looks the same but the diodes are reversed (cathodes at base) and base current flows in the opposite direction (out of the base)
« Last Edit: July 06, 2013, 12:28:01 am by hlavac »
Good enough is the enemy of the best.
 

Offline lewis

  • Frequent Contributor
  • **
  • Posts: 704
  • Country: gb
  • Nullius in verba
Re: reverse on/off switch
« Reply #28 on: July 05, 2013, 08:40:21 pm »
Think of PNP BJT like this:

You mean NPN
I will not be pushed, filed, stamped, indexed, briefed, debriefed or numbered.
 

Offline hlavac

  • Frequent Contributor
  • **
  • Posts: 536
  • Country: cz
Re: reverse on/off switch
« Reply #29 on: July 06, 2013, 12:22:16 am »
yes NPN, typo :) Fixed
« Last Edit: July 06, 2013, 12:31:46 am by hlavac »
Good enough is the enemy of the best.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf