Basic LED fading question

Discussion in 'General Electronics Chat' started by DanRilley, Mar 29, 2010.

  1. DanRilley

    Thread Starter Senior Member

    Jan 13, 2008
    107
    0
    Hi hopefully this is a simple question.

    I'm trying to get an LED to fade on when I flip a switch on, and fade off when I flip the switch off. I can currently make it fade off using the schematic below, but I can't seem to figure out the fading on. I assume its some other kind of capacitor resistor combination but couldn't figure it out.

    [​IMG]

    Thanks,
    Dan
     
  2. teravenous

    New Member

    Mar 29, 2010
    8
    0
    I couldn't understand your question . You want that when you flip switch on, led become on; when you flip switch off, led become off ? Or you want that when flip switch on, led become on; when you flip switch off, led become off after a few seconds ?
     
  3. retched

    AAC Fanatic!

    Dec 5, 2009
    5,201
    312
    Turn Switch ON
    -- LED FADES from OFF to BRIGHT
    Turn Switch OFF
    -- LED FADES from BRIGHT to OFF

    With a incandescent bulb, this would be easier than with an LED.

    With an LED you have to reach a certain forward voltage before it turns "on". So the fade in will be more difficult than just the cap-resistor.

    To dim LED's you blink them VERY fast in a process called PWM. Pulse Wave Modulation.

    By changing the on - off times, or duty-cycle, you can change the brightness.

    With your fade out, It is easier because the inital "arc" has been established and you are dropping the voltage until it can no longer be established.

    But with fade-in, You will increase the voltage with no light at all untill the forward-voltage is reached. then it will "flash" on. After the initial 'ON' you can play with brightness by varying capacitance and resistance.

    Getting that smooth black to bright fade-in is a little more involved.
     
  4. llawwehttam

    New Member

    Mar 29, 2010
    10
    0
    I want to do somthing similar but fade a bulb slowly over 10 minutes.
    My thread is HERE

    I'm just not sure how to slowly increase resistance automatically.
    I would normally do this with a PIC but I can use one for my project.
     
  5. Mike33

    AAC Fanatic!

    Feb 4, 2005
    349
    25
    Would probably have to use PWM...
     
  6. Wendy

    Moderator

    Mar 24, 2008
    20,765
    2,535
    You'll probably need a transistor to amplify the capacitance. Something like this...

    [​IMG]

    3.3V is a bit low for this idea, some LEDs won't even light up with that voltage. PWM would also work (as suggested) but would require a lot more circuitry. It could use 3.3V though.

    I'm assuming the LED is red. You could extend the duration by adding a transistor and making a darlington, but that would definitely require more power supply voltage.
     
    Last edited: Mar 29, 2010
  7. santonel

    New Member

    Feb 28, 2010
    6
    0
    Here's what I got just fiddling around with a simulator. You can adjust the speed of the fade by the size of the cap , resitor and/or inductor.
     
Loading...