[En-Nut-Discussion] [Understand compilation process] avr-objcopy -R .eeprom

Rodrigue rodrigue.roland at gmail.com
Tue Feb 20 12:45:39 CET 2007


Anybody doesn't know why we suppress the .eeprom section ? 
Is this section used Nut/OS? I think that the answer is yes but only within
the software...


Rodrigue wrote:
> 
> Hello,
> 
> When I compile "simple" project. The following commands are executed:
> avr-objcopy -R .eeprom -O ihex simple.elf simple.hex
> avr-objcopy -O binary simple.elf simple.bin
> 
> The first command removes the .eeprom section form simple.elf and converts
> the rest of the file in ihex format (is it Intel Format?). Why remove this
> section? How to write the eeprom section? If I have a variable like this
> in my software:
> static const char my_string[] __attribute__ ((section(".eeprom"))) = "This
> data will be loaded into EEPROM";
> What's happening?
> 
> The second command converts simple.elf file in binary format which is not
> used after, so I don't understand why it's generated?
> make -k burn 
> avrdude -p atmega128 -P com1 -c stk500v2 -V -U flash:w:simple.hex 
> 
> Thanks in advance!
> Rodrigue
> 
> 

-- 
View this message in context: http://www.nabble.com/-Understand-compilation-process--avr-objcopy--R-.eeprom-tf3250513.html#a9060304
Sent from the MicroControllers - Ethernut mailing list archive at Nabble.com.




More information about the En-Nut-Discussion mailing list