User forums > Using Code::Blocks

AVR XMEGA ?

(1/3) > >>

RoboMike:
Hi All,

Great work with C::B.   

I'm trying to write code for an AVR XMEGA128A1 .

I didn't find it in the list - so I just added the proper .h file for the chip.

When I build, I get the following error:

 Compiling: main.c
cc1.exe: error: missing argument to "-mmcu="

Is there a way I can manually set this?  If so, where and to what?

Thanks!

stahta01:
Try under "Projects" -> "Build Options"
Tab Compiler Settings
Sub-tab Other Settings

Tim S

RoboMike:
Hi Tim,

Thanks for your help.

In that section I put:

-mmcu=atxmega128a1

and I still get

Compiling: main.c
cc1.exe: error: missing argument to "-mmcu="
Process terminated with status 1 (0 minutes, 0 seconds)
0 errors, 0 warnings
 

Anything else I can try?   :D

Jenna:

--- Quote from: RoboMike on June 29, 2009, 02:47:57 pm ---Anything else I can try?   :D

--- End quote ---
You can check the build log with full commandline support turned on: change "Settings -> Compiler and debugger... -> Global compiler settings -> [the compiler you use] -> Other settings(rightmost tab)" "Compiler logging" to "Full commandline".

And post the appropriate part of the build log, if you do not find the solution yourself.

RoboMike:
Hmmm ....

avr-gcc.exe -Wall -mmcu= -DF_CPU=16000000UL  -g "-mmcu=atxmega128a1"  -mmcu=atxmega128a1    -c main.c -o obj\Debug\main.o
cc1.exe: error: missing argument to "-mmcu="
Process terminated with status 1 (0 minutes, 0 seconds)
0 errors, 0 warnings
 

and when removing the duplicate setting:

avr-gcc.exe -Wall -mmcu= -DF_CPU=16000000UL  -g "-mmcu=atxmega128a1"     -c main.c -o obj\Debug\main.o
cc1.exe: error: missing argument to "-mmcu="

In both I can see that the first -mmcu is the argument avr-gcc is expecting.  My question is now, how I can set that one - instead of creating an "other setting" ?

Navigation

[0] Message Index

[#] Next page

Go to full version