D.I.Y. Illuminated tailcap

Mm in my experience the 560 bleeder does fine all the way up close to 0.75ma draw in the tail before the driver starts acting weird. I expect it to still be fine with Rev6, but I guess we’ll find out in a couple weeks

I apologize if this has been suggested already. Has anybody considered putting one of these dual LEDs in the tail?

The green has a Vf of 3.3 and the red has a Vf of 1.95. Wouldn’t this work as a “dumb” battery level indicator?

I found a few green LEDs with a higher Vf but they were more expensive. My thought was that multiple greens that fall off at various voltages would allow the light to shift away from green, to yellow (green+red), to red.

EDIT: If we could find an appropriate LED where the lowest Vf is around 2.8 wouldn’t that be ideal? That way when the LED goes out the battery is depleted and won’t discharge any further.

It’d be great, but frankly, it doesn’t seem to work that way in my testing. I’ve used these led’s which have a rated Vf of 3.0-3.2v, and even with a limiting resistor in series, they are still giving off a little light at ~2.5v input. Eventually that would stop, but the listed Vf’s are usually at normal operating currents, not a strict cut off voltage.

At which voltage a certain colour led drops out I found also highly dependent on battery type. Not that I can explain why...

OK, so the consensus seems to be that using the LED Vf to prevent over-discharge probably won’t work. What are your thoughts on the dual LED that should shift its combined color spectrum as the voltage falls?

I think Djozz actually tried to jerry-rig something like that. Djozz?

IIRC, the dual-LED color-shift thing worked sometimes… but it was awfully sensitive to the wrong things — didn’t work the same on multiple units (or even one unit with different cells), and still didn’t really cut out at the desired voltages. But you can do it if you’re willing to fiddle with it a lot.

That’s much of why I’m hoping the smart version of the tail board will pan out. It can be more more responsive, consistent, and explicit about the cell status. And, if desired, even animated.

Plus, I want colorful shiny things to play with.

Basically the BLF motto

I can’t wait to see first results of the smart tailcap.

TK, I had a look at your firmware, but due to my lack of knowledge I have trouble understanding what it does… But I think I understand enough to say it’s cool. May I ask some questions?

That colorful swirl… it does it on every boot. So would it start blinking on every short press?

When is the MCU sent to sleep? If watchdog wakes it up every x seconds, basically all the functions like ADC (and that other stuff on page 32 in the t13A datasheet) could be turned off and the port pins can be set to inputs before going to sleep for power reduction, right?

I think we would need a firmware for calibration, right? Could we just use battcheck for that, or would we need something different here?

Has anyone tried adding a diode in series with the LED to increase the total Vf? that might make the drop off with battery voltage steeper.

It was tried pretty early on, Rev1 of my boards I think. It didn’t appear to anything different than having a higher resistor in series.

You’re always welcome to give it a shot though, maybe I missed something

At some point I’m going to have to start doing some board design, I’ve stacked SMD parts off pads and air wired before but 0805 parts are tiny.

Hey TK just had a look at your tail cap firmware looks pretty concise already. Should make for an interesting new tail cap version

Yes it works sometimes, and as ToyKeeper pointed out, is very sensitive to about everything, especially the battery type. So for each combination of battery and driver you will have to figure the values out. Thusfar it never worked for 18650 batteries: I tried the same blue/red tail-board that worked well enough on a 16340 flashlight (blue fades away between 3.7V and 3.8V with red still bright) on a BLF-A6 and the blue led stayed lit brightly until the low voltage protection (2.8V?) kicked in.

Also a zener diode did not shift the voltage at which the leds started dimming: at these very low currents things appear to work different.

My current EDC (Supfire S1 host, 3-mode FET-modded AK-47 driver, sliced Nichia 219C):

16340 IMR battery, red 603 tail-led with some resistor (forgot) + dedomed XM-L2 (6A1 80CRI ) tail-led without resistor, 680 Ohm bleeder resistor on the driver. With a full battery the white led is clearly brighter than the red led, once the two leds appear the same brightness to me, the battery is half empty, between 3,6V and 3.7V, the white led fades further when the voltage is getting lower than that.

Do we need to set up a simple constant current circuit so they stay the same brightness. Would it then cut of at a specific voltage?

As is, it should spin on every button tap. I don’t know if this will be annoying.

The MCU goes to sleep after it completes a voltage readout, then stays asleep until the watchdog wakes it up. There are probably ways to reduce the power more than I did, but I consider that an optimization for later. Those steps would be added to go_to_sleep(), and the driver could be put back into a more normal state in the WDT handler.

This definitely needs to be calibrated before I expect it to work. Battcheck should be fine.

I’m guessing about a lot of things because there’s no actual hardware to test on yet. I just used something vaguely similar in hopes it’ll be close enough. And I intentionally left it pretty simple… it can get fancier later if desired, if the hardware works.

Once it’s shown as working, just throwing in a delay should remove the spin on every tap, no? Just select a delay which is longer than a medium press.

Anyone order the smart tailcap board and planing to test it out?

Nope, just ordered the dumb 6-led board.

I can not program, I can not flash. I do like to see it happen though, and oh, can it made to play music too? And project the voltage? (aspheric tailcap!) :-) ;-)

I have seen cheap little novelty clocks project the time! :smiley: I think I disassembled one many years ago and iirc it projected thru a tiny LCD (digits clear, background dark).

For the music, would a limited range midi tune be ok or do we need full range mp3s? :party:

I ordered some