Hi,
Ich wollte gerade meinen ATTINY2313 mit Winavr programmieren, doch der ATTINY2313 taucht unter dem Tool MFile [WinAVR] um das Make file zu machen nicht auf?!
Soll man einfach den AT90s1313 nehmen?
Und wenn ich versuche den LCD Sourcecode von Ulrich Radig zu kompilieren dan erscheint die Fehlermeldung:
makefile:Code:> "make.exe" all set -e; avr-gcc -MM -mmcu=at90s2313 -I. -g -Os -funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums -Wall -Wstrict-prototypes -Wa,-adhlns=lcd.lst -std=gnu99 lcd.c \ | sed 's,\(.*\)\.o[ :]*,\1.o \1.d : ,g' > lcd.d; \ [ -s lcd.d ] || rm -f lcd.d set -e; avr-gcc -MM -mmcu=at90s2313 -I. -g -Os -funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums -Wall -Wstrict-prototypes -Wa,-adhlns=main.lst -std=gnu99 main.c \ | sed 's,\(.*\)\.o[ :]*,\1.o \1.d : ,g' > main.d; \ [ -s main.d ] || rm -f main.d -------- 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. Compiling: main.c avr-gcc -c -mmcu=at90s2313 -I. -g -Os -funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums -Wall -Wstrict-prototypes -Wa,-adhlns=main.lst -std=gnu99 main.c -o main.o Compiling: lcd.c avr-gcc -c -mmcu=at90s2313 -I. -g -Os -funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums -Wall -Wstrict-prototypes -Wa,-adhlns=lcd.lst -std=gnu99 lcd.c -o lcd.o Linking: main.elf avr-gcc -mmcu=at90s2313 -I. -g -Os -funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums -Wall -Wstrict-prototypes -Wa,-adhlns=main.o -std=gnu99 main.o lcd.o --output main.elf -Wl,-Map=main.map,--cref -lm lcd.o(.text+0x0): In function `Read_LCD': C:\WinAVR\projekts/lcd.c:77: multiple definition of `Read_LCD' main.o(.text+0x0):C:\WinAVR\projekts/lcd.c:77: first defined here lcd.o(.text+0x3a): In function `Write_LCD': C:\WinAVR\projekts/lcd.c:46: multiple definition of `Write_LCD' main.o(.text+0x3a):C:\WinAVR\projekts/lcd.c:46: first defined here lcd.o(.text+0x86): In function `LCD_Init': C:\WinAVR\projekts/lcd.c:18: multiple definition of `LCD_Init' main.o(.text+0x86):C:\WinAVR\projekts/lcd.c:18: first defined here lcd.o(.text+0xde): In function `LCD_print_str': C:\WinAVR\projekts/lcd.c:214: multiple definition of `LCD_print_str' main.o(.text+0xde):C:\WinAVR\projekts/lcd.c:214: first defined here lcd.o(.text+0xfe): In function `LCD_Print': C:\WinAVR\projekts/lcd.c:114: multiple definition of `LCD_Print' main.o(.text+0xfe):C:\WinAVR\projekts/lcd.c:114: first defined here lcd.o(.text+0x2ce): In function `LCD_Clear': C:\WinAVR\projekts/lcd.c:223: multiple definition of `LCD_Clear' main.o(.text+0x2ce):C:\WinAVR\projekts/lcd.c:223: first defined here make.exe: *** [main.elf] Error 1 > Process Exit Code: 2
Code:# MCU name MCU = at90s2313 # Output format. (can be srec, ihex, binary) FORMAT = ihex # Target file name (without extension). TARGET = main # Optimization level, can be [0, 1, 2, 3, s]. 0 turns off optimization. # (Note: 3 is not always the best optimization level. See avr-libc FAQ.) OPT = s # List C source files here. (C dependencies are automatically generated.) SRC = $(TARGET).c lcd.c # If there is more than one source file, append them above, or modify and # uncomment the following: #SRC += foo.c bar.c # You can also wrap lines by appending a backslash to the end of the line: #SRC += baz.c \ #xyzzy.c







Zitieren

Lesezeichen