Embedded Programming: The Task Model
Embedded Programming: The Task Model
Elements of a task:
A name
Unique ID
Priority
Task control block
Stack
Task routine
Task Definition
Elements of a task:
A name
Unique ID
Priority
Task vs Function!
Task control block
Stack
Task routine
Task Definition
Note:
Few divided tasks – less loose coupling, bigger risk when changes occur.
Many tasks – may cost overhead
Task Diagrams
Loosely coupling tasks
Inter-task communication
State Machine Diagram