volatile unsigned portSHORT usCriticalNesting = portINITIAL_CRITICAL_NESTING;\r
/*-----------------------------------------------------------*/\r
\r
-/*\r
- * The tick interrupt handler.\r
- */\r
-__interrupt void MD_INTTM05( void );\r
-\r
/*\r
* Sets up the periodic ISR used for the RTOS tick.\r
*/\r
}\r
#else\r
{\r
- TBD\r
-\r
+ /* Task function address is written to the stack first. As it is\r
+ written as a 32bit value a space is left on the stack for the second\r
+ two bytes. */\r
pxTopOfStack--;\r
\r
- /* Task function start address. */\r
- pulLocal = (unsigned long*) pxTopOfStack;\r
- *pulLocal = (unsigned long) pxCode;\r
- pxTopOfStack--;\r
-\r
- /* Initial PSW value. */\r
- *pxTopOfStack = portPSW;\r
+ /* Task function start address combined with the PSW. */\r
+ pulLocal = ( unsigned long * ) pxTopOfStack;\r
+ *pulLocal = ( ( ( unsigned long ) pxCode ) | ( portPSW << 24UL ) );\r
pxTopOfStack--;\r
\r
/* The parameter is passed in AX. */\r