[Top][All Lists]

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

[avr-gcc-list] string initialization

From: Milan Bajza
Subject: [avr-gcc-list] string initialization
Date: Wed, 09 Jul 2003 20:21:40 +0200

Hi All,

I am working on atmega128 with avr-gcc v3.3.

I have problems to initialize a string e.g.
char test[] = "Hello!";

If this string is initialized as global, the linker
put it in the flash and the string has undefined values.
I have used the watch-window.

If I put this line in the main() the linker put it in
the SRAM. This is OK, but all values are 0xFF.

Is the initialization a bug of avr-gcc?
How can I avoid an allocation of the string to the flash memory?


reply via email to

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