cancel
Showing results for 
Search instead for 
Did you mean: 

USB-FS-Device development kit demo won't compile

Stm32User
Associate II
Posted on March 27, 2012 at 17:50

Has anyone got this to compile.

I downloaded it and selected the virtual comport demo.  Compiled it for STM32L152-EVAL board using IAR tools and there are 143 errors.  

core_cm3.c '' core does not support this register '' et al

The build is set for the target board. Its almost as though the target processor is wrong

Any ideas ?

#iar-compiler-errors
6 REPLIES 6
alok472
Associate II
Posted on March 28, 2012 at 03:44

This can be because of the IAR tool chain changes from v6.2x onwards. (new intrinsics added which  are conflicting with CMSIS headers )

Try the following

Open the Project -> General Option -: Library configuration, Click/Check on ''USE CMSIS''

Go to Preprocessor settings [Project>Options>C/C++ Compiler>Preprocessor]

Remove:

$PROJ_DIR$\..\..\..\Libraries\CMSIS\CM3\CoreSupport 

Stm32User
Associate II
Posted on March 28, 2012 at 10:36

I have tried this

Project -> Options -> General Options - Library Configuration tab

The ''USE CMSIS'' radio button is greyed out.  I can't ungrey it with any combination of settings.  Is there something I need to do first?

I am completely new to this tool chain

alok472
Associate II
Posted on March 28, 2012 at 19:16

Which IAR version you have installed ?

Stm32User
Associate II
Posted on March 29, 2012 at 10:41

Version of ewb IS 6.30.7.3447

Common components V6.3.17.2218

alok472
Associate II
Posted on March 29, 2012 at 14:01

''The ''USE CMSIS'' radio button is greyed out.  I can't ungrey it with any combination of settings.  Is there something I need to do first?''

This is surprising. Can you pls try to open any other workspace to verify if this option is Greyed out in them as well ? Maybe use any example from ST web. If this is still the case, maybe IAR is not installed properly. i can't think of any other reason.

Also you can check that the folder is Not Read-only in windows-explorer.. 

Stm32User
Associate II
Posted on March 29, 2012 at 17:36

Solution is as described above by Alokm.

The reason the ''USE CMSIS'' radio button is grayed out is because when you open an ST example the target processor is not setup for some reason.

You need to go to Project->Options->C Compiler and set the Target, then follow the instructions above.