mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-04-20 05:21:59 -04:00
Move the call to start the high frequency timer to inside a task to ensure it does not trigger before the scheduler has started.
This commit is contained in:
parent
5a1129c315
commit
9d0e60493a
|
@ -190,7 +190,6 @@ unsigned portLONG ulRegTest1Cycles = 0, ulRegTest2Cycles = 0;
|
|||
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
|
||||
/*
|
||||
* Create the demo tasks then start the scheduler.
|
||||
*/
|
||||
|
@ -219,9 +218,6 @@ int main( void )
|
|||
/* prvCheckTask uses sprintf so requires more stack. */
|
||||
xTaskCreate( prvCheckTask, "Check", configMINIMAL_STACK_SIZE * 2, NULL, mainCHECK_TASK_PRIORITY, NULL );
|
||||
|
||||
/* Setup the high frequency, high priority, timer test. */
|
||||
vSetupTimerTest( mainTEST_INTERRUPT_FREQUENCY );
|
||||
|
||||
/* Finally start the scheduler. */
|
||||
vTaskStartScheduler();
|
||||
|
||||
|
@ -290,6 +286,10 @@ static portCHAR cStringBuffer[ mainMAX_STRING_LENGTH ];
|
|||
extern unsigned portLONG ulMaxJitter ;
|
||||
xLCDMessage xMessage = { ( 200 / portTICK_RATE_MS ), cStringBuffer };
|
||||
|
||||
/* Setup the high frequency, high priority, timer test. It is setup here
|
||||
to ensure it does not fire before the scheduler is started. */
|
||||
vSetupTimerTest( mainTEST_INTERRUPT_FREQUENCY );
|
||||
|
||||
/* Initialise the variable used to control our iteration rate prior to
|
||||
its first use. */
|
||||
xLastExecutionTime = xTaskGetTickCount();
|
||||
|
@ -367,7 +367,13 @@ xLCDMessage xMessage = { ( 200 / portTICK_RATE_MS ), cStringBuffer };
|
|||
}
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
void vApplicationGeneralExceptionHandler( unsigned portLONG ulCause, unsigned portLONG ulStatus )
|
||||
void vApplicationStackOverflowHook( void )
|
||||
{
|
||||
for( ;; );
|
||||
}
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
void _general_exception_handler( unsigned portLONG ulCause, unsigned portLONG ulStatus )
|
||||
{
|
||||
/* This overrides the definition provided by the kernel. Other exceptions
|
||||
should be handled here. */
|
||||
|
|
Loading…
Reference in a new issue