Herbert, Well, I don't know. I created a directory and copied in your makefile. Then I cut and pasted the code from the body of your message into a file named test1.c. Typed "make all" from both the pn and from a dos prompt - worked fine, no errors. About the only suggestion I have left is to make sure your path is correct and you are really using the correct "make" application (first in path??) as opposed to some other make (VC++, PIC, etc. - could account for the invalid assembler option). My path is as follows: PATH=C:\WinAVR\bin;C:\WinAVR\utils\bin; C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS \System32\Wbem;C:\COSMIC\CXHC08LT;c:\program files \devstudio\sharedide\bin\ide;c :\program files\devstudio\sharedide\bin;c:\program files\devstudio\vc\bin;C:\COS MIC\CXHC08LT;C:\PICC Good Luck. Ken ----- Original Message ----- From: "Herbert Graf" To: Sent: Saturday, April 24, 2004 8:57 PM Subject: Re: [AVR]: Still having problems with WinAVR > > > as: unrecognized option `-cu=atmega128' > > > > I think that the "as:" part is the assembler - check the following line in > > the makefile, especially the -mmcu part to make sure you didn't > > accidentally change it to -cu. > > > > ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS) > > > > As far as the warnings go, please paste the first 5 or ten lines > > of test.c into your next message, it appears your missing some > > function prototypes and it would be easier to > > see what is actually there. > > I'm actually now trying with the exact example that comes with the package > (after syntax corrections): > > #include > #include > int main (void) > { > unsigned char counter; > //set PORTB for output > DDRB =0xFF; > while (1) > { > //set PORTB.2 high > PORTB |=1<<2; > //wait (10 *120000)cycles =wait 1200000 cycles > counter =0; > while (counter !=5) > { > //wait (30000 x 4)cycles =wait 120000 cycles > _delay_loop_2(30000); > counter++; > } > //set PORTB.2 low > PORTB &=~(1<<2); > //wait (10 *120000)cycles =wait 1200000 cycles > counter =0; > while (counter !=5) > { > //wait (30000 x 4)cycles =wait 120000 cycles > _delay_loop_2(30000); > counter++; > } > } > return 1; > } > > And the result of 'make all': > > Compiling: test1.c > avr-gcc -c -mmcu=atmega8535 -I. -g -Os -funsigned-char -funsigned-bitfields > -fpack-struct -fshort-enums -Wall -Wstrict-prototypes -Wa,-adhlns=test1.ls t > -Ic:\winavr\avr\include -std=gnu99 -Wp,-M,-MP,-MT,test1.o,-MF,.dep/test1.o .d > test1.c -o test1.o > as: unrecognized option `-cu=atmega8535' > make.exe: *** [test1.o] Error 1 > > FWIW I've tried different processors all with similar errors (i.e. if I sub > atmega16 the error becomes -cu=atmega16) > > I have checked that line in the makefile: > > ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS) > > I've attached the complete makefile to this message (it's very small). > > > I'm disappointed that you're having so many problems. I'm working > > on a project for the circuit cellar contest and was going to > > mention how easily and quickly I was able to get winavr up and > > running (actually had zero problems - I know, just what you wanted to > > hear!). > > > > Ken > > Well I have no problem debugging problems that are mine. Debugging problems > that aren't mine generally aren't something I will do unless absolutely > necessary, and trying to debug defective software is about the lowest on my > scale. > > If it weren't for the circuit cellar contest I wouldn't have bothered to > try for this long. > > Thanks for your help. TTYL > > ---------------------------------- > Herbert's PIC Stuff: > http://repatch.dyndns.org:8383/pic_stuff/ > > -- > http://www.piclist.com#nomail Going offline? Don't AutoReply us! > email listserv@mitvma.mit.edu with SET PICList DIGEST in the body > > > -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body