/* Library includes. */\r
#include "string.h"\r
\r
+/* Hardware specifics. */\r
+#include "iodefine.h"\r
+\r
/*-----------------------------------------------------------*/\r
\r
/* Tasks should start with interrupts enabled, therefore PSW is set with U,I,PM \r
PM = 0 Supervisor mode.\r
IPL = 0 All interrupt priorities enabled.\r
*/\r
-#define portINITIAL_PSW ( ( portSTACK_TYPE ) 0x00030000 )\r
-#define portINITIAL_FPSW ( ( portSTACK_TYPE ) 0x00000100 )\r
+#define portINITIAL_PSW ( ( portSTACK_TYPE ) 0x00030000 )\r
+#define portINITIAL_FPSW ( ( portSTACK_TYPE ) 0x00000100 )\r
\r
\r
/*-----------------------------------------------------------*/\r
use. A demo application is provided to show a suitable example. */\r
vApplicationSetupTimerInterrupt();\r
\r
+ /* Enable the software interrupt. */ \r
+ _IEN( _ICU_SWINT ) = 1;\r
+ \r
+ /* Ensure the software interrupt is clear. */\r
+ _IR( _ICU_SWINT ) = 0;\r
+ \r
+ /* Ensure the software interrupt is set to the kernel priority. */\r
+ _IPR( _ICU_SWINT ) = configKERNEL_INTERRUPT_PRIORITY;\r
+ \r
/* Start the first task. */\r
prvStartFirstTask();\r
}\r
}\r
/*-----------------------------------------------------------*/\r
\r
-void vPortYield( void )\r
-{\r
-}\r
-/*-----------------------------------------------------------*/\r
-\r
-#pragma interrupt (vTickISR(vect=configTICK_VECTOR,enable))\r
+#pragma interrupt ( vTickISR( vect = _VECT( configTICK_VECTOR ), enable ) )\r
void vTickISR( void )\r
{\r
- /* Restore previous IPL on exit. */\r
- //set_ipl( configMAX_SYSCALL_INTERRUPT_PRIORITY );\r
+static volatile unsigned long ul = 0;\r
+\r
+ ul++;\r
\r
/* Clear the interrupt. */\r
- vTaskIncrementTick();\r
+// vTaskIncrementTick();\r
\r
#if( configUSE_PREEMPTION == 1 )\r
- taskYIELD();\r
+// taskYIELD();\r
#endif\r
}\r
/*-----------------------------------------------------------*/\r
\r
+#pragma interrupt ( vSoftwareInterruptISR( vect = _VECT( _ICU_SWINT ), enable ) )\r
+void vSoftwareInterruptISR( void )\r
+{\r
+static volatile unsigned long ul = 0;\r
+\r
+ ul++;\r
+}\r
+\r
#pragma inline_asm prvStartFirstTask\r
static void prvStartFirstTask( void )\r
{\r
NOP\r
NOP\r
}\r
+\r
+\r