Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Where to get stay on/off mini switches?

Status
Not open for further replies.
I think the ugly Judco switch is also momentary.

What are you switching? If it is DC then an alternate action circuit will use a momentary switch and alternate from high to low to high to etc.
 

Attachments

  • alternate action LED2.PNG
    alternate action LED2.PNG
    11.6 KB · Views: 163
  • alternate.PNG
    alternate.PNG
    13 KB · Views: 157
Are there any constant on/off switches for DC?

I'm just using them for a simple wired LED.

Can you use one side of a 4 pin for both the negative and positive of an LED, and then connect the battery to the corresponding pins on the other side?
 
If you connect an LED directly to a battery (with or without a switch) then the current will be much too high and the LED will instantly burn out. You must use a current-limiting resistor calculated correctly in series.

We do not know the schematic of the "sides" of the 4-pins switch you talked about.
 
All the small, 4-pin "tactile" switches that I've ever seen are only momentary SPST. The two pins on one side are connected together, as are the two on the other side. So there is only one set of contacts. Never seen that type in a push-on/push-off configuration...without needing extra active circuitry (per audioguru).

Ken
 
I've connected 3 AG3 batteries and single CR2032's directly to LED's. They work fine.

The two pins on one side are connected together, as are the two on the other side.

Oh, okay.
 
I've connected 3 AG3 batteries and single CR2032's directly to LED's. They work fine.
The AG3 is a tiny 1.5V button battery cell that cannot provide enough current to damage an LED.
The CR2032 is a small coin 3V lithium battery cell that does not provide enough voltage or current to damage an LED.
These little batteries have a high internal resistance that limits the current.

I never use button battery cells to light LEDs. Instead I use AA or AAA and sometimes 9V alkaline battery cells. Even my solar garden lights use an AA cell or two.
 
**broken link removed**

will these do
 
The "self-locking" type of switches wear out much sooner than 100,000 times because nobody counts the number of times it is pushed. I bet the contacts corrode and fail soon too.
Their extremely cheap (cheep, cluck cluck) price says why.
 
Do you need resistors for AA batteries of the same voltage? Are the button cell batteries not actually 3 volts or is it enough volts to make 3 with the resistance?

I connected an LED directly to a 9 volt battery and it did not light at all. I didn't know if it was already broken so I tried another one and it did not light either, but before I tried it I connected it to a CR2032 and it lit fine, and after I connected it to a CR2032 and it flashed on and off like it might not have been a good connection, or it was just broken or something. How do burnt out LED's act like? Do they just not light or what? Is it temporary and will it work again after you leave it for a while?

will these do

Gah, I really wish I could find ones like I linked to, but I guess I'll have to compromise. Are the switches with 3 pins on each side all connected together too?

Those switches will work for what I'm wanting them right now for, but something with a more button kind of top like the ones NorthGuy and me linked would be better all the way around since if possible I want to buy 100 or 50 or so for future projects.
 
I connected an LED directly to a 9 volt battery and it did not light at all. I didn't know if it was already broken so I tried another one and it did not light either, but before I tried it I connected it to a CR2032 and it lit fine, and after I connected it to a CR2032 and it flashed on and off like it might not have been a good connection, or it was just broken or something. How do burnt out LED's act like? Do they just not light or what? Is it temporary and will it work again after you leave it for a while?

Gah, I really wish I could find ones like I linked to, but I guess I'll have to compromise. Are the switches with 3 pins on each side all connected together too?
Those switches will work for what I'm wanting them right now for, but something with a more button kind of top like the ones NorthGuy and me linked would be better all the way around since if possible I want to buy 100 or 50 or so for future projects.

9 volts burn them out so fast you don't get to see the light,once dead always dead, they don't come back.

No not all connected 2 pole double throw. see drawing
 

Attachments

  • Untitled.png
    Untitled.png
    8.6 KB · Views: 133
Do you need resistors for AA batteries of the same voltage? Are the button cell batteries not actually 3 volts or is it enough volts to make 3 with the resistance?
Look at the datasheet of an AA or button battery on the website of a battery manufacturer. I look at Energizer or Duracell.

A new AA alkaline cell is about 1.6V when new and it can supply hundreds of mA of current for a few minutes. A new button alkaline cell is also 1.6V but can supply only maybe 20mA for a few seconds. A new coin Lithium cell is about 3.2V and can supply maybe 25mA for a few minutes.

Look at the datasheet for LEDs. They have a typical operating voltage and an absolute maximum allowed current. They are a diode that limits the voltage and when the voltage supplied to them is higher than their rated voltage then the current skyrockets unlike an incandescent light bulb that is simply a resistor. Most 5mm LEDs are operated at a limited current of 20mA. 30mA or more will burn them out. If the power supply (battery) can supply more voltage and more current than their ratings then a series current-limiting resistor must be used. The resistance is simply calculated.

I connected an LED directly to a 9 volt battery and it did not light at all.
You instantly burned it out.
The datasheet for a 9V alkaline battery shows that a new one can supply 500mA for about 40 minutes and more current for a shorter duration. The current in your LED might have been as high as 1500mA which is 50 times too high.
Or maybe you connected the LED with backwards polarity.
 
Hi,

With a 9v battery you need a current limiting resistor, at the least, AND you also need to be very very careful about connecting the LED backwards. If you connect it backwards even once, it could blow out at 9v, even with the resistor.
Without the resistor connecting it the right way will also blow it out because 9v will force too much current through the device.
So a better way to test it is with three AA cells in series and current limiting resistor of say 220 ohms, so if you get it wrong it wont blow out.

What you are looking for is a small "push on, push off" switch. You might find one somewhere but they are probably not as small as the smallest "momentary push on" type switches.
The "modern" way to handle this (and i almost hate to propagate this method) is to use a microcontroller that sleeps most of the time and only turns on once maybe every half second for a very short time to check to see if the button is pushed. Battery life for two or three AA cells in series can be very long like 2 years or longer, but yes it does eat some battery power.

So you are probably better off using a small slide switch. They can make these things pretty small these days because there is so little to their construction.
 
Ah, thanks audioguru.

I switched the LED back and forth a few times to make sure it was connected the right way.

If you connect it backwards even once, it could blow out at 9v, even with the resistor.

Why is that? If it has a resistor it's like you just have a few AA batteries isn't it?

The "modern" way to handle this (and i almost hate to propagate this method) is to use a microcontroller that sleeps most of the time and only turns on once maybe every half second for a very short time to check to see if the button is pushed. Battery life for two or three AA cells in series can be very long like 2 years or longer, but yes it does eat some battery power.

I see why you hate it..

What you are looking for is a small "push on, push off" switch. You might find one somewhere but they are probably not as small as the smallest "momentary push on" type switches.
So you are probably better off using a small slide switch. They can make these things pretty small these days because there is so little to their construction.

Okay. I might even get both just to see. Thanks!
 
Ah, thanks audioguru.

I switched the LED back and forth a few times to make sure it was connected the right way.


Why is that? If it has a resistor it's like you just have a few AA batteries isn't it?


I see why you hate it..


Okay. I might even get both just to see. Thanks!

Hi again,

A resistor in series with an LED does not limit current if the LED is connected backwards because the LED then draws very little current. That means the LED gets a huge voltage across it, in reverse, and a reverse voltage higher than 5 volts will often blow out the LED. LED spec's are usually such that the max reverse voltage is 5 volts. Going over that blows the LED or damages it so it blows out sooner than expected. It's hard to tell if it got damaged or not, so it's best not to ever do this. The simplest way to avoid this is to test them with a voltage lower than 5v, like 4.5v max which is about what you get with three AA cells in series, along with a series resistor to limit current. If you hook it up backwards, nothing happens, but at least it does not blow out so when you turn it around it works well.

Another method is to solder a 1N4007 (or similar) diode in anti parallel to the LED. Anti parallel means cathode of diode to anode of LED, and anode of diode to cathode of LED. This way if you do connect it backwards (with current limit resistor) then the diode conducts and that means it only allows 0.7 volts across the LED (reverse voltage) so the LED never burns out. This works with 9v too now because the diode protects the LED.
You should not keep this connected this way though for very long because it will drain the battery too fast and just use up a perfectly good battery for nothing.
This diode trick is especially good for the expensive LED's, or if you just have one of the LED's you need and dont want to take a chance burning it out.
 
Last edited:
MrAl:

Nice job on that post. In essence a LED wants to be fed a constant current. You can find LEDs labeled 5V or 12V or even 24 VAC/DC but they have a built in resistor.
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top