Basic Electronics Question

If you connect the positive lead to the negative lead of a battery we all know the high amps will generate heat and drain the battery too quickly.

I want to power a push button switch which contains an LED. This is a useless button for a cosmetic purpose that I want to just light up when it is pushed as intended. The (-)/(+) will be connected directly to the switch, with the only resistance being the LED inside.

Drill hole diameter: 16mm
Switch rating: 3A / 250VDC
Switch contacts: 1 NO, 1 NC
Material: Chrome plated brass
Grade: IP40/IP67
Contact resistance: < 50 mOhm
Insulation resistance: > 1000 Mohm
Temperature: -20 C to +55 C
Mechanical life: > 500,000
Electrical life: > 50,000
Panel thickness: 1-13mm
Operating pressure: 1.5 - 2.5 N
Operating stroke: 2mm
Lamp rated voltage: 6V
http://www.adafruit.com/products/559

How can I calculate the resistance needed to extend the life of the battery as long as possible while still lighting the LED.

I want to connect a standard 9v battery to this switch, however while the switch is in the on position I want the amp draw to be as low as possible to make sure it lasts long as possible.

Sidebar…

http://www.teknue.com/
Nameserver: NS1.YOUR-DOMAIN-HAS-EXPIRED.COM
Nameserver: NS2.YOUR-DOMAIN-HAS-EXPIRED.COM
Registry Status: redemptionPeriod

Ampix0: ...a push button switch which contains an LED.

Are you certain it is an LED?

Lamp rated voltage: 6V

LEDs generally have a "forward voltage" not a "rated voltage".

In either case, use a series resitor to limit the current. Does the LED have separate pins from the switch?

http://led.linear1.org/1led.wiz

[quote author=Coding Badly link=topic=263223.msg1856853#msg1856853 date=1409083626]

Sidebar...

http://www.teknue.com/ Nameserver: NS1.YOUR-DOMAIN-HAS-EXPIRED.COM Nameserver: NS2.YOUR-DOMAIN-HAS-EXPIRED.COM Registry Status: redemptionPeriod

[/quote]

Failed project that I just let die and never updated on here.

[quote author=Coding Badly link=topic=263223.msg1856855#msg1856855 date=1409083739]

Ampix0: ...a push button switch which contains an LED.

Are you certain it is an LED?

Lamp rated voltage: 6V

LEDs generally have a "forward voltage" not a "rated voltage".

[/quote]

This isnt exactly the same switch, I bought the same thing from a china site at a better price, but this is the switch.

http://www.adafruit.com/products/559

CrossRoads:
In either case, use a series resitor to limit the current.
Does the LED have separate pins from the switch?

I updated the main post with more information I should have posted earlier. Sorry for the vagueness. It does not have separate leads, I linked to the switch I bought (I actually bought mine from a china site cheaper).

Uh, OK. This is right from Lada Ada’s webpage…

If you want to use this with a higher voltage, say 12V or 24V, simply add a 470 ohm resistor in series with the LED connection to keep the LED current at around 20mA.

Start with a 1K ohm resistor. If the light is too dim make the resistance less until you reach 470 ohms. If the light is bright enough make the resistance more until you run out of patience.

Ampix0: It does not have separate leads, I linked to the switch I bought (I actually bought mine from a china site cheaper).

huh? Are you sure? Sure looks like it to me from the picture. How else would you power the led then?

I have used these AV (Anti Vandal) switches before in the past and all have had leads to power the LED..

Actually right on the Adafruit site it says:

On the back there are 3 contacts for the button (common, normally-open and normally-closed) and 2 for the red LED ring (+ and -). Connect 3 to 6V to the LED to have it light up nicely, there's a built in resistor!

Hi, how many terminals does it have? Please post a photograph of the switch you have, front and back. A link to the ebay page that you purchased it from would help.

Tom..... :)

If it's really the same as the Adafruit one then the Adafruit info has all you need.

On the back there are 3 contacts for the button (common, normally-open and normally-closed) and 2 for the red LED ring (+ and -). Connect 3 to 6V to the LED to have it light up nicely, there's a built in resistor! If you want to use this with a higher voltage, say 12V or 24V, simply add a 470 ohm resistor in series with the LED connection to keep the LED current at around 20mA.