The three tests below tests the following features:
- StartOs(...) function and TerminateTask() function;
- BCC1 mode;
- BCC2 mode;
- BCC1 mode with a shared resource;
- tests behavior 1 and 2
- The goal is to test the start phase of the kernel (StartOs(...)), the activation of a task and its termination procedure.
- To configure the task set we must change the files eecfg.h and eecfg.c located inside the Debug folder.
- Finally, we created inside the EEtest6 a C file with a main() function. That function explicitly calls the StartOs(...) function and finishing with a for(;;). Please note that the TerminateTask() function is called inside a function called by the task. The compilation must finish with an executable fully linked.
- tests behavior 3
- The goal is to create a task with pending activations to test the kernel behaviour in the BCC2 mode. Task2 is executed six times at the beginning.
- tests behavior 4
- The goal is to activate two tasks that share a resource to test the scheduler and the blocking mechanism. The main function activates the low priority task. The high priority task is activated within the first task and is executed at the end of the low priority task. The rtos continues the execution of the high priority task.
When everything is done in the right way, with the following commands we can have the executable file:
- open a Cygwin shell
- cd into the Debug directory
- the commands make clean and make all should work correctly producing an executable inside the Debug directory.
To simulate the application we can use directly the hardware or a "good" software debugger.