Pages: [1]   Go Down
Author Topic: Why is direct programing via AVR ISP MKII so slow?  (Read 1333 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 50
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I've noticed even really small programs (1192 bytes) take a lot longer to download when I program the chip (ATMega16) via my AVR ISP MKII (90 seconds) than when I download the same program via the bootloader (about 15 seconds.)  It's almost as if the direct option is programming the full 16K program space.  Or, perhaps it's using a very slow transfer speed.  I'd like to speed this up, but I don't know where to look.  Anyone have any ideas?

Wayne

BTW, I'm using 0012.

Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 12
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The AVRISP mkII has some speed / bit delay option that apparently comes from the factory with a random setting (e.g. really slow).  You can adjust it with AVR Studio.
Logged

0
Offline Offline
Faraday Member
**
Karma: 8
Posts: 2526
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If you're a non-windows user, you can also set it with avrdude.  Sorry, I don't recall how to do it at the moment, but I had to do the same with mine and successfully used avrdude on the mac to speed things up.

-j

Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 50
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Sorry, I should have specified I'm running on a Mac, so I'm not sure how to use AVRStudio.  If someone knows how to set this some other way, please let me know.  Thanks.
Logged

0
Offline Offline
Faraday Member
**
Karma: 8
Posts: 2526
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I googled "avrispmkii slow avrdude" and this was the second hit: http://www.lesto.com/andrewn/avr01.html #5 on that page says

Quote
Problem 5:  Slow ISP Programmer.
      AVRISPmkII was factory configured with a very slow SCK delays.

      Run avrdude in terminal mode and talk to the programmer to change the delay .

      $ avrdude -p m16 -c avrispmkII -b 115200 -P usb -tuF
                   wait for it to prompt you then:
      > sck 10
      > quit

Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 50
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks kg4wsv!  That was exactly what I needed.

Wayne
Logged

Pages: [1]   Go Up
Jump to: