-
1. Re: Timer Counting Backwards?
bob.marlowe Apr 10, 2017 7:43 AM (in response to cheche_romo_1574446)Welcome in the forum.
The timer usually counts down to zero from period value. A simple difference (PeriodValue - Counter) will give the counts elapsed.
Some more information needed: Which PSoC ? Which board (self made, Kit? Which kit).
When you got stuck, 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
-
2. Re: Timer Counting Backwards?
cheche_romo_1574446 Apr 10, 2017 8:03 AM (in response to bob.marlowe)1 of 1 people found this helpfulGreat, this is what I did:
uint8_t a = Timer_ReadPeriod();
uint8_t b = Timer_ReadCounter();
CurrentTime = (a - b);
Im Using CY8CKIT - 059 , the project is really simple, im just trying to check for Delta time so I can read it at the begin of my loop and then use the same "time" on different functions, I think it was a pretty generic project so i didn't included it, but got it gorking now, thanks Bob