Forum: Compiler & IDEs String


von Mario Schmitt (Gast)


Lesenswert?

Hallo

ivh habe in der main-Funktion eine Variable folgendermassen definiert.

char text[] = "Hallo";

Der Compieler mekert auch nicht.

Beim Testen des Programms in AVR-Studio 4 sind alle Speicherstellen
mit
0XFF belegt.

Die Datei wurde mit dem Befehl "make extcoff" compiliert.

Wo liegt mein Denkfehler ?

mfg
Mario Schmitt

von Peter Fleury (Gast)


Lesenswert?

Bitte c:\WINavr\AVRCOFFREADME.txt lesen !

Abschnitt "Known Issues":

The second issue is that AVR Studio until now didn't support the way
gcc allocates the initialization data for initialized variables: they
are not issued as part of the program code, but instead need to
appended manually after the program code itself.  (When preparing an
Intel Hex file, this is usually done by specifying both, the .text and
.data section in the call to avr-objcopy.)  So in the end, AVR Studio
was simulating with all the initializers still using 0xff as ROM
contents.

Bitte melde dich an um einen Beitrag zu schreiben. Anmeldung ist kostenlos und dauert nur eine Minute.
Bestehender Account
Schon ein Account bei Google/GoogleMail? Keine Anmeldung erforderlich!
Mit Google-Account einloggen
Noch kein Account? Hier anmelden.