Exercise 4 - Introduction To Embedded Systems
Exercise 4 - Introduction To Embedded Systems
Task 1: Earliest Deadline First (EDF) and Total Bandwidth Server (TBS)
τ1 τ2 τ3
Ci 1 1 2
Ti 3 5 13
A Total Bandwidth Server (TBS) executes along with the periodic tasks above.
1. What can be the maximum value of Us such that the whole set (i.e., periodic tasks and the TBS) is
schedulable with EDF?
2. Now assume Us = 0.25. Construct the EDF schedule (in Figure 1) in the case in which three aperiodic
requests J4 (r4 = 0, C4 = 2), J5 (r5 = 15, C5 = 1) and J6 (r6 = 10, C6 = 1) are served by TBS. Assume
that the arrival time of the first instance/job of each periodic task is 0.
τ1
τ2
τ3
J4
J5
J6
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
Time
1
Task 2: Schedulability Test for Fixed Priorities – Rate Monotonic (RM)
τ1 τ2 τ3
Ci 1 3 2
Ti 3 8 9
1. Test if the given task-set is schedulable under RM, using the sufficient test.
2. Test if the given task-set is schedulable under RM, using the necessary test.
3. Assume that the first job of each task arrives at time 0. Construct the schedule for the interval [0, 20]
and illustrate it graphically. In case they exist, identify deadline misses.
τ1 τ2 τ3
Ci 2 2 2
Di 6 8 16
Ti 6 8 16
In addition to the above periodic tasks, we have an aperiodic job Ja with computation time Ca = 1, and
relative deadline Da . The scheduling policy is RM. The aperiodic job is scheduled through a Polling Server
(PS).
1. Let the period and computing time of the polling server be Ts = 25 and Cs = 1, respectively. Compute
the aperiodic guarantee available to Ja , i.e., compute the minimum relative deadline of Ja which is
guaranteed not to be missed.
2. Using the sufficient test of RM, test if the polling server of (a) is schedulable along with the periodic
task-set?
3. [optional] Determine integer parameters (Cs , Ts ) of the polling server such that (1) the relative deadline
guaranteed to Ja is minimised, and (2) the RM schedule satisfies the sufficient schedulability test.
4. [optional] For the optimal setting of (c) devise a necessary schedulability test with the relative deadline
of the aperiodic task Da = 32.
The two optional subquestions of Task 3 and the remaining tasks below are meant for additional
practice and will not be discussed in the exercise session. Solutions will be provided online, as usual.
τ1 τ2 τ3
Ci 1 2 3
Di 5 4 8
Ti 5 6 10
1. Check the schedulability of the task set using the Deadline Monotonic (DM) policy.
2. Construct the schedule graphically. Let the phase Φi = 0 ∀i. In case they exist, identify deadline misses.
2
Task 5: Mixed Tasks – Polling Server
Two periodic tasks are given, with execution times and periods given in the following table (deadlines equal
periods). The phase of the periodic tasks is assumed to be Φi = 0 ∀i. The given set of tasks should be
scheduled with the Rate Monotonic scheduling scheme.
τ1 τ2
Ci 1 2
Ti 5 8
Construct a schedule graphically for following aperiodic requests (a Polling Server with integer parameters
should be introduced). The CPU utilization has to be maximized.
J1 J2 J3
ai 2 7 9
Ci 3 2 1
We have to design a system that schedules periodic tasks with EDF and employs a total bandwidth server to
serve aperiodic requests. We know of one sporadic aperiodic request with computation time Ca = 2 and a
relative deadline Da = 7. What is the maximum processor utilization available for periodic tasks if we want
to guarantee that this aperiodic task completes within its deadline?
A processor is supposed to execute the following set of tasks described by their execution times C, relative
deadlines D and periods T .
τ1 τ2 τ3
Ci 2 2 4
Di 5 4 8
Ti 6 8 12
1. Execute the sufficient schedulability test under DM and calculate the result. What statement regarding
schedulability can be made based on your result?
2. Execute the sufficient and necessary schedulability test under DM and calculate the result. What
statement regarding schedulability can be made based on your result?
3. If there is a feasible schedule for the given task set, construct it graphically. Let the phase Φi = 0 ∀i.