| Digital Power Starter Kit 3 Firmware dsPIC33C Boost Converter Voltage Mode Control Example |

rtos.c
1 /*
2 * File: task_execute.c
3 * Author: M91406
4 *
5 * Created on May 27, 2021, 2:44 PM
6 */
7
8
9 #include <xc.h> // include processor files - each processor file is guarded.
10 #include <stdint.h> // include standard integer data types
11 #include <stdbool.h> // include standard boolean data types
12 #include <stdlib.h> // include C standard library
13
14 #include "config/apps.h" // include applicaiton layer abstraction header file
15 #include "config/os.h" // include the operating system user configuration header file
16 #include "config/mcal.h" // include the microcontroller abstraction layer header file
17
18 #include "rtos_typedef.h" // include private data type defiitions
19 #include "boot/rtos_timer.h" // include operating system timer configuration driver header file
20
21 /*********************************************************************************
22 * @ingroup operating-system-objects
23 * @var OS_TASK_MANAGER_t task_manager
24 * @brief The task manager object provides a global scope to task list execution status
25 * @details
26 * ADD_DESCRIPTION_HERE
27 **********************************************************************************/
28 volatile struct OS_TASK_MANAGER_s task_manager;
29
30 #define OSTMR_TIMEOUT 30000 // Timeout protection for OS-Timer interrupt flag bit
31
32 /***********************************************************************************
33 * @ingroup GROUP_NAME
34 * @enum TASK_QUEUE_TYPE_e
35 * @brief ADD_SHORT_DESCRIPTION
36 * @details
37 * DETAILED_DESCRIPTION
38 ***********************************************************************************/
39 enum TASK_QUEUE_TYPE_e {
40
41 QUEUE_INITIALIZE = 0,
42 QUEUE_START = 1,
43 QUEUE_EXECUTE = 2,
44 QUEUE_STOP = 3
45
46 };
47 typedef enum TASK_QUEUE_TYPE_e TASK_QUEUE_TYPE_t;
48
49 /***********************************************************************************
50 * @ingroup GROUP_NAME
51 * @enum ENUMERATION_NAMESPACE_e
52 * @brief ADD_SHORT_DESCRIPTION
53 * @details
54 * DETAILED_DESCRIPTION
55 ***********************************************************************************/
56 enum TASK_QUEUE_EXECUTE_OPTION_e {
57
58 QUEUE_EXEC_ALL = 0,
59 QUEUE_EXEC_LP = 1,
60 QUEUE_EXEC_HP = 2
61
62 };
63 typedef enum TASK_QUEUE_EXECUTE_OPTION_e TASK_QUEUE_EXECUTE_OPTION_t;
64
65 typedef uint16_t (*FUNCPTR_t)(void); // Definition of data type of a standard function pointer
66
67 // APPLICATION LAYER PRIORITY TASK LISTS (externally defined in apps.c)
68
69 #define NO_OF_TASK_QUEUES 4
70
71 // OS Task Queue objects and their contents are declared externally by the user.
72 // These defined lists are imported here and grouped into a "List of Queues"
73 // allowing the OS to efficiently access their members
74
75 extern volatile struct APPLICATION_TASK_s* Queue_InitializeSequence[];
76 extern volatile uint16_t Queue_InitializeSequence_Size;
77
78 extern volatile struct APPLICATION_TASK_s* Queue_StartSequence[];
79 extern volatile uint16_t Queue_StartSequence_Size;
80
81 extern volatile struct APPLICATION_TASK_s* Queue_ExecuteSequence[];
82 extern volatile uint16_t Queue_ExecuteSequence_Size;
83
84 extern volatile struct APPLICATION_TASK_s* Queue_StopSequence[];
85 extern volatile uint16_t Queue_StopSequence_Size;
86
87 // The "List of Queues" is organizing the data of all user tasks for
88 // theOS to be processed efficiently in the task execution function
89 static volatile struct APPLICATION_TASK_s** exec_queues[] = {
90 (volatile struct APPLICATION_TASK_s**)&Queue_InitializeSequence,
91 (volatile struct APPLICATION_TASK_s**)&Queue_StartSequence,
92 (volatile struct APPLICATION_TASK_s**)&Queue_ExecuteSequence,
93 (volatile struct APPLICATION_TASK_s**)&Queue_StopSequence
94 };
95
96 // Array holding the individual sizes of the task queues
97 static volatile uint16_t* exec_queues_sizes[] = {
98 &Queue_InitializeSequence_Size,
99 &Queue_StartSequence_Size,
100 &Queue_ExecuteSequence_Size,
101 &Queue_StopSequence_Size
102 };
103
104 // Size of the "List Of Queues"
105 static volatile uint16_t exec_queues_size = (sizeof(exec_queues)/sizeof(exec_queues[0]));
106
107 // A user task is embedded in a data structure allowing to attach
108 // additional information about its type, size, execution time and
109 // an object identifier label
110 struct OS_TASK_QUEUE_s {
111 volatile struct APPLICATION_TASK_s** ptrQueue;
112 volatile enum TASK_QUEUE_TYPE_e queueType;
113 volatile uint16_t size;
114 volatile uint32_t exec_time;
115 volatile uint16_t id;
116 };
117 typedef struct OS_TASK_QUEUE_s OS_TASK_QUEUE_t;
118
119 // The "List of Queues" is wrapped into a data structure to attach
120 // additional information about the "List of Queues" such as its
121 // size
122 struct OS_TASK_QUEUES_s {
123 volatile uint16_t size;
124 volatile struct OS_TASK_QUEUE_s queues[NO_OF_TASK_QUEUES];
125 };
126 typedef struct OS_TASK_QUEUES_s OS_TASK_QUEUES_t;
127
128 // The "List of Queues" object is made available through
129 // the my_queues variable of type OS_TASK_QUEUES_s
130 static volatile struct OS_TASK_QUEUES_s os_queues;
131
132 // Private high-/low-priority code profiling auxiliary variables
133 static volatile bool LowPriorityWait = true;
134
135 // Debugging array for task execution tracking
136 #if __DEBUG
137 volatile uint16_t ptrTaskProfileArray;
138 volatile uint16_t arrTaskProfile[2][TASK_PROFILE_ARR_SIZE];
139 #endif
140
141 // Private function prototypes of task list execution functions
142 static volatile uint16_t rtos_Initialize(void);
143 static volatile uint16_t rtos_Start(void);
144 static volatile uint16_t rtos_Queue_Execute(TASK_QUEUE_TYPE_t type, TASK_QUEUE_EXECUTE_OPTION_t priority);
145 static volatile uint16_t rtos_Task_Execute(volatile FUNCPTR_t fptr, volatile int32_t* exec_loops, volatile int32_t* exec_time);
146
147 static volatile uint16_t __attribute__((always_inline))rtos_TaskExecCounter_Update(void);
148
149 /*********************************************************************************
150 * @ingroup operating-system-functions-public
151 * @fn uint16_t rtos_Stop(void)
152 * @brief Stops the execution of user tasks and halts the execution timer
153 * @return unsigned integer (0=failure, 1=success)
154 *
155 * @details
156 *
157 **********************************************************************************/
158
159 volatile uint16_t rtos_Stop(void)
160 {
161 volatile uint16_t retval=1;
162
163 // Execute function list covering user-task start-up functions
164 retval &= rtos_Queue_Execute(QUEUE_STOP, QUEUE_EXEC_ALL);
165
166 // Set SCheduler Disable bit exits the continuous main() loop
167 // forcing a CPU reset.
168 task_manager.Status.bits.disable = true;
169
170 return(retval);
171 }
172
173 /*********************************************************************************
174 * @ingroup operating-system-functions-public
175 * @fn uint16_t rtos_End(void)
176 * @brief Ends the execution of the main() loop enforcing a CPU reset.
177 * @return unsigned integer (0=failure, 1=success)
178 *
179 * @details
180 *
181 **********************************************************************************/
182
183 volatile uint16_t rtos_End(void)
184 {
185 volatile uint16_t retval=1;
186
187 // Execute function list covering user-task start-up functions
188 retval &= rtos_Queue_Execute(QUEUE_STOP, QUEUE_EXEC_ALL);
189
190 // Set SCheduler Disable bit exits the continuous main() loop
191 // forcing a CPU reset.
192 task_manager.Status.bits.disable = true;
193
194 return(retval);
195 }
196
197 /*********************************************************************************
198 * @ingroup operating-system-functions-public
199 * @fn uint16_t rtos_Execute(void)
200 * @brief Application main loop
201 * @return unsigned integer (0=failure, 1=success)
202 * @details
203 * This function replaces the common main()-loop of a C-program, which would
204 * commonly be placed in file main.c. This function will only be called once
205 * from main() and remain to be executed on the lowest CPU priority of #0.
206 * Within the main()-loop of this function, the execution of the low-priority
207 * task sequence is called, triggered by the interrupt-driven, real-time high-
208 * priority task layer function. Thus low-priority layer tasks are always called
209 * at a moment of potentially lowest CPU load, with the highest likelihood of
210 * completing the execution.
211 *
212 * Some low-priority tasks, however, might always take multiple task-manager
213 * cycles to be executed, during which period they will get frequently interrupted
214 * by high-priority tasks.
215 *
216 **********************************************************************************/
217
218 volatile uint16_t rtos_Execute(void)
219 {
220 volatile uint16_t retval = 1;
221 volatile uint16_t timeout = 0;
222
223 // Initialize User Tasks and OS Timer
224 retval &= rtos_Initialize();
225
226 // Launch RTOS scheduler
227 retval &= rtos_Start();
228
229 // Main program execution
230 while (!task_manager.Status.bits.disable) {
231
232 // wait while low-priority wait semaphore is set or a 'go' timeout occurs
233 while ((LowPriorityWait) && (timeout++ < OSTMR_TIMEOUT)); // Wait until semaphore is cleared
234
235 // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
236 // Execute non-time critical, low-priority tasks
237
238 retval &= rtos_Queue_Execute(QUEUE_EXECUTE, QUEUE_EXEC_LP);
239
240 // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
241
242 // After all code has been executed, reset counters to capture "free" CPU cycles
243 timeout = 0; // Reset timeout counter
244 LowPriorityWait = true; // Set Low-Priority Queue Wait
245 }
246
247 CPU_RESET(); // if the firmware ever ends up here, reset the CPU
248
249 return(0); // Return "false" signaling OS has exited execution
250 }
251
252 /**********************************************************************************
253 * @ingroup operating-system-functions-private
254 * @fn void _OsTimerInterrupt(void)
255 * @brief High priority, interrupt-driven task sequence execution
256 *
257 * @details
258 * This interrupt is used to call the high priority task sequence at a fixed
259 * repetition frequency (default of 10 kHz/100 us period). All tasks listed
260 * in the high priority task list will get executed one after another. The total
261 * execution time of the sequence therefore has to fit in the given repetition
262 * period to ensure reliable real-time resolution of each task of the sequence.
263 *
264 * ********************************************************************************/
265
266 void __attribute__((__interrupt__, context, no_auto_psv)) _OsTimerInterrupt(void)
267 {
268 volatile uint16_t retval=1;
269
270 // Increment execution period counter
271 task_manager.Status.bits.hp_active = true; // Set High-Priority Task Execution flag bit
272 task_manager.Timebase.Counter++; // Increment task manager OS time-base counter
273 _OSTIMER_IF = 0; // Clear the interrupt flag bit
274
275 // Update task execution counter
276 rtos_TaskExecCounter_Update(); // Increment all task execution time-base counter
277
278 // Execute high priority task queue
279 retval &= rtos_Queue_Execute(QUEUE_EXECUTE, QUEUE_EXEC_HP); // execute the high priority task queue
280
281 // Clear low-priority semaphore allowing to execute low-priority tasks
282 LowPriorityWait = false; // Clear WAIT trigger allowing execution of low priority tasks
283 // _OSTIMER_IF = 0; // Clear the interrupt flag bit
284
285 return;
286 }
287
288 /*********************************************************************************
289 * @ingroup operating-system-functions-private
290 * @fn uint16_t rtos_Initialize(void)
291 * @brief Initializes the task manager object and user-task execution lists
292 * @return unsigned integer (0=failure, 1=success)
293 *
294 * @details
295 *
296 **********************************************************************************/
297
298 static volatile uint16_t rtos_Initialize(void)
299 {
300 volatile uint16_t retval=1;
301 volatile uint16_t _i=0;
302 volatile uint16_t _j=0;
303
304 // Reset task manager status word
305 task_manager.Status.value = 0;
306
307 // Set size of "List of Queues" object
308 os_queues.size = exec_queues_size;
309
310 // Initialize all queue objects
311 for (_i=0; _i<exec_queues_size; _i++)
312 {
313 os_queues.queues[_i].ptrQueue = (volatile struct APPLICATION_TASK_s**)exec_queues[_i];
314 os_queues.queues[_i].size = *exec_queues_sizes[_i];
315 os_queues.queues[_i].queueType = _i;
316 os_queues.queues[_i].id = 100 * (os_queues.queues[_i].queueType + 1);
317 os_queues.queues[_i].exec_time = 0;
318
319 // Assign task IDs to task objects
320 for (_j=0; _j<os_queues.queues[_i].size; _j++)
321 {
322 os_queues.queues[_i].ptrQueue[_j]->TaskID =
323 ((100 * os_queues.queues[_i].ptrQueue[_j]->Settings.execClass) + _j);
324
325 os_queues.queues[_i].ptrQueue[_j]->Status.busy = false;
326 os_queues.queues[_i].ptrQueue[_j]->Status.retval = false;
327
328 }
329
330 }
331
332 // Configure Operating System Timer
333 retval &= osTimer_Initialize();
334
335 return(retval);
336 }
337
338 /*********************************************************************************
339 * @ingroup operating-system-functions-private
340 * @fn uint16_t rtos_Start(void)
341 * @brief Initializes the task manager object and user-task execution lists
342 * @return unsigned integer (0=failure, 1=success)
343 *
344 * @details
345 *
346 **********************************************************************************/
347
348 static volatile uint16_t rtos_Start(void)
349 {
350 volatile uint16_t retval=1;
351
352 // Start Operating System Timer without interrupts (no high priority execution)
353 retval &= osTimer_Enable(false, 0);
354
355 // Execute function list covering user-task initialization functions
356 retval &= rtos_Queue_Execute(QUEUE_INITIALIZE, QUEUE_EXEC_ALL);
357
358 // Execute function list covering user-task start-up functions
359 retval &= rtos_Queue_Execute(QUEUE_START, QUEUE_EXEC_ALL);
360
361 // Start Operating System Timer with interrupts (starts high priority task execution)
362 retval &= osTimer_Enable(true, _OSTIMER_PRIORITY);
363
364 return(retval);
365 }
366
367 /**********************************************************************************
368 * @ingroup operating-system-functions-private
369 * @fn uint16_t OsLowPriorityTasks_Execute(void)
370 * @brief Low priority task sequence executed after the high priority task sequence execution is complete
371 * @return unsigned integer (0=failure, 1=success)
372 *
373 * @details
374 * This function executes different task lists of which some are time
375 * critical while others are insensitive to execution time jitter. Each
376 * task list handed into this function will be executed from task #0 to
377 * task #n in ascending order. Hence, tasks with a lower list index will
378 * encounter less task execution jitter than others with a higher list
379 * index.
380 *
381 * This function can also be interrupted by the high-priority execution
382 * call, in which case the high-priority task will be executed before the
383 * previously started low-priority task sequence has completed.
384 *
385 * ********************************************************************************/
386
387 static volatile uint16_t rtos_Queue_Execute(TASK_QUEUE_TYPE_t type, TASK_QUEUE_EXECUTE_OPTION_t priority)
388 {
389 volatile uint16_t retval=1; // common return variable
390 volatile int32_t _tretval=0; // task execution time return variable
391 volatile int32_t* _tloops=0; // pointer to task execution loop counter
392
393 // Execution runtime variables
394 volatile uint16_t _i=0; // common runtime index
395 volatile uint16_t _size=0; // buffer variable holding the size of the queue
396 volatile uint16_t _ptr_offset=0; // pointer offset for calculation of the address of the most recent queue function to be executed
397 volatile uint16_t* _ptr; // function pointer to the most recent queue function
398
399 // Execution trigger variables
400 volatile bool _exec=false; // flag indicating if task is due to be executed
401 volatile int32_t _tdiff=0; // execution time difference buffer variable
402
403 DBGPIN2_Clear();
404 Nop();
405 Nop();
406 Nop();
407 DBGPIN2_Set();
408
409 // Execute queue task
410 _size = os_queues.queues[type].size; // copy of queue size in local variable
411 _ptr_offset = sizeof(exec_queues[type]); // copy pointer address offset into local variable
412
413 // Track if all execution layers are executed
414 if (priority == QUEUE_EXEC_HP) task_manager.Status.bits.hp_active = true;
415 if (priority == QUEUE_EXEC_LP) task_manager.Status.bits.lp_active = true;
416
417 // Roll through queue executing due tasks
418 for (_i=0; _i<_size; _i++) {
419
420 // Check if task is due to be executed
421 if (priority == QUEUE_EXEC_ALL)
422 { _exec = true; }
423 else {
424 if (os_queues.queues[type].ptrQueue[_i]->Status.enabled)
425 {
426 if ((int)os_queues.queues[type].ptrQueue[_i]->Settings.execClass == (int)priority)
427 {
428 _tdiff = (os_queues.queues[type].ptrQueue[_i]->Settings.Period +
429 os_queues.queues[type].ptrQueue[_i]->Settings.Offset);
430 _exec = (bool)(os_queues.queues[type].ptrQueue[_i]->Settings.Counter >= _tdiff);
431 }
432 }
433 }
434
435 // IF task is due to be executed
436 if (_exec)
437 {
438 // Capture pointer to first function of queue
439 _ptr = (uint16_t *)&os_queues.queues[type].ptrQueue[_i]->Functions.Initialize;
440 _ptr += type; // Add queue offset to dereference correct function pointer of most recent queue
441 _tloops = &os_queues.queues[type].ptrQueue[_i]->Settings.Counter; // Capturing pointer to task counter
442
443 os_queues.queues[type].ptrQueue[_i]->Status.busy = true; // Set BUSY status
444
445 retval = rtos_Task_Execute((FUNCPTR_t)(*_ptr), _tloops, &_tretval); // Call task function, get execution time
446
447 os_queues.queues[type].ptrQueue[_i]->Status.retval = retval; // log last function result
448 os_queues.queues[type].ptrQueue[_i]->Status.busy = false; // Clear BUSY status
449
450 // Check if OS timer has overflown
451 if (_OSTIMER_IF) {
452 task_manager.Timebase.Counter += _OSTIMER_IF;
453 rtos_TaskExecCounter_Update(); // Increment all task execution time-base counter
454 }
455
456 // Set up task counter for next execution
457 _tdiff = os_queues.queues[type].ptrQueue[_i]->Settings.Counter;
458 _tdiff -= os_queues.queues[type].ptrQueue[_i]->Settings.Offset;
459 _tdiff -= os_queues.queues[type].ptrQueue[_i]->Settings.Period;
460 _tdiff += os_queues.queues[type].ptrQueue[_i]->Settings.Offset;
461 os_queues.queues[type].ptrQueue[_i]->Settings.Counter = _tdiff; // Set execution counter
462
463 }
464 }
465
466 DBGPIN2_Clear();
467
468 // Return result (0=failure, 1=success)
469 return(retval);
470 }
471
472 /*********************************************************************************
473 * @ingroup operating-system-functions-private
474 * @fn uint16_t rtos_Task_Execute(volatile FUNCPTR_t fptr, volatile int32_t* exec_time)
475 * @brief Executes a single task of the most recent task queue measuring its execution time
476 * @param fptr: Function pointer to task function
477 * @param exec_time: Pointer to external task execution time variable of type unsigned long integer
478 * @return unsigned integer (0=failure, 1=success)
479 * @details
480 * ADD_DESCRIPTION_HERE
481 *
482 *
483 **********************************************************************************/
484
485 static volatile uint16_t rtos_Task_Execute(volatile FUNCPTR_t fptr, volatile int32_t* exec_loops, volatile int32_t* exec_time)
486 {
487 volatile uint16_t retval=1;
488
489 // Auxiliary variables for execution time calculation
490 volatile uint16_t _start=0, _stop=0;
491 volatile uint32_t _pre_loop_cnt=0, _loops=0;
492 volatile uint32_t _texec=0;
493
494 if(fptr == NULL){ // If function pointer is invalid, return failure
495 *exec_time = 0; // Clear execution time
496 return(0); // Return failure value = 0 indicating unsuccessful action
497 }
498
499 // Capture effective execution time of task queue
500 // by capturing timer period counter register value
501 _pre_loop_cnt = *exec_loops; // capture loop counter value
502 _start = _OSTIMER_TMRCAP; // capture time-base count
503
504 // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
505
506 retval &= fptr(); // Execute queue function
507
508 // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
509
510 // Capture effective execution time of task sequence
511 // by capturing timer period counter register value
512 _stop = _OSTIMER_TMRCAP;
513 _loops = (*exec_loops - _pre_loop_cnt); // capture number of execution cycles
514
515 // Calculate effective execution time of low priority task sequence
516 switch(_loops)
517 {
518 case 0: // Timer has not overflown during task list execution
519 _texec = (uint32_t)(_stop - _start);
520 break;
521
522 case 1: // Timer has overflown once during task list execution
523 _texec = (uint32_t)(MAIN_EXEC_PER - _start);
524 _texec += (uint32_t)_stop;
525 break;
526
527 default: // Timer has overflown multiple times during task list execution
528 _texec = __builtin_muluu(_loops, MAIN_EXEC_PER);
529 _texec -= (uint32_t)(MAIN_EXEC_PER - _start);
530 _texec += (uint32_t)_stop;
531 break;
532 }
533
534 // Copy measured execution time to function parameter "exec_time"
535 *exec_time = _texec;
536
537 // Return function result success=1, failure=0
538 return(retval);
539
540 }
541
542 /*********************************************************************************
543 * @ingroup operating-system-functions-private
544 * @fn uint16_t rtos_TaskExecCounter_Update(void)
545 * @brief ADD_SHORT_DESCRIPTION
546 * @return unsigned integer (0=failure, 1=success)
547 * @details
548 * ADD_DESCRIPTION_HERE
549 *
550 **********************************************************************************/
551
552 static volatile uint16_t rtos_TaskExecCounter_Update(void)
553 {
554 volatile uint16_t retval=1;
555 volatile uint16_t _i=0;
556 volatile uint16_t _toff=0;
557
558 // Capture most recent time base counter to prevent drift across tasks
559 _toff = task_manager.Timebase.Counter;
560
561 // Increment all task execution counters
562 for (_i=0; _i<Queue_ExecuteSequence_Size; _i++) {
563 Queue_ExecuteSequence[_i]->Settings.Counter += _toff;
564 }
565
566 // Reset common time base counter
567 task_manager.Timebase.Counter = 0; // Clear the task scheduler tick counter
568 _OSTIMER_IF = 0; // Clear Timer interrupt flag bit
569
570 return(retval);
571 }
572
573 // end of file
APPLICATION_TASK_s::Settings
volatile struct APPTASK_EXECUTION_s Settings
Execution time settings of the task object.
Definition: apptask_typedef.h:152
OS_TASKMGR_STATUS_s::disable
unsigned disable
When set, causes the execution of main() to be terminated resulting in a CPU reset.
Definition: rtos_typedef.h:67
OS_TASKMGR_STATUS_s::hp_active
unsigned hp_active
Bit 1: Flag indicating that low-priority task queue is executed frequently.
Definition: rtos_typedef.h:52
OS_TASK_MANAGER_s::Timebase
volatile struct OS_TASKMGR_TIMEBASE_s Timebase
Task manager time base monitor.
Definition: rtos_typedef.h:114
_OSTIMER_TMRCAP
#define _OSTIMER_TMRCAP
Timer period counter register.
Definition: dspic33c_mcal.h:175
OS_TASKMGR_TIMEBASE_s::Counter
volatile int32_t Counter
Operating system task execution tick counter.
Definition: rtos_typedef.h:84
OS_TASKMGR_STATUS_s::lp_active
unsigned lp_active
Bit 0: Flag indicating that high-priority task queue is executed frequently.
Definition: rtos_typedef.h:51
_OSTIMER_IF
#define _OSTIMER_IF
interrupt flag bit
Definition: dpsk3_hwdescr.h:177
OS_TASK_MANAGER_s::Status
volatile struct OS_TASKMGR_STATUS_s Status
Task manager status word.
Definition: rtos_typedef.h:113
_OSTIMER_PRIORITY
#define _OSTIMER_PRIORITY
interrupt priority (1 ... 7, default = 2)
Definition: dpsk3_hwdescr.h:178
OS_TASK_MANAGER_s
Definition: rtos_typedef.h:112
APPLICATION_TASK_s
DESCRIPTION.
Definition: apptask_typedef.h:149
APPTASK_EXECUTION_s::Counter
volatile int32_t Counter
Execution period counter (read only)
Definition: apptask_typedef.h:97
_OsTimerInterrupt
#define _OsTimerInterrupt
Global state-machine peripheral assignments.
Definition: dpsk3_hwdescr.h:174
OS_TASKMGR_STATUS_s::value
volatile uint16_t value
Status word value.
Definition: rtos_typedef.h:69
MAIN_EXEC_PER
#define MAIN_EXEC_PER
Global state-machine user-settings conversion macros.
Definition: dpsk3_hwdescr.h:160