Gast
#168379
Hallo, wollte folgenden Code mit WinAVR compilieren: #include <inttypes.h> #include <avr/io.h> #include <avr/interrupt.h> #include <avr/signal.h> DDRB=0xFF; PORTB=0xFF; int lauflicht; lauflicht=1; void main(void){ if(;;){ PORTB=lauflicht; lauflicht=lauflicht<<1; if (lauflicht==0) lauflicht=1; } } Bekomme folgende Fehlermeldung: > "make.exe" all -------- begin -------- avr-gcc (GCC) 3.4.3 Copyright (C) 2004 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Linking: lauflicht.elf avr-gcc -mmcu=atmega8 -I. -gdwarf-2 -DF_CPU=8000000UL -Os -funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums -Wall -Wstrict-prototypes -Wa,-adhlns= -std=gnu99 -MD -MP -MF .dep/lauflicht.elf.d --output lauflicht.elf -Wl,-Map=lauflicht.map,--cref -lm C:/WinAVR/bin/../lib/gcc/avr/3.4.3/../../../../avr/lib/avr4/crtm8.o(.ini t9+0x0): undefined reference to `main' make.exe: *** [lauflicht.elf] Error 1 > Process Exit Code: 2 Kann mir jemand weiterhelfen? Grüße Chris