[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[avr-gcc-list] using eeprom section in avr-gcc

From: Klaus Rudolph
Subject: [avr-gcc-list] using eeprom section in avr-gcc
Date: Sat, 02 Mar 2002 19:30:58 +0100

Hi all,

i use the compiler for assembling with -xassembler.with-cpp
for access to data section i can use sections with
and for text as

But i now want to use eeprom, to get later with avr-objcopy 
a file which i can download to the device.

The compiler have no pseudo-opcode
.eeprom?????? .data works.

Next step is to get the eeprom data from the elf file.
I cant create a file with eeprom so i ask before i go later there in
I think:
avr-objcopy -O srec -j .eeprom test.o test.ee  must work or is
avr-objcopy -O srec -j eeprom test.o test.ee the correct way?

Is the rest of my syntax correct for that problem:

.section .eeprom //this will not work at all, ?????
.eeprom //this will also not work yet

.byte 0x10, 0x20        ;data will be used in eeprom 
.byte 0x55, 0x66

ldi r30, lo8(label1)    ;lo8 only used to get no warning  xx is maybe
greater then 255 
                        ;is it possibel to use the lable in eeprom section for 
referencing to
                        ;position in the assembler source?
out eeadr, r30          ; sorry register name not in my head here, but this is
no question here! :-)
; now reading eeprom 

tested and working example code very welcome as PM. :-)

And last but not least.... have you also a example in C for me with the
eeprom section????

Thanks a lot
avr-gcc-list at http://avr1.org

reply via email to

[Prev in Thread] Current Thread [Next in Thread]