Connect with us

Lights activted by reed switch

Discussion in 'LEDs and Optoelectronics' started by iamjacob, Jul 30, 2013.

Scroll to continue with content
  1. iamjacob

    iamjacob

    6
    0
    Jul 30, 2013
    Hello all.

    I'm looking for some assistance with a circuit for a reed switch driven light switch. Let me start off by saying that I'm brand new to designing electronics so go easy on me.

    I'm in the process of making a lighted jewelry cabinet for my wife and I want the lights to be controlled by a reed switch inside the door of the cabinet. Open the door and the lights come on, close the door and they shut off, like a refrigerator .

    My idea is to have a N/O reed switch that controls an SPDT relay where the N/C side of the relay is connected to an LED strip that lights the cabinet. See crude diagram below....

    Now here's my 2

    1. Is there anything I need to add between the input side of the reed switch and the power source to keep it from burning up?

    2. How do I know what relay specs I need? I am somewhat worried that if I get too big of a relay the limited current through the reed switch won't trigger the relay. I was hoping to use a solid state relay so that I don't hear a click when the cabinet door opens.

    Sorry if the diagram below is way off.

    [​IMG]



    Reed Switch - http://www.clrwtr.com/PDF/GE-Securit...x-Contacts.pdf

    LED Strip - http://www.ebay.com/itm/New-Cool-Whi...E:L:OC:US:3160

    Wall Wart - Came with the LED Strip

    Relay - ??? I'm open to suggestions...

    Anything else I need ???

    Thanks a ton in advance.

    Jake
     
  2. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,496
    2,837
    Jan 21, 2010
    I think you'll find that the reed switch is open when the door is open and closed when the magnet is near it.

    If that's the case your circuit will work exactly correctly, the lights will be on when the doors are open. (if not, it will be backward).

    I'm assuming that the LED strip is designed to be connected directly to 12V, and not to some constant current source. If the strip has inbuilt resistors then this should be the case.

    The one issue is that the relay is continuously energized and that's not elegant.

    Although it will only use a small amount of power it may well add up to more than that used by the LED strip over time.

    You could fix that with a transistor, a resistor and a diode to make a circuit that works around the other way, OR you could switch the relay using a microswitch or similar that is actuated by the closing door.
     
  3. duke37

    duke37

    5,364
    771
    Jan 9, 2011
    You must have the led polarity correct. You are feeding the circuit with the neg power supply output. With the led arrow pointing down, you need positive at the top.

    A transistor to invert the signal, taking very little current, could drive a mosfet to switch the leds. This would replace the relay and put the light on when the door is open.
     
  4. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,271
    Nov 28, 2011
    Reed switches are available with normally closed contacts and changeover contacts. If you use one of these, you don't need a relay or any other circuitry; just connect the normally closed contact in series with the LED strip. This one is rated to switch 500 mA - make sure your LED strip doesn't draw more than that. http://www.digikey.com/product-detail/en/KSK-1C90U-1015/374-1148-ND/2765263
     
  5. davenn

    davenn Moderator

    13,833
    1,950
    Sep 5, 2009
    kris

    thats what I initially though too till I saw that the circuit is showing that the LED strip to be used is drawing ~ 3 Amps


    Dave
     
  6. iamjacob

    iamjacob

    6
    0
    Jul 30, 2013
    Thanks for all the ideas guys.

    Dave, I'm not 100% sure that the led strip will pull 3Amps but the info on the strip says 1.2Amps per meter and I think I'm going to be using about 7-8 ft of it.

    Kris, That's the route I was going to go but I couldn't find a reed switch that seemed like it would work.

    Duke, sorry for the bad drawing, I was pretty much guessing about what went where and which symbols to use.




    Steve, is there any chance you could draw out how the transistor and diode would need to go in order to switch the relay around? Would that also make it so that I can use a spst relay instead?
     
  7. duke37

    duke37

    5,364
    771
    Jan 9, 2011
    Would this do?

    A suitable fet could take several amps.
     

    Attached Files:

  8. iamjacob

    iamjacob

    6
    0
    Jul 30, 2013
    Sorry if I'm a little slow.

    So in the diagram, the transistor replaces the relay and the 100k resistor limits the current through the reed switch so it doesn't burn up?...

    I would need a 100K resistor and a transistor that can handle the 3Amps that the LED strip is going to draw. Right?
     
  9. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,496
    2,837
    Jan 21, 2010
    Duke37: Yeah, that would work, however I'd probably place a 10V zener between the gate and source. Without this the gate is subject to any spikes that may appear on the 12V rail.

    Oh, and well spotted about the voltage source.

    Alternately, if a reed relay with changeover contacts (or contacts that are open when the magnet is near them) is used, then it can be used to turn ON the relay when the door is opened.

    edit: iamjacob, the 100k resistor turns the mosfet on (it required very little current to do this). The red relay holds the mosfet off when the door is closed. The resistor only has 0.1mA flowing through it. I would probably decrease the resistor value to 4.7k just to ensure the mosfet turns on a little more quickly. Either way, the resistor needs only be 1/4W or higher -- probably a couple of cents :) The 3A goes through the mosfet. A mosfet (in this circuit) is like a relay that requires almost no current to operate.

    For your information, the top contact is the drain, the bottom is the source, and the one connected to the resistor and the reed relay is the gate. You should look for a device capable of carrying between 5A and 10A in a TO-220 package. (we can help you with this). You also need to know that these devices are static sensitive.
     
    Last edited: Jul 31, 2013
  10. iamjacob

    iamjacob

    6
    0
    Jul 30, 2013
    Is that on the bottom right or the left side of the transistor?

    Thanks for the heads up, that's just the direction the tool had the icon.


    I couldn't find an appropriate reed switch in form b or form c for what I was looking for.
     
  11. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,496
    2,837
    Jan 21, 2010
    The zener goes between the source (the bottom connection) and the gate (the one on the left). Essentially it goes across the reed switch, but I'd solder it as close as possible to the mosfet.

    The cathode end (the end with a band) goes to the gate.

    Also see edits in my post above.
     
  12. iamjacob

    iamjacob

    6
    0
    Jul 30, 2013
    Steve,

    I can't say thank you enough. I have spent the last 3 hours researching mosfets and I don't feel any smarter than I did yesterday.

    I found this mosfet but I have no idea if it is something that would work...

    https://www.jameco.com/webapp/wcs/s...01&langId=-1&catalogId=10001&productId=812236

    The diode and the resistor pretty straight forward but the mosfet completely escapes me. Is there any chance you can recommend a mosfet that will fit the bill?
     
  13. duke37

    duke37

    5,364
    771
    Jan 9, 2011
    Mosfet
    I would use a IRF540 since I have some. This has a resistance of less than 0.1 ohm when turned on properly. Power dissipation = I * I * R = 3 * 3 * 0.1 = less than 1W so it should be possible to run without a heat sink.

    There are many N channel mosfets which could be used, look for low Rds. There are lots of cheap ones in TO220 package. The STP16NF06 is adequate.

    Check that the fet does not get too hot (finger test). If it does, you could put two in parallel or add a heat sink.
     
  14. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,271
    Nov 28, 2011
    If you want to buy from Jameco I'd suggest the Fairchild FQP50N06, Jameco catalogue number 785590. It's in a TO-220 package so it's easy to work with, it seems to be ex stock and it's only USD 0.99.

    It's rated for 50A which seems like a huge overkill, but it's pretty cheap, and you're only making one of these things. You might want to get one or two more, for future applications. It has a reasonably low Rds(on) of 22 milliohms. Assuming your LED strip draws 3A, it will drop 0.066 volts (about 0.5% of your total voltage) and dissipate about 0.2 watts, so it will only get slightly warm and won't need any heatsinking.

    Duke's design in post #7 is good. You should add a 12V 0.5W zener diode between the gate and source, as previously suggested. Jameco part number 179098.

    The value of the pullup resistor will determine the circuit's OFF-state current. You can calculate this using Ohm's Law: I = V / R, where I is the OFF-state current, in amps; V is the supply voltage, in volts, and R is the resistor value. A higher value will give a lower current, so your battery will last longer, but it will slow down the turn-on of the MOSFET slightly, which will cause a short burst of high power dissipation at the moment the LEDs turn ON. I don't expect that would be a problem, but I would go for something between 4.7k and 100k, depending on your battery capacity and expected lifetime.
     
  15. iamjacob

    iamjacob

    6
    0
    Jul 30, 2013
    Kris,

    Thank you for the part numbers! I don't need to buy from Jameco, they just had the easiest sort function for trying to dig through the parts. Is there a recommended parts place?

    This circuit isn't going to be operated via a battery, it is going to be plugged into the wall. I'm guessing that would mean it would be safe to use a resistor on the smaller side causing the mosfet to turn on faster.

    I'll probably get a couple different resistors and see how much of a difference there is.


    Thank you all for all of the help!
     
  16. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,271
    Nov 28, 2011
    I usually give links to components on the Digikey web site, http://www.digikey.com, unless I know the person is in England, in which case Element 14 is the normal mail order supplier. There's also Mouser in the U.S.A.

    Digikey have a very wide selection, and their parametric seach is probably the best, although it still isn't ideal.

    The Electronics Point profile has a field for your location, and it's a good idea to fill that in, since it tells us things like your mains voltage and frequency, and which supplier we should link to.

    If the circuit won't be battery-powered, I would just go with a 4k7 resistor.
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-