


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Main points of this exam paper are: Identical Execution Times, Effective Deadlines, Effective Release Times, Execution, Schedule Assuming, Feasibly Scheduled, Maximum Execution Time, Weighted Round-Robin, Non-Preemptive Priority-Driven, Preemptive Priority-Driven Based
Typology: Exams
1 / 4
This page cannot be seen from the preview
Don't miss anything!



Attempt THREE of four questions – 20 marks per question. ( NB: Candidates should note that marks may be lost if answers are not presented in a neat and orderly manner) ____________________________________________________ Q 1. (a) In the task graph for a set of jobs shown in Fig 1 , each job is given as Ji(ri , Di) where ri is the release time and Di is the relative deadline. The jobs are pre-emptable and have identical execution times and priorities. List the effective release times and effective deadlines of each job assuming a maximum execution time of 1. [3 marks] Fig 1: Job dependency tree with release times and deadlines. (b) Produce a feasible EDF schedule assuming each job has an execution time of 1. [4 marks] (c) What is the maximum execution time that the jobs can have and still be feasibly scheduled on a single processor? Explain your answer. [4 marks] (d) Consider the following set of jobs: Name Release Time Execution Time Priority J1 0 8 1 J2 2 5 1 J3 4 1 0 J4 6 3 2 J5 8 2 1 The times are all in ms and 0 is the highest priority. Create a schedule for the jobs using each of the following methods:
Q 4. (a) Explain the shared-data problem which occurs between the application code and the interrupt handling code of an embedded system. Fig 2 shows some C-code which is susceptible to the shared-data problem. Explain how errors can occur in this code. [4 marks] Fig 2: .Code to implement a push-button user interface and a real-time scan of tank levels using two RTOS tasks which both access the shared data array containing the tank-level data. (b) Describe in detail three distinct algorithmic methods which can offer a solution to the shared data problem. Note briefly the advantages/disadvantages of each. Illustrate your discussion with example source code where appropriate. [8 marks] (c) What are the 4 principle categories of software architecture employed in embedded systems? Explain the basic functionality of each, using code segments and diagrams, where appropriate, to illustrate your answer. Compare each of these architectures under the headings of (i) availability of priority levels, (ii) worst-case response times, (iii) stability of response with code changes and (iv) simplicity. [8 marks]