AnsweredAssumed Answered

Mixed C and Assembly style coding for K60 on Code warrior 10.3

Question asked by Nasreen Shaikh on May 30, 2013
Latest reply on Jun 3, 2013 by Nasreen Shaikh

HI,

I am trying to write a delay function for k60 in codewarrior 10.3 using the __asm directive.The compiler gives me an error as follows

"expected '(' before '{' token" .The help manual for Codewarrior 10.3 states that

"To ensure that the C/C++ compiler recognizes the asm keyword, you must clear the ANSI Keywords Only checkbox in the C/C++ Language panel. "

But the C/C++ Build properties do not have an option for this particular setting.

In the Build properties panel under the ARM LTD windows GCC C compiler -->Miscellaneous-->Language standard If I change it from Compiler default to ISO C9 -ansi teh error related to asm directive goes away . But the rest of my C code throws up Multiple errors.

I know that asm directive is  ansi keyword. How do I enable my compiler to accept ANSI keywords?   


Outcomes