mod: continuous brightness adjustment via sliding switch

I have been more interested in optimizing the user interfaces of my flashlights. Ramping FW like Narsil and from Toykeeper have the features I want and are intuitive to use. Maybe an even more intuitive UI is a sliding switch controlling the brightness from off to full. The way I chose to implement this was to continuously vary the gate voltage to a MOSFET via a voltage divider with a sliding variable resistor.

The light I put it on is my 7xXPL modded Convoy L2. I had previously drilled a small hole to the driver cavity to use an e-switch, and I used this hole to route the wires to the variable resistor outside the light. The variable resistor I used was this 10Kohm one. The MOSFET was the Vishay one from mtnelectronics.

This method really simplifies the system. There is no MCU or firmware, just a MOSFET and two resistors. The biggest challenge with implementing this is dealing with the heat dissipated by the MOSFET, which is up to 10W in this particular light. Below is a graph, for this particular light, of the power, in watts, the MOSFET must dissipate as a function of current, in amps. Basically it is the voltage the FET must “burn off” multiplied by the current. The heat the FET must dissipate is small at low and full power and maximum at half power.

The main heat dissipating contact of the FETs we typically use is that of the drain which is connected to the LED negative, so it must be kept electrically insulated from the flashlight body. At first I tried mounting the top of the FET to the bottom of the shelf using thermal paste and some epoxy, as shown below. I knew this was not optimal but I hoped it would be good enough. It wasn’t; the drain solder point desoldered within a few seconds at half power (which corresponds to max FET heat dissipation).

Next I used a 16mm MCPCB. I sanded the top down to reveal some copper and soldered the FET drain to the copper. The source and gate contacts were left overhanging. The plan was to attach the MCPCB to the bottom of the shelf. The shelf bottom in the L2 had a raised part in the middle so I sanded that down until it was acceptably flat. To electrically isolate the MCPCB from the flashlight body I used a layer of Kapton tape. This tape material has a thermal conductivity of 0.12 W/m*K and is 1-2 mils thick. Over the area of the 16mm MCPCB one layer of tape adds only 1-2 K/W of thermal resistance. I attached the MCPCB with thermal paste and some epoxy around the perimeter and clamped it down while the epoxy cured.



Judging by how hard it was to get the solder up to temperature to solder the LED negative wire, the thermal path is pretty good. The sliding switch is secured to the light with epoxy. The variable resistor goes from 0 to 10Kohms, and I chose 22Kohm for the other resistor in the divider. So the gate voltage can be adjusted from 0V to ~8V(10/32)=2.5V. The conductance changes quite quickly within a small voltage range, so only about the middle third of the resistor travel significantly adjusts the output.


A benefit of using constant current is that it is more efficient at producing light. Below is a graph of the approximate output (measured by ceiling bounce test) versus the current at the tailcap for the PWMing a FET and constant current through the FET. To measure the current I measured the voltage across a shunt resistor of 10mOhms. The cell voltage in each case was about 4.05V. There is not a huge difference in output between the two methods in this case, partly because the pulsed current is not that high, between 3 and 4A per LED. Higher pulsed currents lead to less efficiency.

Thanks for looking!

This is a great prototype mod. Nice & simple concept.

Could you have used a less-expensive host though!! :wink:

I was shocked by the picture, but then i realised you’re working through the side switch hole. :smiley:

You could do this with a bunch of CN5611 maybe, then you’ll have adjustable constant current, but unfortunately also more voltage drop…

Cool! Are you going to optimize resistor choice so you can utilize the full slider range?

I think I will. I will need to add a resistor between the slider and ground to get rid of some of the space at the bottom. Based on some measurements of where in the slider range the output changes I want the slider range to approximately correspond to the range 0.6V to 2V gate voltage. I’ll need to take into account the lower cell voltage at lower states of charge when I choose the resistor values.

When I saw this i thought myself why not try to solder the FET directly on one of your stars on the negative side

A 20mm LED MCPCB should have enough space to easily solder the FET on it and its insulated to the body

there are also different types of sliders with logarythmic, linear or custom resistance

Good idea. The thermal path would probably not be as good as my current solution, but would be fine for less powerful lights. It might simplify installation in some lights.

playing with two diving lights with a magnetic slider
muggles love that way of operation
nice mod, creative!

Is there more energy efficient method than using MOSFET? Spending up to 10W (if I understood correctly) on MOSFET seems a bit too much :slight_smile:

The MOSFETS we use have below 10mOhms resistance
there is not that much heat generated in them it knows only 2 states on and off

If you use also 7135 chips they generate a lot of heat as they regulate the current acting as linear driver

Then I don’t think you have actually read the OP. The MOSFET here is used for on, off and everything in between.

Yep, I’m using the MOSFET basically as a linear regulator, so significant heat is generated.

Yes, you understood correctly. 10W is a lot, but the efficiency isn’t so bad when you consider the total power at that level, which is ~50W.

There are basically 3 methods we use to control the brightness: linear (like this mod), PWM (like a traditional FET driver), and voltage conversion via switching (e.g. buck or boost driver). Ideally a buck or boost driver is most efficient, but in practice they can be 80-95% efficient, and high power examples are not readily available for our lights. Comparing linear and PWM is interesting. One might think at first that PWM could be more efficient since the driver does not dissipate heat like the linear method, but it turns out the power consumption is the same for both methods. The PWM driver doesn’t dissipate heat, but extra power is dissipated in the circuit resistances and the LED itself. See here for some analysis I did recently.