Problems programming the AVR-Stick

I recently purchased an AVR-Stick from Sparkfun:

http://www.sparkfun.com/commerce/produc … ts_id=9147

I would like to program it and I have run into a few issues.

Before I start listing problems, let me give you an overview of my environment:

–OS X, MacBook Pro

–avrdude version 5.8 , the latest from macports

–avr-gcc version 4.1.1

–USBTinyISP programmer

Okay, first problem (just for documentation purposes), trying to run

$ make

right out of the box threw this error:

make: Nothing to be done for `all’

I was able to remedy this situation by first running:

$ make clean

The next problem I ran into was with the checksize script:

./checksize main.bin 4096 256

make: execvp: ./checksize: Permission denied

make: *** [main.hex] Error 127

I was able to remedy this one by running:

$ chmod 777 ./checksize

So now I am got everything compiling and I got my .bin , .o, and my .hex files. I decide to try to upload the code via avrdude. I plug in my usbtinyisp and the avr stick lights up.

Then I run this:

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex

It finds the programmer and the red light (the data light) on the programmer flashes for a second, the avr stick also seems to acknowledge the request. But then I immediately see this error:

avrdude: initialization failed, rc=-1

Double check connections and try again, or use -F to override

this check.

avrdude done. Thank you.

of course, trying -F yields this classis avrdude error:

avrdude: initialization failed, rc=-1

avrdude: AVR device initialized and ready to accept instructions

avrdude: Device signature = 0x000000

avrdude: Yikes! Invalid device signature.

avrdude: Expected signature for ATtiny85 is 1E 93 0B

avrdude done. Thank you.

I tried fiddling with the -B options:

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex -B 1 -F

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex -B 2 -F

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex -B 4 -F

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex -B 8 -F

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex -B 10 -F

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex -B 32 -F

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex -B 250 -F

$ avrdude -c usbtiny -p attiny85 -U flash:w:main.hex -B 1024 -F

Still the same…

and this is where I am stuck. Keep in mind that I am using the USBTinyISP to power the board. I think it is applying 5 volts but I read that the attiny85 is rated for 5.5v. However, I am sure the circuitry is designed for USB levels (3.3v). I read on the ladyada forums that this problem occurs when trying to program her TV B Gone because of an LED pulling too much current from one of the ICSP lines.

I found this:

viewtopic.php?f=15&t=16465&hilit=avr+stick

so I am guessing that someone has done it, I just didn’t post there b/c I am pretty sure this has to do with the USB programmer. I just want to get some feedback. Should I be in Lady Ada’s forum?

Any help is greatly appreciated. I am pretty pissed off that I can’t get this working!

Did you ever get this thing programmed, cause i’m in the same boat and can’t figure this out for the life of me…

bump-

same thing here. I am an electrician trying to become are accustomed to some of these computer issues because the moisture meters I tend to work on are started to add bluetooth and USB functionality. Any information here would be very helpful. Have you all heard of [www.wagnermeters.com?](http://www.rhspec.com)