Migrate a RTAI Application to RT- Preempt - A case study lin u troni x.

Slides:



Advertisements
Similar presentations
Vassal: Loadable Scheduler Support for Multi-Policy Scheduling George M. Candea, Oracle Corporation Michael B. Jones, Microsoft Research.
Advertisements

Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1.
Background Introduction Android OS Architecture Feasibility and Necessity Android RTS Architecture Limitation Improvement Lei Cui.
Embedded and Real-time Operating Systems The suitability of Linux.
Contiki A Lightweight and Flexible Operating System for Tiny Networked Sensors Presented by: Jeremy Schiff.
Introduction to Kernel
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)
1-1 Embedded Software Development Tools and Processes Hardware & Software Hardware – Host development system Software – Compilers, simulators etc. Target.
University of Kansas Douglas Niehaus Information and Telecommunication Technology Center Electrical Engineering and Computer Science Department University.
1 Input/Output Chapter 3 TOPICS Principles of I/O hardware Principles of I/O software I/O software layers Disks Clocks Reference: Operating Systems Design.
Comparative Operating Systems Fall 2001 An Examination of Embedded Linux as a Real Time Operating System Mark Mahoney.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 2: Operating-System Structures Modified from the text book.
Embedded Linux Sandeep Sirpatil Graduate Student University of North Carolina Charlotte Feb 7, 2005.
CprE 458/558: Real-Time Systems (G. Manimaran)1 RTLinux Lab – Introduction Cpre 558 Anil
EtherCAT Protocol Implementation Issues on an Embedded Linux Platform
Wir schaffen Wissen – heute für morgen 24 August 2015PSI,24 August 2015PSI, Paul Scherrer Institut Status WP 8.2 RF Low Level Electronic Manuel Brönnimann.
Wind River VxWorks Presentation
Final Year Project Electronic & Computer Engineering Student: Andrew Sweeney Supervisor: Dr. Peter Corcoran Design and Realisation of Experiments for an.
ITEC 502 컴퓨터 시스템 및 실습 Chapter 8-1: I/O Management Mi-Jung Choi DPNM Lab. Dept. of CSE, POSTECH.
Segmentation & O/S Input/Output Chapter 4 & 5 Tuesday, April 3, 2007.
ASQF Fachgruppe Automation/ Automation Day 1 Realtime capable Linux: Requirements (Standard)LinuxRealtime LinuxRealtime kernel One (physical) address space.
I/O Systems I/O Hardware Application I/O Interface
Linux and Real Time Real-time systems are characterized by deadlines. When a missed deadline results in inconvenience or a diminished customer experience,
Tittle:Real Time Linux
1-1 Embedded Network Interface (ENI) API Concepts Shared RAM vs. FIFO modes ENI API’s.
1 Haptic Systems Mohsen Mahvash Lecture 4 12/1/06.
Xenomai’s Porting on processor NIOS II Professor : P. Kadionik Authors : Bassi Vincent Louati Azza Mirault Raphael Polette Simon.
Real-Time Linux Evaluation NASA Glenn Research Center Kalynnda Berens Richard Plastow
CE Operating Systems Lecture 3 Overview of OS functions and structure.
Real-Time, Clocking, and Porting (My Job ) Determining the Real Time Capabilities of various Operating Systems. Writing code to support Real Time Clocking.
An Introduction to Device Drivers Ted Baker  Andy Wang COP 5641 / CIS 4930.
Author George Peck EVLA Hardware Monitor & Control PDR March 13, MIB FUNCTIONALITY.
Final Year Project Electronic & Computer Engineering Design and Realisation of Experiments for an embedded Linux Laboratory Class. Student: Andrew Sweeney.
Digital Handheld Communication and Navigation Device
System Software Design Engineer: Mac Gainor Western Washington University.
4. Operations and Performance M. Lonza, D. Bulfone, V. Forchi’, G. Gaio, L. Pivetta, Sincrotrone Trieste, Trieste, Italy A Fast Orbit Feedback for the.
Kernel Modules – Introduction CSC/ECE 573, Sections 001 Fall, 2012.
Interrupt Handler Migration and Direct Interrupt Scheduling for Rapid Scheduling of Interrupt-driven Tasks Reviewer: Kim, Hyukjoong ESLab.
From VME/RTEMS to Industrial PC/LinuxRT: A Migration Story Mitch D’Ewart May EPICS Collaboration Meeting May 2015.
KNU RTLAB A Real-Time Linux System For Autonomous Navigation And Flight Attitude Control Of An Uninhabited Aerial Vehicle Charles E. Hall, Jr. Mechanical.
CIT 140: Introduction to ITSlide #1 CSC 140: Introduction to IT Operating Systems.
Real-Time Performance of Linux “A Measurement-Based Analysis of the Real-Time Performance of Linux” (L. Abeni, A. Goel, C. Krasic, J. Snow, J. Walpole)
Polishing the Dirt Deploying vendor software in embedded Linux systems Porting legacy RTOS code to Userspace drivers framework © Vitaly Wool, BroLab AB,
Computer System Structures
cFS Platforms OSAL and PSP
Voice Controlled Robot by Cell Phone with Android App
Chapter 13: I/O Systems.
Introduction to Kernel
REAL-TIME OPERATING SYSTEMS
Module 12: I/O Systems I/O hardware Application I/O Interface
CS501 Advanced Computer Architecture
Linux Realtime Preemption and Its Impact on ULDD* - Progress Report -
CS 6560: Operating Systems Design
UNIT – Microcontroller.
3rd IEEE Int. Conference on Industrial Informatics (INDIN), August 2005, Perth, Australia A Real-Time Linux Execution Environment for Function-Block.
Introduction to the Kernel and Device Drivers
Chapter 2: Operating-System Structures
An Introduction to Device Drivers
CSCI 315 Operating Systems Design
I/O Systems I/O Hardware Application I/O Interface
Operating System Concepts
13: I/O Systems I/O hardwared Application I/O Interface
CS703 - Advanced Operating Systems
Lecture Topics: 11/1 General Operating System Concepts Processes
Real-time Linux Evaluation
Chapter 5: I/O Systems.
Chapter 13: I/O Systems I/O Hardware Application I/O Interface
Chapter 13: I/O Systems I/O Hardware Application I/O Interface
Module 12: I/O Systems I/O hardwared Application I/O Interface
Chapter 13: I/O Systems “The two main jobs of a computer are I/O and [CPU] processing. In many cases, the main job is I/O, and the [CPU] processing is.
Presentation transcript:

Migrate a RTAI Application to RT- Preempt - A case study lin u troni x

Initial position ● Linux RTAI ● Existing Application (Automated Test Equipment) – Audio stimulation – Frequency generator ( Hz) – Power fail scenarios – Serial data stream capture and analysis

Goal ● Linux Realtime Extension ● Make the application code more modular and portable. Code must be usable on an unmodified kernel ➔ Application Programming Interface: POSIX

Which real-time extension to use ? Available choices: ● RT-Linux – Excluded due to licensing ● RTAI/Xenomai ● RT-Preempt

Xenomai vs. RT-Preempt Xenomai: ● Dual Kernel approach ● Separate libraries ● RTAI migration skin allows easy transition of the existing code RT-Preempt ● Single Kernel ● Standard glibc (+ patches) ● Reimplementation of the code necessary

Xenomai first choice ? ● POSIX interface not fully implemented ● One to one usage of existing code did not work out ● Adds 300k+ binary code size and 250k+ data size to the kernel ● Code has to be modified / recompiled to use on vanilla Linux ● Unclear project situation after the RTAI split

What about RT-Preempt ? ● POSIX interface fully implemented ● Small increase in kernel size (36k code, 15k data) ● Strong and mainline visible development ● Code runs unmodified on vanilla Linux ● Performance evaluation positive

How to migrate smoothly and fast ? Userspace: ● Complete redesign of the application ● Reuse of code evaluated ● Modular functionalities implemented in parallel Kernel: ● Usage of a framework for industrial I/Os ● Driver implementation restricted to absolute necessary low level functions Stub device drivers implemented first, so application and device driver development can go in parallel

What's the result ? Two weeks of implementation time. (4 engineers) ● Functional prototype ● Shiny new modular design ● Impressive decrease of code lines: Original RTAI code: New implementation: 7300

Performance results Environment: – Pentium M 1,4GHz – Custom made interface hardware (Audio stimulation, Frequency stimulation, Fieldbus interface)

Performance results Audio: Interrupt driven refill of the D/A buffer (Period: 720us) Maximum Latency (Hardware interrupt -> Last FIFO entry written): 220us ISR (Low level ACK) Wakeup UT Hardware Buffer Refill Task ● Fill FIFO with pre calculated values ● Calculate next buffer or read from mmapped file mma p

Performance results Frequency stimulation: 1-8 Timers toggle an output pin Hardware High Resolution timers Timer callback Driver Frequency Control Task ● Command pattern processing Frequency jitter: max. 60µs

Performance results Data stream capture from the device under test ISR (Low level ACK) Wakeup UT Hardware Buffer Readout Task ● Read FIFO ● Store values into a Ring Buffer mma p Data processing task ● Read and process values from the Ring Buffer ● Store result Sign al

Performance results Data stream capture from the device under test Data Rate: Baud Interrupt Rate: 1.3 ms Maximum Latency (Interrupt -> Readout last byte): 380us Ringbuffer size: 256kiB Max. Filllevel: 160 kiB

Is Preempt-RT production ready ? It depends. ● The development process has stabilized ● Productized versions are necessary (not every single -rt release is usable) ● Used already in products: – Laser control – Wood working machines (multi axis servo control) – Soft-PLC (ARM, PPC based)