Overall Structure of RT Systems

Similar documents
What s an Operating System? Real-Time Operating Systems. Cyclic Executive. Do I Need One? Handling an Interrupt. Interrupts

Real-Time Programming

Introduction to Real-time Systems. Advanced Operating Systems (M) Lecture 2

EECS 571 Principles of Real-Time Embedded Systems. Lecture Note #10: More on Scheduling and Introduction of Real-Time OS

Today s topic: Real Time Programming with Ada

Real-Time Systems 1. Basic Concepts

What are Embedded Systems? Lecture 1 Introduction to Embedded Systems & Software

Syllabus Instructors:

CEC 450 Real-Time Systems

A Predictable RTOS. Mantis Cheng Department of Computer Science University of Victoria

Today: I/O Systems. Architecture of I/O Systems

Commercial Real-time Operating Systems An Introduction. Swaminathan Sivasubramanian Dependable Computing & Networking Laboratory

Real Time Operating Systems and Middleware

TDDD07 Real-time Systems Lecture 10: Wrapping up & Real-time operating systems

IN4343 Real-Time Systems

Time Triggered and Event Triggered; Off-line Scheduling

Department of Computer Science Institute for System Architecture, Operating Systems Group REAL-TIME MICHAEL ROITZSCH OVERVIEW

Implementing Scheduling Algorithms. Real-Time and Embedded Systems (M) Lecture 9

DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING UNIT-1

Pattern-Based Analysis of an Embedded Real-Time System Architecture

Embedded Systems. 6. Real-Time Operating Systems

SE300 SWE Practices. Lecture 10 Introduction to Event- Driven Architectures. Tuesday, March 17, Sam Siewert

PROBABILISTIC SCHEDULING MICHAEL ROITZSCH

Real-time Support in Operating Systems

Safety and Reliability of Software-Controlled Systems Part 14: Fault mitigation

Multicore for safety-critical embedded systems: challenges andmarch opportunities 15, / 28

Exam Review TexPoint fonts used in EMF.

SIDDHARTH GROUP OF INSTITUTIONS :: PUTTUR Siddharth Nagar, Narayanavanam Road QUESTION BANK (DESCRIPTIVE) UNIT I OPERATING SYSTEMS

Developing deterministic networking technology for railway applications using TTEthernet software-based end systems

Scheduling Mar. 19, 2018

Computer Hardware Requirements for Real-Time Applications

CEC 450 Real-Time Systems

Hardware Support for Priority Inheritance

Classification of RTS. RTS Definitions. RTS Definitions

Components & Characteristics of an Embedded System Embedded Operating System Application Areas of Embedded d Systems. Embedded System Components

Real-Time Operating Systems M. 9. Real-Time: Basic Concepts

Example Networks on chip Freescale: MPC Telematics chip

Ensuring Schedulability of Spacecraft Flight Software

Real-time HOOD. Analysis and Design of Embedded Systems and OO* Object-oriented Programming Jan Bendtsen Automation and Control

Introduction to Real-Time Systems and Multitasking. Microcomputer Architecture and Interfacing Colorado School of Mines Professor William Hoff

Main Points of the Computer Organization and System Software Module

Lecture Little s Law Flux Queueing Theory Simulation Definition. CMPSCI 691ST Systems Fall 2011

ARTIST-Relevant Research from Linköping

Reference Model and Scheduling Policies for Real-Time Systems

Module 11: I/O Systems

Programming Languages for Real-Time Systems. LS 12, TU Dortmund

RTOS overview. Basic concepts and benefits

Administrative Stuff. We are now in week 11 No class on Thursday About one month to go. Spend your time wisely Make any major decisions w/ Client

Concurrent activities in daily life. Real world exposed programs. Scheduling of programs. Tasks in engine system. Engine system

Operating Systems : Overview

Embedded Systems. Octav Chipara. Thursday, September 13, 12

Exam TI2720-C/TI2725-C Embedded Software

Real-Time Component Software. slide credits: H. Kopetz, P. Puschner

Linux Xenomai UAV Sensor platform.

Hardware/Software Co-design

SpaceCommRTOS. From a formal RTOS concept to a universal communication mechanism for distributed real-time systems

Embedded Software Engineering

CS 571 Operating Systems. Midterm Review. Angelos Stavrou, George Mason University

Embedded Systems. 5. Operating Systems. Lothar Thiele. Computer Engineering and Networks Laboratory

Operating System: Chap13 I/O Systems. National Tsing-Hua University 2016, Fall Semester

Analyzing Real-Time Systems

Lecture notes Lectures 1 through 5 (up through lecture 5 slide 63) Book Chapters 1-4

Real-Time Operating Systems. Ludovic Apvrille Eurecom, office

Investigation of System Timing Concerns in Embedded Systems: Tool-based Analysis of AADL Models

15: OS Scheduling and Buffering

Design of Real-Time Software

Systems Integration. Gautam H. Thaker Patrick J. Lardieri Donald Krecker Keith O Hara Chuck Winters

Chapter 6. Storage and Other I/O Topics

COMPLEX EMBEDDED SYSTEMS

Static Analysis of Embedded Systems

(b) External fragmentation can happen in a virtual memory paging system.

Timers 1 / 46. Jiffies. Potent and Evil Magic

Real-Time Operating Systems Design and Implementation. LS 12, TU Dortmund

[08] IO SUBSYSTEM 1. 1

即時控制系統設計 Design of Real-Time Control Systems

Caution Notes. Features. Specifications. A3-L User Manual V1.0

EMBEDDED OPERATING SYSTEMS

Final Exam Study Guide

NWI-IBC019: Operating systems

Multimedia Systems 2011/2012

Tasks. Task Implementation and management

Multiprocessor and Real-Time Scheduling. Chapter 10

Distributed IMA with TTEthernet

CPS 210: Operating Systems

Operating Systems, Fall

A Byzantine Fault-Tolerant Key-Value Store for Safety-Critical Distributed Real-Time Systems

CSI3131 Final Exam Review

CS4514 Real-Time Systems and Modeling

Understanding the Role of Real-Time Java in Aegis Warship Modernization. Dr. Kelvin Nilsen, Chief Technology Officer Java, Atego Systems

Green Hills Software, Inc.

VALLIAMMAI ENGINEERING COLLEGE

Computer Organization and Structure. Bing-Yu Chen National Taiwan University

Resource-bound process algebras for Schedulability and Performance Analysis of Real-Time and Embedded Systems

A new architecture for real-time control in RFX-mod G. Manduchi, A. Barbalace Big Physics Symposium 1/16

Real-Time Technology in Linux

ECE 612: Embedded and Real-Time Systems

Operating Systems. Introduction & Overview. Outline for today s lecture. Administrivia. ITS 225: Operating Systems. Lecture 1

Storage. Hwansoo Han

Midterm Exam. October 20th, Thursday NSC

Copyright Notice. COMP9242 Advanced Operating Systems S2/2014 Week 9: Real-Time Systems. Real-Time System: Definition

Transcription:

Course Outline Introduction Characteristics of RTS Real Time Operating Systems (RTOS) OS support: scheduling, resource handling Real Time Programming Languages Language support, e.g. Ada tasking Scheduling and Timing Analysis of RT Software Worst-case execution and response time analysis Design and Validation Modeling, Verification and Testing Reliability and Fault-Tolerance Fault tolerant, failure recovery, exception handling Distributed real time systems Real Time Communication: CAN Bus 1 Overall Structure of RT Systems Hardware (CPU, I/O device etc) a clock! A real time OS (function as standard OS, with predictable behavior and well-defined functionality) A collection of RT tasks/processes (share resourses, communicate/synchronize with each other and the environment) 2 1

Components of RT Systems Other Computers Actuators Comm. Network Real Time Software RTOS e.g. Cars, trains Sensors Task Task Task Physical World 3 General-Purpose vs. Embedded RT Computer Systems User Programs/application Operating Control Tasks and Operating System Hardware Hardware System General-purpose computer systems Typical Embedded Configuration 4 2

What Do RT Embedded Systems Do? 5 main kinds of functionality: Digital signal processing Open loop and closed loop control Wired and wireless networking User interfacing Storage management Most embedded systems do 1-4 of these 5 Example: Fly-by-wire Avionics: Hard real-time system with multi-rate tasks Sensors Signal Conditioning Control laws Actuating Actuators gyros, accel. INU 1kHz Pitch control 500 Hz Aileron 1 1 khz Aileron GPS Air Sensor GPS 20 Hz Air data 1 khz Lateral Control 250 Hz Aileron 2 1 khz Elevator 1 khz Aileron Elevator Stick Joystick 500 Hz Throttle Control 250 Hz Rudder 1 khz Rudder 3

Example: a Car Controller Activities of a car control system. Let 1. C= worst case execution time 2. T= (sampling) period 3. D= deadline Speed measurment: C=4ms, T=20ms, D=5ms ABS control: C=10ms,T=40ms, D=40ms Fuel injection: C=40ms, T=80ms,D=80ms Other software with soft deadlines e.g audio, air condition etc Construct a controller meeting all the deadlines! 7 Programming the car controller (1) Process Speed: read sensor,compute,display... sleep (0.02) /*period*/ Process ABS Read sensor, compute, react sleep(0.04) Process Fuel read data, compute, inject... sleep(0.08) Soft RT Processes read temperature el hiss, stereo... 8 4

Any problem? We forgot the execution times e.g. Process speed: 20ms = execution time + sleep(x) 9 Programming the car controller (2) Process Speed: next := get-time + 0.02 read sensor,compute,display... sleep until next Process ABS next:=get-time + 0.04 Read sensor, compute, react sleep until next Process Fuel next:=get-time + 0.08 read data, compute, inject... sleep until next Soft RT Processes read temperature elevator, stereo... 10 5

What is the problem now? We don t know if the deadlines are met! We need to know the execution times We need to do schedulability analysis We need to construct a schedule We need to implement/buy an RT OS kernel 11 Programming the car controller (3) 76 800 Soft RT tasks speed 4 ABS 14 64 FUEL-4 FUEL-1 20 speed A feasible Schedule! speed 24 60 FUEL-3 Fuel-2 54 ABS 44 speed 40 12 6

Challenges in RT Systems Design Predictability: the system behaviour is known before it is put into operation! e.g. Response times, deadlock freedom etc Testability: easy to test if the system can meet all the deadlines Cost optimality: e.g. Energy consumption, memory blocks etc 13 Main desirable properties of RT Systems (2) Maintainability: modular structure to ease system modification Robustness: must not collapse when subject to peak load, exception, manage all possible scenarios Fault tolerance: hardware and software failures should not cause the system to crash - function down-grading 14 7

Predictability: the most important one! Difficult (impossible?) to achieve! e.g. How to estimate the worst case response time of a task? 15 Difficult to achieve predictability: RT Tasks: Difficult to calculate the worst case execution time for tasks (theoretically impossible, halting problem) Avoid dynamic data structures Avoid recursion Bounded loops e.g. For-loops only Complex synchronization patterns between tasks: potential deadlocks (formal verification) Multi-tasking, tasks that share resources 16 8

Difficult to achieve predictability: Hardware & RTOS Cache sharing, processor pipelines, DMA... Interrupt handling may introduce unbounded delays Priority inversion (low-prority tasks blocking high-prior taskts) Memory management (static allocation may not be enough, dynamic data structures e.g. Queue), no virtual memory Communication delays in a distributed environment 17 Problems to solve... Missing deadlines (!) Deadlocks/livelocks Uncontrolled exception (ARIAN 5) Clock jitter (the golf war, Scud missile) 57micro sec/min, 343ms/100 hours 687 meters Priority inversion (the Mars project) Uncontrolled code size, cost,... Non-determinism and/or Race condition 18 9

END of introduction 19 10