NerdKits - electronics education for a digital generation

You are not logged in. [log in]

NEW: Learning electronics? Ask your questions on the new Electronics Questions & Answers site hosted by CircuitLab.

Basic Electronics » USBasp Help!

October 21, 2015
by TheUnfocusedOne
TheUnfocusedOne's Avatar

Hey guys,

Long time since I've been on here. I'm trying to get into programming MCUs again. I recently purchased a USBasp (from NewbieHack.com), and I'm trying to get an ATTiny85 working. I know from reading around that I can't connect to the t85 due to its slow clock speed. I've ready in a bunch of places that I need to set a jumper somewhere on my board to slow the clock speed of my USPasp down to be able to communicate, but I'm not sure what jumper I should connect (they aren't labeled). Any one use this USBasp before and could give me some insight? I'm really new to all this stuff, but I'm trying to get up any running fast.

Here's a full link :https://www.newbiehack.com/categories/newbiehack-development_tools-prototyping-microcontroller-USB-AVR-Programmer-usbasp

Thanks! -Brian

October 22, 2015
by Rick_S
Rick_S's Avatar

As long as you have has a somewhat recent version of AVRDUDE, Within the last several years, all you need to do to slow down the ISP clock for your programming. This is done with the -B parameter (bitclock period). When programming new ATMega328's, I use the -B 6 option (6us). Some people talk about using -B 3 (3us) The default is 1 (1us). Either way, try adding that to your parameters and don't worry about the jumpers. More than likely that'll get you going.

Here is a link to the parameter descriptions for AVRDUDE

and the excerpt from them regarding the -B parameter.

-B bitclock

Specify the bit clock period for the JTAG interface or the ISP clock (JTAG ICE only). The value is a floating-point number in microseconds. The default value of the JTAG ICE results in about 1 microsecond bit clock period, suitable for target MCUs running at 4 MHz clock and above. Unlike certain parameters in the STK500, the JTAG ICE resets all its parameters to default values when the programming software signs off from the ICE, so for MCUs running at lower clock speeds, this parameter must be specified on the command-line. It can also be set in the configuration file by using the ’default_bitclock’ keyword.

Rick

October 22, 2015
by sask55
sask55's Avatar

You could consider downloading and using Khazama AVR Programmer. I believe it will handle all the perimeter setup and auto program virtually any of the AT chips including the ATtiny85

Post a Reply

Please log in to post a reply.

Did you know that you can build a circuit to convert the "dit" and "dah" of Morse code back into letters automatically? Learn more...