Unit - I Real Time Operating System. Content : Operating System Concepts Real-Time Tasks Real-Time Systems Types of Real-Time Tasks Real-Time Operating.

Slides:



Advertisements
Similar presentations
Processes and Threads Chapter 3 and 4 Operating Systems: Internals and Design Principles, 6/E William Stallings Patricia Roy Manatee Community College,
Advertisements

Chorus and other Microkernels Presented by: Jonathan Tanner and Brian Doyle Articles By: Jon Udell Peter D. Varhol Dick Pountain.
Computer Systems/Operating Systems - Class 8
Review: Chapters 1 – Chapter 1: OS is a layer between user and hardware to make life easier for user and use hardware efficiently Control program.
Operating Systems High Level View Chapter 1,2. Who is the User? End Users Application Programmers System Programmers Administrators.
CS 3013 & CS 502 Summer 2006 Scheduling1 The art and science of allocating the CPU and other resources to processes.
I/O Hardware n Incredible variety of I/O devices n Common concepts: – Port – connection point to the computer – Bus (daisy chain or shared direct access)
Embedded Real-time Systems The Linux kernel. The Operating System Kernel Resident in memory, privileged mode System calls offer general purpose services.
Cs238 CPU Scheduling Dr. Alan R. Davis. CPU Scheduling The objective of multiprogramming is to have some process running at all times, to maximize CPU.
1/28/2004CSCI 315 Operating Systems Design1 Operating System Structures & Processes Notice: The slides for this lecture have been largely based on those.
Figure 1.1 Interaction between applications and the operating system.
Real-Time Kernels and Operating Systems. Operating System: Software that coordinates multiple tasks in processor, including peripheral interfacing Types.
Wk 2 – Scheduling 1 CS502 Spring 2006 Scheduling The art and science of allocating the CPU and other resources to processes.
By Group: Ghassan Abdo Rayyashi Anas to’meh Supervised by Dr. Lo’ai Tawalbeh.
Real-Time Operating System Chapter – 8 Embedded System: An integrated approach.
Operating System Organization
Slide 3-1 Copyright © 2004 Pearson Education, Inc. Operating Systems: A Modern Perspective, Chapter 3 Operating System Organization.
Chapter 13: I/O Systems I/O Hardware Application I/O Interface
General What is an OS? What do you get when you buy an OS? What does the OS do? What are the parts of an OS? What is the kernel? What is a device.
1 Previous lecture review n Out of basic scheduling techniques none is a clear winner: u FCFS - simple but unfair u RR - more overhead than FCFS may not.
Introduction to Embedded Systems Rabie A. Ramadan 6.
Real-Time Scheduling CS4730 Fall 2010 Dr. José M. Garrido Department of Computer Science and Information Systems Kennesaw State University.
Real-Time Operating Systems for Embedded Computing 李姿宜 R ,06,10.
Multiprocessor and Real-Time Scheduling Chapter 10.
Lecture 3 Process Concepts. What is a Process? A process is the dynamic execution context of an executing program. Several processes may run concurrently,
Real-Time Systems Mark Stanovich. Introduction System with timing constraints (e.g., deadlines) What makes a real-time system different? – Meeting timing.
Cpr E 308 Spring 2004 Real-time Scheduling Provide time guarantees Upper bound on response times –Programmer’s job! –Every level of the system Soft versus.
Computers Operating System Essentials. Operating Systems PROGRAM HARDWARE OPERATING SYSTEM.
© 2000 Morgan Kaufman Overheads for Computers as Components Processes and operating systems Operating systems. 1.
1 Threads, SMP, and Microkernels Chapter Multithreading Operating system supports multiple threads of execution within a single process MS-DOS.
Real Time Operating Systems Michael Thomas Date: Rev. 1.00Date.
1 VxWorks 5.4 Group A3: Wafa’ Jaffal Kathryn Bean.
Review for Quiz-2 Applied Operating System Concepts Chap.s 1,2,6,7 - ECE3055b, Spring 2005.
Real time scheduling G.Anuradha Ref:- Stallings. Real time computing Correctness of the system depends not only on the logical result of computation,
CSCI1600: Embedded and Real Time Software Lecture 23: Real Time Scheduling I Steven Reiss, Fall 2015.
Chapter 19: Real-Time Systems Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 19: Real-Time Systems System Characteristics.
What is an Operating System? Various systems and their pros and cons –E.g. multi-tasking vs. Batch OS definitions –Resource allocator –Control program.
For a good summary, visit:
Slides created by: Professor Ian G. Harris Operating Systems  Allow the processor to perform several tasks at virtually the same time Ex. Web Controlled.
Silberschatz, Galvin, and Gagne  Applied Operating System Concepts Module 12: I/O Systems I/O hardwared Application I/O Interface Kernel I/O.
1.  System Characteristics  Features of Real-Time Systems  Implementing Real-Time Operating Systems  Real-Time CPU Scheduling  An Example: VxWorks5.x.
Undergraduate course on Real-time Systems Linköping University TDDD07 Real-time Systems Lecture 2: Scheduling II Simin Nadjm-Tehrani Real-time Systems.
Where Testing Fails …. Problem Areas Stack Overflow Race Conditions Deadlock Timing Reentrancy.
1.3 Operating system services An operating system provide services to programs and to the users of the program. It provides an environment for the execution.
1 Module 3: Processes Reading: Chapter Next Module: –Inter-process Communication –Process Scheduling –Reading: Chapter 4.5, 6.1 – 6.3.
CONCEPTS OF REAL-TIME OPERATING SYSTEM. OBJECTIVE  To Understand Why we need OS?  To identify Types of OS  To Define Real - Time Systems  To Classify.
Real-Time Operating Systems RTOS For Embedded systems.
 Operating system.  Functions and components of OS.  Types of OS.  Process and a program.  Real time operating system (RTOS).
Computer System Structures
Embedded System Scheduling
Chapter 13: I/O Systems.
REAL-TIME OPERATING SYSTEMS
Kernel Design & Implementation
Module 12: I/O Systems I/O hardware Application I/O Interface
EEE Embedded Systems Design Process in Operating Systems 서강대학교 전자공학과
Topics Covered What is Real Time Operating System (RTOS)
Applied Operating System Concepts -
Networks and Operating Systems: Exercise Session 2
Unit OS9: Real-Time and Embedded Systems
Chapter 2 Scheduling.
KERNEL ARCHITECTURE.
Operating System Concepts
13: I/O Systems I/O hardwared Application I/O Interface
CS703 - Advanced Operating Systems
Mid Term review CSC345.
February 5, 2004 Adrienne Noble
Chapter 13: I/O Systems I/O Hardware Application I/O Interface
Operating Systems: A Modern Perspective, Chapter 3
Operating System Introduction.
Module 12: I/O Systems I/O hardwared Application I/O Interface
Presentation transcript:

Unit - I Real Time Operating System

Content : Operating System Concepts Real-Time Tasks Real-Time Systems Types of Real-Time Tasks Real-Time Operating Systems

Operating System Concepts : Component of an Operating System : Processor Management Memory Management Primary Secondary Cache Virtual File Management I/O Management Multiprogramming Protection and Security Network Management

Kernel Architecture (UNIX) : Library hardware File Subsystem character block Hardware control Buffer Cache system call interface Device driver Inter process communication Scheduler Memory Management Process Control Subsystem User program User level kernel level User level kernel level

Monolithic Kernel : User Mode Kernel Mode

Micro Kernel : User Mode Kernel Mode

Hybrid Kernel : User Mode Kernel Mode

Types of kernel : Monolithic Kernel One single program that contains all of the code performing kernel operations. Less software involved hence faster execution. Less code generally means less bugs. Single error need recompilation of whole kernel functionalities. Microkernel Only core kernel functionalities are together all other functions of are written in modules. Maintenance is generally easier. Rapid development time as new addition doesn’t need to disrupt kernel.

Operating System Concepts : Process States New Ready Running Blocked Exit Process Control Block PID State Register status Scheduling information Pointers to memory I/O resource information Multitasking CPU and IO Bound Tasks Scheduling Algorithms

Operating System Concepts : Threads Common address space Individual stack and registers Interrupt Handling Save current context Determine identity of interrupt Switch to new context Start execution of interrupt Inter-Process Communication Shared Memory Message Passing Semaphores Message Pipes Transfer Protocol Blocking Sender, Blocking Receiver Non-blocking sender, Blocking Receiver Remote Procedure Call Interrupt Latency

Operating System Concepts : Critical Section Race Condition Producer Consumer Reader Writer Problems Deadlock Necessary conditions Prevention Avoidance Detect and Recover

Real-Time Tasks Time constrained tasks Useful only if output generated within deadline Terms: Release/Ready Time Scheduling Time Completion Time Burst/Run Time Deadline Tardiness: When completion time > deadline Completion time - Deadline Laxity: Time the task can wait without missing deadline Deadline – Completion time

Types of Real-Time Tasks : Hard Real-time task Must condition C <= D Air traffic control Vehicle subsystems control Nuclear power plant control Soft Real-time Task If C > D then penalty is associated with delay in results. Multimedia transmission and reception Networking, telecom/cellular networks Web sites and services Computer games Firm Real Task

Real-Time Systems : Periodic Task Executes regularly after fixed intervals Aperiodic Task Jobs arriving at irregular intervals Soft deadlines have time constraints either for deadlines or start Sporadic Task Aperiodic tasks with hard deadlines Pre-emptible Non-preemptible Tasks

Real-Time Operating Systems : Simpler embedded systems use superloop-based approach. Complex embedded systems require dedicated OS Smart phones Abstraction layer between hardware and application layer. Task management Inter Task Communication and Synchronization Dynamic Memory Allocation Device I/O supervisor Timers

Real-Time Scheduling : Off-Line Scheduling / Pre-Run Time Scheduling : Total tasks, Deadlines, Release time, Execution time all must be known Inflexible Optimal for systems where jobs are fixed. Online Scheduling : Static Priority Preemptive Non-preemptive Dynamic Priority Priority can be changed at runtime Planning Based Best Effort

Classes of Real-Time Scheduling Algorithms Static Priority Non- Preemptive Preemptive Dynamic planning-based Feasibility determined at run time Guarantees execution of accepted tasks Dynamic best effort No feasibility analysis is performed. All hard real time tasks’ deadlines are met. Aborts any started process whose deadline is missed.

Rate Monotonic Scheduling: Assigns priorities to tasks on the basis of their time periods Highest-priority task is the one with the shortest period Sufficient but not necessary condition Static Priority with preemption C i / P i ≤ n(2 1/n - 1) Task SizeBound

Earliest Deadline First : Dynamic Priority Allocation Priority changes at runtime Highest priority to task with nearest deadline Can be used for tasks where RM fails. Overhead for implementation.

Two Tasks

Periodic Scheduling

Problem: Static Priority TasksPriorityPeriodCPU Burst T1172 T22174 T33248 Draw the Gantt-chart for scheduling these tasks. Assume the all jobs have same release time Schedule the process to meet their deadline Without Pre-emption With Pre-emption Note: Deadline of task is the time when its next burst arrive

Example CPU utilization for the set of task: LHS : 2/7 + 4/17 + 8/24 = RHS : = 3 X (2 1/3 -1)= 3 x.26 =.78 LHS> RHS :RM does not get satisfied But the task still might get schedulable by RM technique TasksPeriod (T)CPU Burst(C) T172 T2174 T3248

Problem 1 TasksPeriod (P or T)CPU Burst(C) T1154 T2122 T3205 Find out whether above problem is solvable using Rate Monotonic Scheduling.

Problem 2 TasksPeriodCPU BurstRelease Time T1310 T21031 T31543 Find out whether above problem is solvable using Rate Monotonic Scheduling.

Example TasksPeriodCPU Bursts T141 T262 T394 Solve using Rate Monotonic EDF

Example TasksPeriodCPU Bursts T1105 T2122 T3153 T4246 Is it possible to solve above set of tasks using EDF

Qualities of good RTOS Performance: Must be capable of meeting the requirements of application Reliability: System should not fail. “Mean Time between Failure” should be very high. Compactness: Size of RTOS should be as small as possible. (Ported to embedded systems mostly with limited memory) Scalability: Modularity in OS design. Can be scaled up or down.