avrdude 5.5 issues: 2 questions

Go To Last Post
4 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Last year, Jörg Wunsch posted detailed instructions on how to build avrdude on Windows using msys.
I followed those instructions and was able to build a working version of avrdude 5.5.
The problem is: the size of this executable is about 2 MB (1,965,010 bytes), much bigger than the version included with WinAVR (239,616).
Does anyone know how to build the smaller version.

I emailed Jorg but no reply yet. Maybe I used an old email address.

Second question:
When using avrdude to program an stk500v1 compatible device (in this case a bootloader), I am finding that programming the EEprom is a problem since avrdude sends each and every byte of the eeprom memory to the device, using the value 0xff for data not in the original hex file.
I can ignore these 0xff values in the bootloader, but besides the fact that this is slow, it also causes the verification to fail if there are other eeprom data present on the chip (say in a different area of the eeprom than the data to be downloaded).
Is this standard behavior?

Thanks for any insights

-Jan-
oscilloscopeclock.com

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

jrseattle wrote:

> The problem is: the size of this executable is about 2 MB (1,965,010
> bytes), much bigger than the version included with WinAVR (239,616).

This is nothing really to worry. Your version simply comes with
debugging symbols, while the WinAVR version is stripped. To know
about the actual size of the individual executable sections (.text,
.data, .bss), use the "size" command on the final .exe file. If the
debugging symbols really bother you, you can use the strip command to
remove them:

Here's the transcript of a Msys terminal session, still on an
older version of avrdude (I just happened to had around):

$ size avrdude.exe 
   text    data     bss     dec     hex filename
 205812    5988    5104  216904   34f48 avrdude.exe

$ ls -l avrdude
-rwxr-xr-x    1 jwunsch  Administ  2524049 May 27 08:50 avrdude

$ cp avrdude.exe avrdude.strip.exe

$ strip avrdude.strip.exe 

$ size avrdude.strip.exe 
   text    data     bss     dec     hex filename
 205812    5988    5104  216904   34f48 avrdude.strip.exe

$ ls -l avrdude.strip.exe 
-rwxr-xr-x    1 jwunsch  Administ   214016 Oct 28 12:52 avrdude.strip.exe

> I emailed Jorg but no reply yet.

Sorry for that, must have been swamped in the dozens of emails I'm
getting each day.

> When using avrdude to program an stk500v1 compatible device (in this
> case a bootloader), I am finding that programming the EEprom is a
> problem since avrdude sends each and every byte of the eeprom memory
> to the device, using the value 0xff for data not in the original hex
> file.

There are several patches around to address this problem, but I
somehow got lost in recognizing whether all of them are really doing
the same, or one of them would be more preferrable. The authors of
these patches don't seem to respond either. If you want to review
them, and file an opinion about which one of them might be the most
preferrable solution: please go ahead.

> I can ignore these 0xff values in the bootloader, but besides the
> fact that this is slow, it also causes the verification to fail if
> there are other eeprom data present on the chip (say in a different
> area of the eeprom than the data to be downloaded).

I'm afraid that detail isn't handled even by the existing patches.

Jörg Wunsch

Please don't send me PMs, use email if you want to approach me personally.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

jrseattle wrote:
When using avrdude to program an stk500v1 compatible device (in this case a bootloader), I am finding that programming the EEprom is a problem since avrdude sends each and every byte of the eeprom memory to the device, using the value 0xff for data not in the original hex file.
avrdude is relatively easy to hack if you know C. So maybe you can fix that by your own.

Stealing Proteus doesn't make you an engineer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks Jorg and Arnold for the replies.

The strip option worked great.

I'll have a look at the source code as time permits though I am so spoiled using interactive debuggers on Windows (both native and avr code) that I'm not looking forward to the debugging process.

For now, I'll use avrdude for complete eeprom programming only.

-Jan-
oscilloscopeclock.com