Guten Abend.
Ich habe hier ein XPlain Board von Atmel, und wollte damit gerade ein
bisschen rumspielen.
Ich habe mir dazu das AVR Studio 5 und einen AVR Dragon ordnungsgemäß
installiert.
Wenn ich folgendes Programm auf den µC lade funtioniert es einwandfrei:
1 | int main(void)
|
2 | {
|
3 | int test = 0;
|
4 |
|
5 | test = 1;
|
6 |
|
7 | while (1) {
|
8 | _delay_ms(500);
|
9 | PORTE.OUT &= ~(1<<4); //LED 4 an
|
10 | _delay_ms(500);
|
11 | PORTE.OUT |= (1<<4); //LED 4 aus
|
12 | }
|
13 |
|
14 | return (0);
|
15 |
|
16 | }
|
Wenn ich jetzt aber test als Globale Variable haben möchte, also so:
1 | int test = 0;
|
2 |
|
3 | int main(void)
|
4 | {
|
5 |
|
6 |
|
7 | test = 1;
|
8 |
|
9 | while (1) {
|
10 | _delay_ms(500);
|
11 | PORTE.OUT &= ~(1<<4); //LED 4 an
|
12 | _delay_ms(500);
|
13 | PORTE.OUT |= (1<<4); //LED 4 aus
|
14 | }
|
15 |
|
16 | return (0);
|
17 |
|
18 | }
|
Bekomme ich beim "hochladen" folgenden Fehler:
Some sections of the file provided does not fit within the device
memory.
Do you want to continue programming Flash using only the sections that
fit within the device memory?
Kann mir jemand sagen wie ich hier bitte schön eine Globale Variable
definieren kann?^^
Danke.
Gruß Paul