Professional Documents
Culture Documents
control).
magnitude
Soft Deadline:
Penalty often lesser magnitude than reward
3
Communication
Architectural Issues
Computing subsystem, Communication subsystem,
I/O subsystem
Software Issues
Requirements, specification, and verification, Real-
switching
Non-preemptive Scheduling
Once a task starts executing, it completes its full
execution
Offers lower schedulability
Less overhead due to less context switching
8
Architectural Issues
Predictability in Instruction execution time,
features.
Support for error handling (self-checking circuitry,
Introduction: Summary
Real-time systems require logical correctness and timeliness.
Real-time system consists of a controlling system, controlled
systems.
complex
Multiple threads
Complicated Synchronization Requirements
Filesystem / Network / Windowing support
OS primitives reduce the software design time
Features of RTOSs
Scheduling.
Resource Allocation.
Interrupt Handling.
Other issues like kernel size.
Scheduling in RTOS
More information about the tasks are
known
No of tasks
Resource Requirements
Release Time
Execution time
Deadlines
QOS guarantee.
(Greedy/List/Event Driven)
Processor never left idle when there are ready tasks
Processor allocated to processes according to priorities
Priorities
static
- at design time
Dynamic - at runtime
Process
Average
Burst
Time
Priority
Waiting
Time
Turnaround
Time
10
16
16
18
18
19
8.2
12
Priority Ceiling
Each resource has an assigned priority
Priority of thread is the highest of all priorities
Priority Inheritance
The thread holding a resource inherits the
possible time
should be small
Interfacing
Serial/parallel ports, USB, I2C, PCMCIA, IDE
Communication
Serial, Ethernet, Low bandwidth radio, IrDA,
802.11b based devices
User Interface
LCD, Keyboard, Touch sensors, Sound, Digital
pads, Webcams
Sensors
A variety of sensors using fire, temperature,
pressure, water level, seismic, sound, vision
Example of Rtos
Wind River Systems
VxWorks
pSOS
QNX Software Systems
QNX
Mentor Graphics
VRTX
Palm Computing
PalmOS
Mobile OS
SymbianOS
Linux based
Embedded Debian Project
convert Debian to an
embedded OS
ETLinux
for PC104 SBCs
uCLinux
for microprocessors that
dont have MM
uLinux (muLinux)
distro fits on a single
floppy
RT-Linux
Introduction
25
Contents
Real-Time Operating System (RTOS) Vs. General Purpose OS
(GPOS)
26
RTOS
needs deterministic timing behavior
Works under worst case assumptions
GPOS
high throughput and fairness
Optimizes for the average case
different
27
Linux
non-preemptible kernel
A system call might take long time to complete
Tasks can be released only with 10ms precision
Virtual memory
Variable priority
Each task is assigned a priority which varies over the
time; this is to achieve fairness
28
efficiency
Linux makes high priority tasks to wait for low priority tasks to
release resources
29
Commercial RTOS
RTLinux Monolithic kernel with loadable modules
LynxOS Microkernel
RTLinux: Overview
Open source Linux project
Supports x86, PowerPC, Alpha
Available as a patch to the regular Linux kernel
Provides an RT API for developers
Runs Linux kernel as lowest priority process
31
Linux Kernel
User Processes
System libraries
Device drivers
I/O
Linux kernel
Hardware Interrupts
Hardware
32
RTLinux Kernel
System libraries
Device drivers
I/O
Direct
h/w
access
Linux kernel
Software Interrupts
RT-Scheduler
RTLinux Plug-in
I/O
Hardware Interrupts
Hardware
33
THE
controller
User
Process
M1
M2
M2
M3
M4
RAM
Module M2 service
(system call)
DISK
34
THE
RTLinux Kernel: code perspective
RT Load
command
controller
Load RT core
RTM2
RTM3
M1
M2
RT-Core Module
M3
RAM
RT core
DISK
35