Anyone in the Santa Barbara CA area able to help me flash my D4?

Victory. removing my D4 driver was not too bad, this post , and these pictures really helped. I could “see” where to press on the board not on a component, especially the picture of the three drivers. I say “see”, as you (at least I) can not see through the hole to a spot on the board where there are not components. But with a skewer, a bit of offset to avoid R5 and his buddies (thanks to the pictures), and a couple taps with my D4 body (host?) and the driver came loose. I am using the cheap clip for programming, and I did have to fiddle a bit with the pins and how they extend through the clip body a bit. Once I got them all extended properly, the light programmed right up. I am SOOOO glad I had a demo board with a ATTiny85 on it to verify my setup (multiple times) during the process. The demo board was much easier to program, not sure why but it all worked out in the end. :smiley:

Special thanks to goshdoggit for all the tips and TK for the awesome firmware (but it really is software is it not?).

[quote=sbslider]

It is “soft” for you……… now! :crown:

That’s great news! Congrats on your successful reflash. :+1:

so I am trying to flash another D4, and the computer I used last time has a dead hard drive. I can’t for the life of me figure out where to find the anduril.hex file again. Help?

Never mind, I found it. used the 2018-01-24.hex file. :smiley:

Rats, now I see I broke a resistor ( thinking R5, the one in the center) when i pushed the board out. What value is that? Maybe a small leaded part can fit back in there.

don’t use that nasty old hex…get the latest one:

http://toykeeper.net/torches/fsm/

awesome, update done. BTW, what is the difference between this one and the one from say May or so? Oh, nevermind, I see there are lots of updates in the old file. I am just wondering what’s been fixed since then.

Now, I still need to fix R5.

Anyone know the value? I am guessing 1k or 10k would work, but if someone knows, all the better. Better yet, maybe just a jumper?

some clicky bugs

Toykeeper:

thanks!

On a sort of related note, I just finished doing some investigation on the D4 driver with an ohm meter. It appears R5 is in series between the battery and a large cap (C2), then a diode and a smaller cap (C1) bring power to the ATTiny85. Guessing something like 5 ohms would be good in here, a short would likely work fine also. R5 limits to some extent the current into the C2 when the battery gets connected. Not sure what other purpose it has, but too big would mess up the voltage readings I suspect.

The resistor next to it (R4) is marked and measures 47 ohms, so it’s ok. The C2 looks fine also, so just removing the old leads from R5 and installing a new component should get this up and running. Definitely a job for under the microscope at work. Some old leaded resistors I have a home look like they fit in the space between the driver board and the shelf (?) that the MCPCB mounts to on the other side.

R5 value?

Here’s a pic of my D1 driver, but you’ll need to stand on your head to read R5’s label. :smiley:

BTW, I popped one of my D4 drivers loose and had barely enough room to pry it sideways to verify that R5 is the same on the D1 and D4. It is. :+1:

Perfect, just as I suspected, R5 is 4.7 ohms (ok, I said 5 ohms . . .). I found a 3.3 ohm resistor at home this afternoon. I would prefer a chip if I can find one, but I’ll likely fool around with the leaded one tonight to see if I can get it to fit.

Thanks! :beer:

So I have replaced R5 and still don’t have a driver that works. I had reflashed the driver a few weeks ago, and it reported going well. When I put the light back together, no light. I am making voltage measurements on the driver board.

MCU has voltage on pin 8, I see pin 2 go from about 0.8V to ground when the switch is pressed, I see pin 3 go from around 0.6V to Vcc when the switch is pressed, pin 5 does nothing when the switch is pressed, nor does pin 6. Pin 5 should drive the 7135 and start high after the switch is pressed and released, as that would fully turn on the 7135. Pin 6 is a bit dicey to probe so I did not try much there, as pin 5 is not working either.

Wondering if I should reflash? I recall using the file http://toykeeper.net/torches/fsm/anduril.2018-09-07.EMISAR_D1.hex
with the command
avrdude -p t85 -c usbasp -Uflash:w:ANDURIL.2018-09-07.EMISAR_D1.hex:a -Ulfuse:w:0xe2:m -Uhfuse:w:0xde:m -Uefuse:w:0xff:m

Or at least that’s what I think. Try again maybe?

Next issue with this driver ( and my test ATTiny85 is that I can not connect with the chip. I am able to measure continuity from the IC pins through the clip, so I don’t beleive it is a bad clip. If somehow I “bricked” the chip would it just stop responding when I try to communicate with it using the command avrdude -p t85 -c usbasp -n

It’s probably bricked. I bricked my q8 and the chip wouldnt respond after with that command. Kept saying failure to connect. I used wrong fuse values.

Yeah, that is what I imagined, but best I can tell I used identical fuse values as when I flashed the first driver I have. I thought the fuses were device specific, not load specific, perhaps I am wrong? If so, where do I find the right fuses for the latest Anduril load?

https://bazaar.launchpad.net/~toykeeper/flashlight-firmware/trunk/view/head:/bin/flash-85.sh

yep, that is very different than what I used. still confused why it worked with an older Anduril load. Time for a new chip or driver board . . .

BTW, thanks for the quick responses all :+1:

Where did you get the other fuse values from? Is there documentation somewhere leading people to the wrong answers?

” post 5 above”:Anyone in the Santa Barbara CA area able to help me flash my D4? - #5 by goshdogit

Oh no! It appears I pasted the ‘BOD disabled’ fuse values specified in the flash-85.sh script.

The difference is just one digit in the ‘hfuse’ value, but I really hope my error isn’t the cause of your trouble.

TK, would this difference cause such an issue? Should I edit my post?