Newb can't figure out enabling counters

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

cross mob
dacoc_960756
Level 1
Level 1

I have an application where I need several counters to manage shifting bits out.  I have a PSOC5LP, and decided to try to create the stand alone logic there - trying to implement with just the schematic entry logic tools for starters.

   

I've tried several different counters, both UDB and fixed, including "Counter", "Count7", "Basic Counter", and in each case have fed them a low speed clock (5-50Hz), and used the built in LED to attempt to monitor the output (P2.1). On counters with an "enable", I attached a "LOGIC HIGH" to enable, and devices with a reset a "LOGIC LOW". 

   

Even though I can monitor the clock ticking (when set to few Hz) with the LED, the output of the counter, the TC and the Compare never change, even when using a "SYNC" element for UDB counters.  It's like there is a separate enable beyond the "Hardware only"... 

   

This is such a basic thing, and the two examples I can find are both for different eval kits with LCDs, so they won't run. There must be a "make it go" button somewhere that I'm missing. 

   

Thanks much

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

Without your project just a guess: Did you call the _Start() API for each counter? This will energize the underlying hardware.

   

If you did that, can you please post your complete project so that we all can have a look at all of your settings. To do so, use
Creator->File->Create Workspace Bundle (minimal)
and attach the resulting file.

   

 

   

Bob

View solution in original post

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

Without your project just a guess: Did you call the _Start() API for each counter? This will energize the underlying hardware.

   

If you did that, can you please post your complete project so that we all can have a look at all of your settings. To do so, use
Creator->File->Create Workspace Bundle (minimal)
and attach the resulting file.

   

 

   

Bob

0 Likes

Bingo! Thanks much.  I assumed that the "Enable Mode=Hardware Only" implied you didn't have to software enable it. 

   

Thanks again for the clarification. I can move forward now... 

   

D

0 Likes
CoMa_264751
Level 2
Level 2
10 replies posted 5 replies posted 5 sign-ins

As Bob Marlow says it always worth looking at the API's for a start() api, with any component that seems not to be working, this had me caught a number of times when I was starting out. 

   

I recently built a PAL video timing chain with a counter and numerous digital comparators components. Not one interrupt used which is the way I like logic to work.

   

Hope you enjoy schematic programming it has made life so much easier for me.

0 Likes