#include "config.h"
#include "conf/conf_scheduler.h"
#include "scheduler.h"
Go to the source code of this file.
Defines | |
#define | _SCHEDULER_C_ |
_____ I N C L U D E S ____________________________________________________ | |
Functions | |
void | scheduler_init (void) |
_____ D E C L A R A T I O N ______________________________________________ Scheduler initialization | |
void | scheduler_tasks (void) |
Task execution scheduler. | |
void | scheduler (void) |
Init & run the scheduler. | |
void | scheduler_empty_fct (void) |
Do nothing Avoid uncalled segment warning if the empty function is not used. | |
Variables | |
bit | scheduler_tick_flag |
_____ M A C R O S ________________________________________________________ _____ D E F I N I T I O N ________________________________________________ |
Supported devices: AT90USB162, AT90USB82
Definition in file scheduler.c.
#define _SCHEDULER_C_ |
_____ I N C L U D E S ____________________________________________________
Definition at line 49 of file scheduler.c.
void scheduler_init | ( | void | ) |
_____ D E C L A R A T I O N ______________________________________________ Scheduler initialization
_____ D E C L A R A T I O N ______________________________________________
Task_x_init() and Task_x_fct() are defined in config.h
:none |
Definition at line 80 of file scheduler.c.
Referenced by scheduler().
00081 { 00082 #ifdef Scheduler_time_init 00083 Scheduler_time_init(); 00084 #endif 00085 #ifdef TOKEN_MODE 00086 token = TOKEN_FREE; 00087 #endif 00088 #ifdef Scheduler_task_1_init 00089 Scheduler_task_1_init(); 00090 Scheduler_call_next_init(); 00091 #endif 00092 #ifdef Scheduler_task_2_init 00093 Scheduler_task_2_init(); 00094 Scheduler_call_next_init(); 00095 #endif 00096 #ifdef Scheduler_task_3_init 00097 Scheduler_task_3_init(); 00098 Scheduler_call_next_init(); 00099 #endif 00100 #ifdef Scheduler_task_4_init 00101 Scheduler_task_4_init(); 00102 Scheduler_call_next_init(); 00103 #endif 00104 #ifdef Scheduler_task_5_init 00105 Scheduler_task_5_init(); 00106 Scheduler_call_next_init(); 00107 #endif 00108 #ifdef Scheduler_task_6_init 00109 Scheduler_task_6_init(); 00110 Scheduler_call_next_init(); 00111 #endif 00112 #ifdef Scheduler_task_7_init 00113 Scheduler_task_7_init(); 00114 Scheduler_call_next_init(); 00115 #endif 00116 #ifdef Scheduler_task_8_init 00117 Scheduler_task_8_init(); 00118 Scheduler_call_next_init(); 00119 #endif 00120 #ifdef Scheduler_task_9_init 00121 Scheduler_task_9_init(); 00122 Scheduler_call_next_init(); 00123 #endif 00124 #ifdef Scheduler_task_10_init 00125 Scheduler_task_10_init(); 00126 Scheduler_call_next_init(); 00127 #endif 00128 #ifdef Scheduler_task_11_init 00129 Scheduler_task_11_init(); 00130 Scheduler_call_next_init(); 00131 #endif 00132 Scheduler_reset_tick_flag(); 00133 }
void scheduler_tasks | ( | void | ) |
Task execution scheduler.
:none |
Definition at line 141 of file scheduler.c.
Referenced by scheduler().
00142 { 00143 // To avoid uncalled segment warning if the empty function is not used 00144 scheduler_empty_fct(); 00145 00146 for(;;) 00147 { 00148 Scheduler_new_schedule(); 00149 #ifdef Scheduler_task_1 00150 Scheduler_task_1(); 00151 Scheduler_call_next_task(); 00152 #endif 00153 #ifdef Scheduler_task_2 00154 Scheduler_task_2(); 00155 Scheduler_call_next_task(); 00156 #endif 00157 #ifdef Scheduler_task_3 00158 Scheduler_task_3(); 00159 Scheduler_call_next_task(); 00160 #endif 00161 #ifdef Scheduler_task_4 00162 Scheduler_task_4(); 00163 Scheduler_call_next_task(); 00164 #endif 00165 #ifdef Scheduler_task_5 00166 Scheduler_task_5(); 00167 Scheduler_call_next_task(); 00168 #endif 00169 #ifdef Scheduler_task_6 00170 Scheduler_task_6(); 00171 Scheduler_call_next_task(); 00172 #endif 00173 #ifdef Scheduler_task_7 00174 Scheduler_task_7(); 00175 Scheduler_call_next_task(); 00176 #endif 00177 #ifdef Scheduler_task_8 00178 Scheduler_task_8(); 00179 Scheduler_call_next_task(); 00180 #endif 00181 #ifdef Scheduler_task_9 00182 Scheduler_task_9(); 00183 Scheduler_call_next_task(); 00184 #endif 00185 #ifdef Scheduler_task_10 00186 Scheduler_task_10(); 00187 Scheduler_call_next_task(); 00188 #endif 00189 #ifdef Scheduler_task_11 00190 Scheduler_task_11(); 00191 Scheduler_call_next_task(); 00192 #endif 00193 } 00194 }
void scheduler | ( | void | ) |
Init & run the scheduler.
:none |
Definition at line 202 of file scheduler.c.
Referenced by main().
00203 { 00204 scheduler_init(); 00205 scheduler_tasks(); 00206 }
void scheduler_empty_fct | ( | void | ) |
Do nothing Avoid uncalled segment warning if the empty function is not used.
:none |
Definition at line 216 of file scheduler.c.
Referenced by scheduler_tasks().
_____ M A C R O S ________________________________________________________ _____ D E F I N I T I O N ________________________________________________
_____ D E F I N I T I O N ________________________________________________
When SCHEDULER_TYPE != SCHEDULER_FREE, this flag control task calls.
Definition at line 59 of file scheduler.c.