How To Build a Flashlight With Perfect Modes (picture heavy)

Another screenshot:

Thank's Tido, Will this burn any fuses or can I program the device otherwise afterwards?

In fact I'm more interrested in making a light with fixed modes at my own levels but will try your example first if it is not destructive.

As long as you don't set any lock bits and don't disable serial programming, the chip can be reprogrammed a few thousand times. Just make sure you get the fuses right (that's what '-Ulfuse:w:0x79:m -Uhfuse:w:0xef:m' does).

Done!

So now I have a monster-driver 2.8A (8x7135) with variable setting. Exiting. But what about 1020 bytes instead of 1024 bytes?

I would want to test it without undoing my elaborate soldering work. (must try to repair that clip).

Thank's again, Tido,

I hope that brted also will be successfull.

Nothing to worry about. I just created the example output from a current development version, not the flash image in the published archive.

I got the clip. It's true not the greatest build quality, but it's pretty standard "pomona soic clip 5250" sold at digikey, etc. If any of the pins are short, you can push them out from inside the clip near the hinge.

My problem is that DX won't ship out the drivers. I should probably order some at KD.

Hi All

This is my first post in the forum, and I just want to thank Tido for his work on the flashlight driver.

Using the soic clip listed in this thread and an arduino board as a very cheap avr programmer, I have now reprogrammed my BLF AA-Y4E to have exactly the modes I like.

It has also been great fun to play around with the driver software "inventing" highly unusable modes :-)

Regards

Nicolai

Welcome nkildal. Good to have you here!

It's encouraging to hear people are having some success with this. I'll tinker around with mine some more this weekend and see if I can get it working. Nice that it works with the BLF AA Y4E, Nicolai! I always wonder how many people like you are lurking here, reading the threads, buying stuff, and yet we never know. Glad you've shown yourself.

brted - I found the following things a bit challenging:

1. My clip was of bad quality - some of the pins were pulled back a bit, making it hard to make proper contact with the pins of the chip

2. The right wires need to be connected from the AVR programmer to the connector of the soic clip. Your post with the images and tables helped me do that - thanks brted

3. Using Mac/OSX I had to download and set up a compiler environment (I chose CrossPack-AVR, http://www.obdev.at/products/crosspack/index.html) - this was easy :-)

4. Lastly I had to use the correct avrdude command line to program the chip. Tido and sixty545's comments above in this thread, helped enourmously - thanks guys.

None of the above are real showstoppers - I just had to take it easy and be careful - so good luck when you get to the tinkering :-)

Also a warm welcome from me, Nicolai!

I have an easy question for you, right away:

Does the BLF AA-Y4E have an ATtiny13 or did you put in a new driver?

Hi there

The BLF AA-Y4E uses a driver with an ATtiny13 - so it was very easy to open it up and just reprogram it.

It has very short wires from the driver to the LED, so I had to unsolder wires to get the driver out.

I have sinced replaced the wires with longer ones, so I now only need to loosen the driver board from the pill to program it.

I didn't originally plan to mess with my BLF AA-Y4E, but I had been waiting for too long, for DX to send me some AK-47's to play with :-)

Thanks for giving the BLF-VLD a try, sixty545 and nkildal. I'm very happy that finally someone else can test out my driver. It would be great if you guys could give me some feedback on the mode programming UI. I've got a new version with some new features ready, but I'm reluctant to push out a new release unless I know I won't have to rewrite the whole UI.

nkilda, have you tried using a PWM level of 1/255? I'd really like to know if the boost circuit stabilizes at such low PWM rates and if it's still running efficiently. Could you measure the current drawn from the battery?

Hi Tido

Yes - I have tried 1/255 and it seems very stable and usable (I like an ultra low low).

When using two different 14500 Li-ion cells I measure the following current at the tailcap, but please keep in mind, that my multimeter is a cheap one, so the PWM probably fools it:

DX Trustfire "Blue", sku 19626 @ 4.14V: 0.52A

DX Trustfire "Flame", sku 26124 @ 3.75V: 0.58A

I wanted to take a reading with a NiMH cell, but I just discovered, that the light does not come on at all, with any of my NiMH cells (even fully charged ones)...

I use the BLF-VLD with only 5 modes and no memory ( 255/255 -> 32/255 -> 1/255 -> Strobe -> "Soft Beacon").

Can you think of a possible explanation for the light not turning on with NiMH ?

The same here. I am waiting for 4 pc. of 101-AK from DX ordered nov.6 -shipped nov.25!

So I have now programmed a SKU: S009742 from Kaidomain ordered nov.8 arrived nov.22.

I just don't own an emitter (yet) that runs on 2.8 A. The XM-L plug-in is to expensive for me - I fear it should be caught by the P.O.

(I would really like to test that emitter) .

Actually, I bought that driver to harvest the 7135's for bringing the 101-AK's to do 1.4A, but now I will keep it for the future XM-L

I got my 8-pin clip to work after 1 hour of surgery and will now sacrifice the BLF for a better life, hopefully.

The ATtiny needs at least 1.8V to work.

Ahh - the good old P.O. - here we have a limit of around 15$ - above this value you get an additional 30$ in handling fee plus 25% VAT :-)

The BLF AA-Y4E worked fine with NiMH before I re-programmed it, so there must be another explanation I think ?

Oh, I smell Denmark here. Welcome, fellow countryman.

I think that the $ has risen so the limit is only $14 now

At least we are in the same "boat".

The NiMH matter could be an issue for Tido, perhaps initialization is wrong. Or there should be some form of charge pump to bring the voltage up.

Yes. Actually, that is exactly what I dreaded. When using Li-Ion, the driver is most likely in direct drive and not boosting. On NiMH it needs to boost, but the "on" periods are probably too short to allow the boosting circuitry to start up. Have you tried if it works with higher PWM levels?

Also, could you post a picture of the PCB's component side? Maybe there is no special driver chip and the ATtiny was used to switch the coil. In that case you're screwed when it comes to using NiMHs.

Nice - thank you - and "godaften til dig også" (sorry non-Danish forum members)...
The SKU S009742 from KaiDomain looks interesting - especially with the new XM-L arriving. I'd better place an order :-)

I could try make the BLF start in the lowest mode, and see if it will run with NiMH's again.

Btw: what is the PWM frequency when running the BLF-VLD firmware - I am very impressed with the flickerfree operation: I see no flicker whatsoever even in the lowest (1/255) mode