The Second Engineering Conference of Control, Computers and Mechatronics Engineering (ECCCM2, 2014) Educational Software Package on Scheduling Algorithms for Real Time Control Applications Safanah Raafat Automation & Robotics Research Unit, Control and System Eng. Dept, University of Technology Baghdad Iraq s.m.raafat@ieee.org Sarah K. Ibrahim Control and System Eng. Dept. University of Technology Baghdad Iraq Sarah.khalil88@yahoo.com Sarah S. Mahmood Control and System Eng. Dept. University of Technology Baghdad Iraq Sarah8834@yahoo.com AbstractThe vital aim of the real time system implementation is to catalyze development in the application of real-time systems engineering, specifically by increasing the use of scheduling algorithms. In this paper, we implement some of the most important decisions strategies in order to build an educational package for final year undergraduate students studying real time control engineering and/or master students taking subject of real time control engineering. In this package, the students will be introduced to the essential concepts of the development of real time control system; starting from providing the linear or nonlinear model that describe a control system (an AC servo motor is considered here as an example), selecting proper sampling rate , design of conventional controller like a PID, ending up with determination of the execution time and the application of scheduling algorithms like (Rate Monotonic- Scheduling (RMS) and Earliest Dead line First (EDF))for multitasking operation. In order to develop the required algorithms the students will be introduced to some useful advanced MATLAB/Simulink functions like S function and state flow diagram. Index Termsreal-time system, scheduling algorithm, AC servo motor, multitasking operation, Rate Monotonic Scheduling (RMS), Earliest Dead line First (EDF), PID. I. INTRODUCTION In the last two decades, we have witnessed an explosive growth of real-time and embedded systems being used in our daily life. Current applications of computers in control, multimedia, signal processing, communications, etc. set very hard timing demands on real-time systems. Regardless of the high computing power, tasks that are executed by those computers need to be scheduled in such a way that they have better requested timing properties and utilization. Real-time scheduling deals with the above-mentioned problem. Recently, many research work on real time scheduling have been recognized; in [1], parallel-machine scheduling problem was described for electronic manufacturing industry considering past-sequence dependent (psd) delivery times and learning effect to obtain an optimal solution. A pseudo- polynomial algorithm is developed in [2] for the case of scheduling with a fixed number of UIs (time intervals during which the machine is not allowed to process jobs). The scheduling problem of an important class of large-scale Grid applications was addressed in [3]. It characterized by a huge number of homogeneous, concurrent, and computationally intensive tasks which are the main sources of performance, cost, and storage bottlenecks. A new formulation had been proposed in [3] of this problem based on a cooperative distributed game-theory-based method. For flight scheduling which is a real-time optimization problem, [4] presents a description of the problem in which the total delay minutes of passengers are considered as the optimization objective and which takes into account available resources and the estimated cost of airlines. Its known that a real-time control system is a system in which the resulting performance depends not only on the correctness of the single control actions but also on the time at which the actions are produced. The operating system is the major architectural component responsible for ensuring a timely execution of all the tasks having some timing requirements. In the presence of several concurrent activities running on a single processor, the objective of a real-time kernel is to ensure that each activity completes its execution within its deadline. Notice that this is very different than minimizing the average response times of a set of tasks [5]. Depending on the consequences caused by a missed deadline, real-time activities can be classified into hard and soft tasks. A real-time task is said to be hard if missing a deadline may have catastrophic consequences on the controlled system, and is said to be soft if missing a deadline causes performance degradation but does not jeopardize the correct system behavior [6]. Most of the control activities, such as signal acquisition, filtering, sensory data processing, action planning, and actuator control, are typically implemented as periodic tasks activated at specific rates imposed by the application requirements. When a set T of n periodic tasks has to be concurrently executed on the same processor, the problem is to verify whether all tasks can complete their execution within their timing constraints. There are several approaches dedicated to handle this problem like classical cyclic scheduling approach, a fixed priority-based scheduler, rate monotonic scheduling (RMS), and earliest deadline first (EDF) algorithms [5].