mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-04-19 21:11:57 -04:00
Add variable to keep a count of the high frequency time tick occurrences. This is then used by the run time stats gathering macros.
This commit is contained in:
parent
c66301ac9e
commit
2293b8ca53
|
@ -83,8 +83,12 @@ zero. */
|
|||
void Timer0IntHandler( void );
|
||||
|
||||
/* Stores the value of the maximum recorded jitter between interrupts. */
|
||||
volatile unsigned portLONG ulMaxJitter = 0;
|
||||
volatile unsigned portLONG ulMaxJitter = 0UL;
|
||||
|
||||
/* Counts the total number of times that the high frequency timer has 'ticked'.
|
||||
This value is used by the run time stats function to work out what percentage
|
||||
of CPU time each task is taking. */
|
||||
volatile unsigned portLONG ulHighFrequencyTimerTicks = 0UL;
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
void vSetupHighFrequencyTimer( void )
|
||||
|
@ -145,6 +149,11 @@ static unsigned portLONG ulMaxDifference = 0, ulLastCount = 0;
|
|||
}
|
||||
|
||||
ulLastCount = ulCurrentCount;
|
||||
|
||||
/* Keep a count of the total number of 20KHz ticks. This is used by the
|
||||
run time stats functionality to calculate how much CPU time is used by
|
||||
each task. */
|
||||
ulHighFrequencyTimerTicks++;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue