Code: Alles auswählen
#if defined (__AVR_ATmega32__)
#define DAT_BUFFER_SIZE 200
#endif
#if defined (__AVR_ATmega644__)
#define DAT_BUFFER_SIZE 1200
#endif
Code: Alles auswählen
#define DAT_BUFFER_SIZE 1200
Code: Alles auswählen
//----------------------------------------------------------------------------
#define DAT_BUFFER_SIZE 1200
#define CMD_BUFFER_SIZE 17
#define CAM_HEADER 16
volatile unsigned long max_bytes;
volatile long cam_dat_start;
volatile long cam_dat_stop;
volatile long cmd_buffercounter;
volatile long dat_buffercounter;
volatile unsigned char cam_cmd_buffer[CMD_BUFFER_SIZE];
volatile unsigned char cam_dat_buffer[DAT_BUFFER_SIZE];
Code: Alles auswählen
Compiling: timer.c
avr-gcc -c -mmcu=atmega644p -I. -g -Os -funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums -Wall -Wstrict-prototypes -Wa,-adhlns=timer.lst -std=gnu99 timer.c -o timer.o
timer.c: In function 'timer_init':
timer.c:45: error: 'TCCR2' undeclared (first use in this function)
timer.c:45: error: (Each undeclared identifier is reported only once
timer.c:45: error: for each function it appears in.)
timer.c:47: error: 'OCR2' undeclared (first use in this function)
timer.c:49: error: 'SFIE' undeclared (first use in this function)
timer.c:49: error: 'PSR2' undeclared (first use in this function)
timer.c:54: error: 'OCIE2' undeclared (first use in this function)
timer.c: At top level:
timer.c:71: warning: 'TIMER2_COMP_vect' appears to be a misspelled signal handler
make.exe: *** [timer.o] Error 1
> Process Exit Code: 2
> Time Taken: 00:03
Code: Alles auswählen
#if defined (__AVR_ATmega32__)
#define DAT_BUFFER_SIZE 200
#endif
#if defined (__AVR_ATmega644__)
#define DAT_BUFFER_SIZE 1200
#endif
Code: Alles auswählen
# MCU name
#MCU = atmega32
MCU = atmega644
#MCU = atmega644p <- wird von mir nicht unterstützt oder nur teilweise
#MCU = atmega128 <- wird von mir nicht unterstützt oder nur teilweise
Code: Alles auswählen
System Ready
Compiliert am Nov 7 2008 um 09:53:33
Compiliert mit GCC Version 4.2.2 (WinAVR 20071221)
NIC init:READY!
My IP: 172.17.1.25
Kein NTP Server gefunden!!
Code: Alles auswählen
//Timertakt intern oder extern
#define EXTCLOCK 1 //0=Intern 1=Externer Uhrenquarz
Code: Alles auswählen
timer.c:49: error: 'SFIE' undeclared (first use in this function)