Attiny programming

@zmetzing do you have any experience with programming AVR chips, and would you be willing to help a guy out? I’ve been trying to help my son build a TinyTesla for a while now, and we just got around to testing the thing, and blew a chip.

I have a replacement chip. I have the source code for the firmware, and I have reflashed the attiny 85, but I can’t seem to get it to work. I’m not sure if I’m just missing something. ANy pointers would be greatly appreciated. Also the original chip was an Attiny 85 10pu, and the new one is Attiny 85 10pu. Not sure if that is enough difference to make it not work. By not work, I mean that when I plug into a usb port it is not recognized.

I am using a tiny avr from Tanner to load the firmware. It seems to go on fine, and verifies. My only concern right now, is if I read the firmware to a file, it seems to be off by comparing to the source, but if I just the dvrdude to verify it, it comes back fine.

I know just enough to be dangerous here.

First line of main.hex. The program to load.
1000000085C04CC29EC0BDC69CC09BC09AC099C052

First line of the readout of the firmware after loading.
:2000000085C04CC29EC0BDC69CC09BC09AC099C098C097C072C695C094C093C092C0040306

What were the fuse settings for the original attiny, and are you correctly programming those in the new chip?

The fuse settings are not stored in the firmware, and are a different process to program.

What software are you using to program?
What is the command/process are you using for the programming?

Good question. There is also an eeprom, that I don’t know if it was blank or not. I only have the zip file to reference with the original firmware. http://onetesla.com/media/usbInterrupter.zip

I am using dvrdude to load the firmware with the command

avrdude -c usbtiny -p t85 -U flash:w:main.hex:ice_cream:

The source is precompiled in the zip file, I found out after loading winavr to compile it. I have not set the fuses, as I’m not sure how to read them. I tried reading them, and writing to a file, and that failed.

I was finally able to read the fuses on the original and they were:

hfuse
:01000000DD22
:00000001FF

lfuse
:01000000C13E
:00000001FF

efuse
:01000000FF00
:00000001FF