uxInitialiseStackFrame() function
Initialize the task's starting interrupt stack frame This function initializes the task's starting interrupt stack frame. The dispatcher will use this stack frame in a context restore routine. Therefore, the starting stack frame must be initialized as if the task was interrupted right before its first instruction is called. - The stack frame is allocated to a 16-byte aligned address - The THREADPTR register is saved in the extra storage area of the stack frame. This is also initialized
Arguments
uxStackPointer
Current stack pointer address
pvParameters
Task function's parameter
threadptr_reg_init
THREADPTR register initialization value
Return value
Stack pointer that points to the stack frame
![]()
uxStackPointer = uxInitialiseStackFrame(uxStackPointer, pxCode, pvParameters, threadptr_reg_init);
uxInitialiseStackFrame() is called by 1 function:
![]()
uxInitialiseStackFrame()
uxInitialiseStackFrame() reads 2 variables and writes 7 variables:
![]()
uxInitialiseStackFrame()