I am controlling a fade up/dn of some short (2" to 8") lengths of 12V UV LED tape with a Nano and a MOSFET module. Everything works just fine, but the designer I am working with does not like the way the tape "pops" on when fading up from 0% to the dimmest point. He would like to see it fade up in much the same way that incandescent lamps do. Yes, I know I'm limited to 8 bit values for controlling the fade. Is the popping on an issue related to the MOSFET or the tape? Any suggestions on how I can make this fade happen smoothly?
Thanks for your time!
Try @septillion's 'FadeLed' library - find it in the IDE library manager.
-
Can you make a YouTube video for us to see what’s happening.
-
Always show us a good schematic of your proposed circuit.
Show us good images of your ‘actual’ wiring. -
Are you using a Logic Level MOSFET ?

Nether, it is an issue with the software. The problem is that light increases in a linear fashion with an increase in the PWM value. Where as your eye has a logarithmic response to light.
There is a solution to your problem and that is to apply "Gamma Correction" to how the values are sent to the strip (not tape, it is called an LED strip).
Read this first, Gamma Correction
Then search the net to find examples of how to use it like this
Adafruit led tricks Gamma Correction
Gamma correction can fix the smoothness of dimming, but not the crude step between PWM level 0 and level 1. You can only make the first step smaller by using higher bit-depth PWM. I use 12-bit PWM for my lighting with a PCA9685 chip.
Maybe your secret Arduino can produce higher bit-depth PWM with code.
Leo..
You are not the first one having issues with commonly available mosfet modules and PWM.
You could try to reduce the frequency and see if it behaves better.
It can by making a lot of the steps at the beginning zero. Also if you follow those links on the Adafruit page you can get links to other techniques like dithering to reduce the impact of those large initial values.
How do you know this?
Doesn't the Nano use a AT328P? If so why not use the 16 bit timer with PWM capabilities?
Explain what you mean, at what duty cycle, as you adjust it from 0 to 100%, does the LED begin to glow?
If you don't know, put some serial print statement in you code to help you find out.
Please post your code?
Can you please post a copy of your circuit, a picture of a hand drawn circuit in jpg, png?
Hand drawn and photographed is perfectly acceptable.
Please include ALL hardware, power supplies, component names and pin labels.
Tom....
![]()
The downside of 16-bit PWM is the lower PWM frequency.
That can give weird strobing effects when used for main lighting.
Leo..