avr-gcc-list
[Top][All Lists]
Advanced

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

Re: [avr-gcc-list] Memory section different of .text section


From: Yannick PODGORSKI
Subject: Re: [avr-gcc-list] Memory section different of .text section
Date: Tue, 23 Nov 2004 19:24:44 +0100

Hi,
I saw it in gcc 3.4.2 manual, there is an example.
I use --section-start=.function=0x1D000 and the section is well create.

I use __attribute__ ((section(".function"))) in front of functions and it works :
   uint16_t section_fct(void); __attribute__ ((section(".function")))
The function is well put in memory at 0x1D000

I try with variables but it doesn't work :
uint16_t var_section __attribute__ ((section(".function"))) = 0;
The linker doesn't link :-). The error is about "section type conflict".

When I use that :
uint16_t var_section; __attribute__ ((section(".function"))) the variable is put in .bss section
because it is not initialized.

Someone knows about it ?
Thanks for help.

Yannick


Hi,
I work with an ATMega 128, a stk500 and a hyperterminal.
I use a boot loader section at the @ 0x1E000 :
DFLAGS = -Wl,-Ttext=0x1E000 to put all code at this @.

I want to know if it's possible to create a memory section different of .text section
because I need more memory than 8Kbytes.
For example, I want to flash 4Kbytes at @ 0x1d000 and never rewrite on it with the boot loader. It is specifically for crc funtions, usart functions that never changes.

I try to use --section=.function=0x1D000 but the main it put at this @.

I saw many topics on forums but none speak about that. I look in the manual and librairies but nothing on this.
Thanks for help.

Yannick

_______________________________________________
avr-gcc-list mailing list
address@hidden
http://www.avr1.org/mailman/listinfo/avr-gcc-list



reply via email to

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