Circuit to create X levels of brightness for a LED

Source followers will not turn on completely so your circuit isn't great. If you want to ground the LEDs, you can use P-channel MOSFETs rated for 3V or lower drive, keeping in mind that the control signals will be inverted (low=on). Or you can connect the LEDs to +3.3 and use N-channel MOSFETs with the sources grounded.

Also, your paralleling of the LEDs is not the best. Assuming they are all very similar it can work okay, but it's better to give each LED its own ballast resistor otherwise slight differences in the forward voltages (they usually have a fairly wide range) will result in one LED hogging more current than its share.

The lowest value you have is 20 ohms so you could put ~60 ohms in series with each LED and then use 0 ohms/80 ohms/230 ohms for the other two resistors. For visual indicator or backlight LEDs the resistor values are not that critical and you can adjust them to convenient values by experimentation to get the visual effect you want, the key thing is that R1~R3 are equal, and they set the maximum brightness. The other two resistors add to R1||R2||R3, so you get the same effect as with 20R/100R/250R running the parallel set, or individual series resistors of 60/300/750 ohms on each LED.

schematic

simulate this circuit – Schematic created using CircuitLab


If you can increase the voltage of your power source you could use a circuit like

schematic

simulate this circuit – Schematic created using CircuitLab

As others have said, by turning on more than one mosfet you can have up to 5 levels of brightness (8 if you add a suitable resistor before \$M_1\$).

Tags:

Brightness

Led