'PWM_Timer_STATUS': undefined identifier

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Newbie here,

   

I'm going though the first example in "My First FIve PSoC 3 Designs" and I receive this error.

   

"'PWM_Timer_STATUS': undefined identifier"

   

I downloaded the associated source files and receive the same error.

   

Any help would be greatly appreciated.

   

Thanks in advance,

   

Bryan

0 Likes
6 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

It would be best, if you upload your project here to have us a look at.

   

To do so:

   

Build -> Clean Project

   

File -> Create Workspace Bundle (minimal)

   

and then upload the residing zip-archive with your post.

   

 

   

Did you use in Creator 2.0 the "Build -> Buils Project" command? Changed any name??  

   

 

   

Bob

0 Likes
lock attach
Attachments are accessible only for community members.
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

To add to Bobs comments,

   

 

   

Components have names, and the attached API generator uses those names as

   

the object name. So in this example, the PWM name being PWM_1, if you wanted

   

to call the start function you would write PWM_1_Start(). This is done so API generator

   

can handle multiple components, of same type, and generate APIs specific to each

   

component.

   

 

   

I compiled this project w/o error. There is a define in the project,

   

 

   

So did you change name of PWM_1 to PWM_......?

   

 

   

Regards, Dana.

   

   

#define PWM_1_STATUS (*(reg8 *) PWM_1_PWMHW__SR0)

0 Likes
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

I simply downloaded the example from Cypress and it failed to compile.  Needless to say I'm still learning "C" so I'm sure it's something simple.

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Rename in the schematic PWM_1 to PWM_Timer, then it will compile.

   

Double-click on the component and change the name, cursor is already in the name-field.

   

 

   

Bob

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

By the way: Would you be so kind to post the address here from which you uploaded the project, I'd like to have an error like that correctes soon.

   

Bob

0 Likes
Anonymous
Not applicable

My bad, the source code from the website didn't have the schematic, I made schematic and the error.

   

Thank you all for the help.

   

 

   

Bryan

0 Likes