mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-04-24 07:21:57 -04:00
move the prototype for vApplicationIdleHook to task.h. (#600)
Co-authored-by: pluess <pluess@faulhorn.mw.iap.unibe.ch> Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
This commit is contained in:
parent
99d3d54ac4
commit
6d65558ba0
|
@ -1649,6 +1649,24 @@ configSTACK_DEPTH_TYPE uxTaskGetStackHighWaterMark2( TaskHandle_t xTask ) PRIVIL
|
|||
|
||||
#endif
|
||||
|
||||
#if ( configUSE_IDLE_HOOK == 1 )
|
||||
|
||||
/**
|
||||
* task.h
|
||||
* @code{c}
|
||||
* void vApplicationIdleHook( void );
|
||||
* @endcode
|
||||
*
|
||||
* The application idle hook is called by the idle task.
|
||||
* This allows the application designer to add background functionality without
|
||||
* the overhead of a separate task.
|
||||
* NOTE: vApplicationIdleHook() MUST NOT, UNDER ANY CIRCUMSTANCES, CALL A FUNCTION THAT MIGHT BLOCK.
|
||||
*/
|
||||
void vApplicationIdleHook( void );
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
#if ( configUSE_TICK_HOOK > 0 )
|
||||
|
||||
/**
|
||||
|
|
8
tasks.c
8
tasks.c
|
@ -3477,13 +3477,7 @@ static portTASK_FUNCTION( prvIdleTask, pvParameters )
|
|||
|
||||
#if ( configUSE_IDLE_HOOK == 1 )
|
||||
{
|
||||
extern void vApplicationIdleHook( void );
|
||||
|
||||
/* Call the user defined function from within the idle task. This
|
||||
* allows the application designer to add background functionality
|
||||
* without the overhead of a separate task.
|
||||
* NOTE: vApplicationIdleHook() MUST NOT, UNDER ANY CIRCUMSTANCES,
|
||||
* CALL A FUNCTION THAT MIGHT BLOCK. */
|
||||
/* Call the user defined function from within the idle task. */
|
||||
vApplicationIdleHook();
|
||||
}
|
||||
#endif /* configUSE_IDLE_HOOK */
|
||||
|
|
Loading…
Reference in a new issue