cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC Creator & Designer Software

Anonymous
Not applicable

Hi,

   

I have followed the Cypress recommendation and installed the compiler from Keil. It builds my project successfully with a more compact code as the ARM GCC 4.7.3, but it generates in my main.c source some strange error messages.

   

Example 1: uint32_t   A1Tim;    is marked with a red dot and the message: reference to uint32_t is ambiguous,

   

                                                    #include <stdint.h> is specified

   

Example 2: CyGlobalIntEnable;  is marked with a yellow triangle and the message:implicit declaration of function is invalid in C99

   

Must I include special header files in order to avoid these error messages? Or install something else?

   

Even if the project builds successfully, I don´t like error messages neither red nor yellow.

   

Thanks for your hint and best regards

   

Walter

0 Likes
7 Replies
JoMe_264151
Expert II

Different compilers may reqiure different libraries. Probably the definition for uint32_t occurs more than once and the declaration for CyGlobalIntEnable is missing.  Since the cy_boot component (which contains the definition of CyGlobatIntEnable) is "automatically" included into every project -as the System Reference Guide says- it might be the case that you have to include that reference manually. Are there any recommendations for libraries coming with that compiler?

   

 

   

Bob

0 Likes
Anonymous
Not applicable

Hi,

   

Many thanks for your quick answer.

   

For using the Keil compiler, I have installed uVision5 (32K version) and defined the path of the compiler in PSoc Creator.

   

I have not seen any hint from Keil regarding the usage in the Cypress environment.

   

In case, I comment the <stdint.h>, the error messages stay.

   

In case, I comment the <project.h>, these errors diappear, but others came out.

   

I think, I will give up the Keil stuff and go back to the good old GCC.

   

Does somebody know, when the GCC 4.8 will be included in the creator?

   

Best regards

   

Walter

0 Likes
markgsaunders
Employee

You definitely need the project.h file to be included. It makes sure you "see" the CyGlobalIntenable macro and the types header.

   

Normally you can switch between the two compilers and simply rebuild. I cannot comment on the errors you see though. Maybe you could post them?

   

I suspect there is an include path issue, which is why you get "not found" errors. The issue is not the compiler itself - you get the editor icons without even running the compiler. Take a look at your project settings and compare the include paths for the GCC and MDK compilers. Go to Project->Build Settings and use thew toolchain pull-down to switch between the compilers so you can see the includes (under).

   

-- Mark.

0 Likes
Anonymous
Not applicable

Hi Mark,

   

Many thanks for your hints.

   

I have attached the error messages, which come up in the IDE, if ARM MDK is selected.

   

It seems, it is a problem of the IDE, because the compiler builds successfully. Maybe uint32_t has been defined twice with different declaration.

   

In the build settings of the project, I did not see any include settings for both compilers.

   

best regards

   

Walter

0 Likes
Anonymous
Not applicable

Next error.

0 Likes
ETRO_SSN583
Esteemed Contributor

This might help -

   

 

   

    

   

          http://www.cypress.com/?id=4&rID=94607

   

 

   

Regards, Dana.

0 Likes
Anonymous
Not applicable

Hi Dana,

   

Many thanks for you interesting hint about systick.

   

This function works well in my project, but the shown errors appear only if  the Keil compiler is selected.

   

Walter

0 Likes