]> rtime.felk.cvut.cz Git - arc.git/blob - boards/ti_tms570ls/examples/rte_simple/Tasks.c
More work on rte_simple example.
[arc.git] / boards / ti_tms570ls / examples / rte_simple / Tasks.c
1 /*\r
2  * Tasks.c\r
3  *\r
4  *  Created on: 16 jun 2011\r
5  *      Author: maek\r
6  */\r
7 \r
8 #include "Os.h"\r
9 #include "Mcu.h"\r
10 #include "arc.h"\r
11 \r
12 //#define USE_LDEBUG_PRINTF // Uncomment this to turn debug statements on.\r
13 #include "debug.h"\r
14 \r
15 // How many errors to keep in error log.\r
16 #define ERROR_LOG_SIZE 20\r
17 \r
18 \r
19 void StartupTask( void ) {\r
20         LDEBUG_FPUTS("StartupTask start\n");\r
21 \r
22         // Call second phase of startup sequence.\r
23         EcuM_StartupTwo();\r
24 \r
25         // Startup CanIf due to ComM is missing in this example\r
26         CanIf_InitController(CANIF_Channel_1, CANIF_Channel_1_CONFIG_0);\r
27         CanIf_SetControllerMode(CANIF_Channel_1, CANIF_CS_STARTED);\r
28 \r
29         // Make sure that the right PDU-groups are ready for communication.\r
30         Com_IpduGroupStart(ComPduGroup, 0);\r
31 \r
32         // End of startup_task().\r
33         TerminateTask();\r
34 \r
35 }\r