found a solution
void Func (Int val) { // function execute // ... }
and in the main function
Int main (void) { // System init // ... System_atexit(Func); BIOS_start(); return (0); }
in the task function, I called BIOS_exit(). it will exit BIOS
void TaskFxn(UArg arg0, Uarg arg1) { // Do some work // ... BIOS_exit(1); }
I debug step by step . after it call BIOS_exit(1), the program counter goes to Func(Int val).
Correct me if I am wrong.
The question here is, after BIOS_exit executed, There is no any tasks running? correct?