Implementing Ada.Real_Time.Clock and Absolute Delays in Real-Time Kernels

A real-time kernel providing multitasking and timing services is a fundamental component of any real-time system. Timing services, which are crucial to the correct execution of this kind of applications, are usually provided by a real-time clock and timer manager, which is part of the kernel and implements the required functionality on top of the one or more hardware timers. Kernel timing services must be implemented carefully in order to avoid race problems and inconsistencies which may be caused by the fact that many common hardware timer chips are not intended at a direct implementation of software timing services. This paper provides advice on the implementation of two of the Ada timing services: Ada.Real_Time.Clock, and absolute delays (delay until). The example implementation of both services in the Open Ravenscar Kernel, which is based on the ideas presented in the paper, is also described.

[1]  D. B. Davis,et al.  Intel Corp. , 1993 .

[2]  Juan Zamorano,et al.  The design and implementation of the open Ravenscar kernel , 2001, IRTAW '00.

[3]  Juan Antonio de la Puente,et al.  Reliable Software Technologies — Ada-Europe’ 99 , 2002, Lecture Notes in Computer Science.

[4]  Hubert B. Keller,et al.  Reliable Software Technologies Ada-Europe 2000 , 2000, Lecture Notes in Computer Science.

[5]  S. Tucker Taft,et al.  Consolidated Ada Reference Manual Language and Standard Libraries , 2002, Lecture Notes in Computer Science.

[7]  José F. Ruiz,et al.  An Open Ravenscar Real-Time Kernel for GNAT , 2000, Ada-Europe.

[8]  Alan Burns The Ravenscar Profile , 1999, ALET.

[9]  Hermann Kopetz,et al.  Clock Synchronization in Distributed Real-Time Systems , 1987, IEEE Transactions on Computers.

[10]  Michael Barabanov,et al.  A Linux-based Real-Time Operating System , 1997 .

[11]  Juan Zamorano,et al.  ORK: An Open Source Real-Time Kernel for On-Board Software Systems , 2000 .

[12]  Juan Antonio de la Puente,et al.  The design and implementation of the open Ravenscar kernel , 2001 .

[13]  J.A. Stankovic,et al.  Misconceptions about real-time computing: a serious problem for next-generation systems , 1988, Computer.

[14]  José F. Ruiz,et al.  Implementing a New Low-Level Tasking Support for the GNAT Runtime System , 1999, Ada-Europe.

[15]  David B. Whalley,et al.  Fast context switches: compiler and architectural support for preemptive scheduling , 1995, Microprocess. Microsystems.