Avrdude and Megabootloader

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

Hi,
I use Mega88 with Megabootloader.
With Avr-Osp II all works well.

Now I test Avrdude without a succes.
I try to read flash. I see no errors in Avrdude report,
but in the file read.hex there is only

:00000001FF

I used command
avrdude -p m88 -c avr109 -P com4 -b 38400 -U flash:r:read.hex:i
I tried also avr911 instead of Avr109. The result is the same.

Thank you

Avrdude report:

Attachment(s): 

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

The Intel Hex you quoted is the "termination record". In other words there's NOTHING useful in the .hex file at all - are you sure this isn't the one destined for the EEPROM rather than the one destined for the code flash? In the case of a bootloader there's a strong chance the EEPROM .hex file will be empty (but usually the EEPROM file has a .eep rather than a .hex filetype to differentiate it from the code flash file)

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

Hi clawson,
Thanks for replay.
I am at a very beginning with avrdude.
So how can I read the flash and save its content to the file "read.hex"?
Is my command not correct?

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

Quote:

So how can I read the flash and save its content to the file "read.hex"?

What would be the point in that? You are far better off rebuilding any code in the device from source. Looking at extracted code is going to be fairly pointless.

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

Hi,
The point is to make avrdude work with my Megabootloader.
I get the folowing message when I try to write flash.

Edit:
Now I have found this:
When I first erase the chip (with AvrOsp) then Avrdude writes the flash succesfuly.
Otherwise I get the report below.

I think, I am going to give up this frustrate effort.
---

Attachment(s): 

Last Edited: Tue. May 26, 2009 - 02:57 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I don't know what "megabootloader" is (is that what Arduino call their one?) but are you sure it uses 38400 baud?

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

Hi,
I am attaching the bootloader.

Quote:
are you sure it uses 38400 baud?

Yes, as I wrote avrdude even writes into empty flash.
See the avrdude report below.
But it does not erase, read etc.

Attachment(s): 

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

Visovian wrote:

See the avrdude report below.
But it does not erase, read etc.
It seems to verify, so doesn't that mean that it reads the flash?

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

It looks to me like it worked just fine!!!

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

Thank you all.

I resume:
I use this bootloader (originaly MegabootloaderBlips), because it fits in 512 bytes. With Avr-Osp II it works well.

I wondered if it would work with Avrdude
But it seems it will not.
Never mind. Not vital thing for me.

In case I need a bootloader with Avrdude I can use this:
https://www.avrfreaks.net/index.php?func=viewItem&item_id=62&module=Freaks%20Tools
A disadvantage is that it needs 2kB BL section.

Thanks again.