Oh damnit, that sux how can I verify this for sure? I don’t want to just keep ordering programmers if I don’t know that’s the problem. I assume that when I plug it in it should just turn green? or with the software running it should turn green? Or how dose this go?
I don't think the LED is an indicator that it's working - mine is ALWAYS red regardless of whether it works or not. I might be wrong, but I just bought a couple from all different vendors until I got one that worked...so I went and bought 2 more from them just in case.
Again - the fasttech programmer has worked for me and everyone else who has bought them.
any way I can tell if mine is bad or if I just haven’t got a clue about using the software? Any guides for using the software but as a modified 8 pin output programmer (dose this even make a diff to the software?)? Any by ‘guide’ I mean the most ‘for dummies’ type of guide possible (I don’t yet know how to program, so I’ll be learning on this : )
http://flashlightwiki.com/AVR_Drivers
Example commands there for avrdude you can simply paste into a command prompt to see if it works.
The light on the programmer is always red anytime it's plugged in.
Or you can use extreme burner avr (on the link abobe), it works fine for reading and erasing, not for writing (and then you have to use avrdude).
You will see easily if it’s correctly connected if it can read the attiny13a. On a protected chip you will have continuous bytes and the lock byte will be set to 0xFC.
Is that the 'right' value to use to lock one? I tried searching and reading general AVR stuff to find out how to do it and got (as usual, since I don't know enough about it to weed out what's relevant from what's not) conflicting info. I tested with 0xC0 and got scrambled data when I tried extracting it, so it works, just don't know if that's the right way to do it with the stuff we use.
Ok, having installed extreme burner it looks like a good starting place to see wth I’m doing
I says ‘No supported programmer found’, dose this mean I need to use one of the drivers I’ve found for the programmer (think they’re actually for a larger more expensive programmer that somehow has the same name)? I have a few drivers i have found that I think might have worked, but even when I try and update the device driver with them from hardware manager under the other devices tab (I actually do see “USBasp”, so i’m connected at least), nothing seems to be recognized as a valid driver. It seems to at least recognize the device as not be ‘unknown’, but it has the exclamation mark for ‘no driver installed’ and none of the ones I’ve tried seem to be accepted). Which driver do I need so that my (windows 7 home prem; 64 bit OS intel processor), can actually recognize and properly interface with the cheapie USBasp I bought?
Wait, found a few more on that page you linked, gonna try all of them first ![]()
dang, one is exactly the same as one of the ones I’ve tried before the other is
usbasp.2011-05-28.tar.gz I not sure what I’m supposed to do with “.tar.gz” files? (run into this problem before while working on this, I’ve never seen.tar.gz files before now : )
I’ve tried running the files: installer_x86.exe and installer_x64.exe but the command interface (like with CMD), flashes very very briefly then vanishes. I have seen these files many times in the possible driver options I’ve been exploring so maybe this contains the solution and I’m just not doing something right?
You need libusb-win32-bin-1.2.6.0.zip. tar.gz is Linux crap.
This has helped, I found it before but didn’t look through the folders/files hard enough; now I have an installed driver for my device ![]()
Found USBasp on USB Port (This is deff a new thing for me WHOOHOO)
Powering On …
Power On Failed
Cannot communicate with target Chip !
retrying etc etc
So my wiring is messed up most likely yes?
I will go back to here (How To Build a Flashlight With Perfect Modes (picture heavy) post #54), and then proceed on from there and see what suggestions were come up with already (if anything was worked out for sure from there).
Yeah, once I get this all down I will definitely have to consolidate the steps I needed and put them together (except I suspect the wiring may be different for everyone… ![]()
Thanks for all your help so far, I’m definitely make (very slow : ) progress now
Ah HA! I am now wired correctly, and can read my chip
now to start trying to figure more stuff out ![]()
the lockbit fuse have only 3 different state and use only bit 0 and bit 1, value 0 is programed, 1 is not programed
bit0=1 and bit1=1 so 0xFF it’s unlocked
bit0=0 and bit1=1 so 0xFE you can’t reprogram it but you can read it
bit0=0 and bit1=0 so 0xFC you can’t read and reprogram it
bit0=1 and bit1=0 is not valid
it’s confusing to use 0 to be activated.
but using 0xC0, you in fact activated the 6 first bit (11000000)
So it have the same effect as 0xFC as only the first 2 bits count (read from the right)
As it’s now protected from programing and reading, when you try to read it, it’s scrambled.
The only way to return to 0xFF is to erase the chip.
see for yourself the result of you lockbit settings AVR Fuse Calculator for ATtiny13A
You need libusb-win32-bin-1.2.6.0.zip. tar.gz is Linux crap.
winrar and 7zip will extract those I believe, but they won’t run on windows…you need the win32 binary
How hard would it be to add something like this to a mode group?
How hard would it be to add something like this to a mode group?
Only one way to see that ![]()
you would have to set min and max values properly thou…
Got some time off from this for a little bit
but I’m doing all my cpr training (so if any old farts around washington in the states sorta ‘fall out’, i’ll hook ya up to my vehicle’s alternator and practice some things I done come up with if I’m around ; ). I could drop in some programmed lines of code but I want to learn to write my own dang code, I’ll be back with more questions soon enough lol. Think My first step is to DL some BLF tiny13 processor flash files, then learn them myself till I understand what the hack you’ll did when you’ll wrote them. Then write my own and try em out and ask questions (by posting my ‘attempts’ on here to be evaluated for free by people who actually ‘know their shi- errr, stuff’). Thanks again for all the help and I will be asking for more ![]()
BLF rocks.
Cool Project!
After a few houres and hundreds of taps i finally understand the programming system. It is very hard to understand it from the readme if this is your first programmable flashlight. Maybe this will help other beginners:
1: short tap is less than 1 second
2: long tap is between 1 and 2 seconds
3: very long tap is more than 2 seconds
1. choose mode you want to change: 111… (every NUM_EXT_CLICKS have to be a 3 to reset counters)
2. stay in that mode for more than two seconds: 3
3. enter extended mode group: if NUM_EXT_CLICKS == 6: 1111111 (at the last 1 will be a blink)
4. choose mode you want to have: 1111111111…
5. stay in the mode you want to have for more than two seconds: 3
6. lock in (save to eeprom) the new mode: 1121 (important here: 1 is around 1 sec, 2 is around 2 sec. if you tap too short, it will not work! with proghelper enabled: tap until blink!)
7. ready! switch through modes to see if it works: 111… (every NUM_EXT_CLICKS have to be a 3 to reset counters)
I think NUM_EXT_CLICKS = 6 is too less. I often enter programming mode accidently. I think 15 or 20 is a good value.
Is there any battery indicator in this firmware? Blink codes for example?
Maybe a bug: When i disable FUNC_STROBE, it will not compile. I have to comment out lines 203 to 205 to get it working:
//MODE_STROBE, // 0x09
//MODE_POLICE, // 0x0A
//MODE_BEACON // 0x0B
My extended modes are very strange:
1: lowest
2: lowest
3: lowest
4: lowest
5: lowest
6: lowest
7: 1 above lowest (can not measure low current)
8: 2 (can not measure low current)
9: 3 - 60mA
10: 4 - 640mA
11: 5 - 1530mA
12: 6 - 2150mA (there should be 2,8A a full throttle!?).
What am I doing wrong?
Taking my first run at programming an AK-47 with a Tiny13A chip. To start with the basics of getting ANY different firmware on there I’ve started with Tido’s well regarded BLF-VLD however I keep running into the following:
I enter:
avrdude -p t13 -c usbasp -u -Uflash:w:BLF-VLD.hex:a -Ueeprom:w:BLF-VLD.eep:a -Ulfuse:w:0x79:m -Uhfuse:w:0xed:m
Then receive the following message:
avrdude: reading input file “BLF-VLD.hex”
avrdude: error opening BLF-VLD.hex: No such file or directory
avrdude: input file BLF-VLD.hex auto detected as invalid format
avrdude: can’t open input file BLF-VLD.hex: No such file or directory
avrdude: write to file ‘BLF-VLD.hex’ failed
avrdude done. Thank you.
From the flashlight wiki, “Open a command window in one of the BLF-VLD subdirectories: ”Fixed Modes”, “Programmable”, or “Simple”. With everything hooked up, enter this command:” This is where I suspect I’m off. How do I “open a command window in one of the BLF-VLD subdirectories”? To begin with, I’m just looked to flash the “Fixed” portion of BLF-VLD.
Any help where I’ve gone wrong would be greatly appreciated.
Thanks
I guess the number of people with no DOS experience is growing rapidly now. Use to be you couldn't even use a PC without knowing DOS. Man, I'm getting old.
Hi HighEfficiency and welcome to the forum. You just need to change to the appropriate subdirectory after you open a Command Prompt window. Try the following after you open the Command Prompt window:
cd\
"cd" means change directory. "\" is the root directory of the drive you are using
cd "name of directory you have the hex file in"
Best of luck
Taking my first run at programming an AK-47 with a Tiny13A chip. To start with the basics of getting ANY different firmware on there I’ve started with Tido’s well regarded BLF-VLD however I keep running into the following:
I enter:
avrdude -p t13 -c usbasp -u -Uflash:w:BLF-VLD.hex:a -Ueeprom:w:BLF-VLD.eep:a -Ulfuse:w:0x79:m -Uhfuse:w:0xed:mThen receive the following message:
avrdude: reading input file “BLF-VLD.hex”
avrdude: error opening BLF-VLD.hex: No such file or directory
avrdude: input file BLF-VLD.hex auto detected as invalid format
avrdude: can’t open input file BLF-VLD.hex: No such file or directory
avrdude: write to file ‘BLF-VLD.hex’ failedavrdude done. Thank you.
From the flashlight wiki, “Open a command window in one of the BLF-VLD subdirectories: ”Fixed Modes”, “Programmable”, or “Simple”. With everything hooked up, enter this command:” This is where I suspect I’m off. How do I “open a command window in one of the BLF-VLD subdirectories”? To begin with, I’m just looked to flash the “Fixed” portion of BLF-VLD.
Any help where I’ve gone wrong would be greatly appreciated.
Thanks
copy it to a directory on your c:\ drive, name it with NO spaces
I usually put mine in c:\avrusb or something simple like that
and yeah…ImA4Wheelr, command line for some is dangerous…me I love poking around in the graphic less box making the computer do stuff with simple text…even more so with putty and linux ![]()
If you're on Windows 7, you can shift + right click in the directory your files are in and select "Open command window here". On XP you add to install a little tool to get that, and I'm not sure about Windows 8.
Welcome to the site! Good luck with the programming, we're certainly here to guide you through it.