REAL TIME OPERATING
SYSTEM
Rajesh k – ENG17EC0079
PV Sai Kumar - ENG17EC0072
Nanda Vishal - ENG17EC0114
A real-time operating system (RTOS) is an operating system (OS) intended to serve
real-time applications that process data as it comes in, typically without buffer
delays
RTOS find applications in various fields of engineering and technology:
Some of them include;
Control systems.
Image processing.
Voice over IP.
Fault Tolerance systems, etc.
RTOS for control
systems:
Let us consider an
example of PID Controller
with single input and single
output Which is common in
practice.
o Many real-time systems are embedded with sensors and actuators and function as digital
controllers.
o The term plant in the block diagram refers to a controlled system for example, an engine, a brake,
an aircraft, etc.
o The state of the plant is monitored by sensors and can be changed by actuators.
o The real time (computing) system estimates output from the sensor readings.
o Also the current state of the plant and computes a control output based on the difference between
the current state and the desired state which is the reference input
The analog sensor reading y(t) gives the measured state of the plant at time t.
Let e(t) =r(t)- y(t):
denote the difference between the desired state r(t) and the measured state y(t) at time “t” .
The output u(t) of the controller consists of three terms:
1. a term that is proportional to e(t)
2. a term that is proportional to the integral of e(t)
3. a term that is proportional to the derivative of e(t).
The entire process can be done by an infinite timed loop.
set timer to interrupt periodically with period T:
at each timer interrupt, do(start loop)
do analog-to-digital conversion to get y;
compute control output u;
output u and do digital-to-analog conversion;
end do(end loop)
• The reference input r(t) is a step function from
the initial position to the final position In figures,
these positions are represented by 0 and 1,
respectively.
• The time origin is the instant when the step in r
(t) occurs. The dashed lines in (a) gives the output
u(t) of the analog controller and the observed position
y(t) of the arm as a function of time.
• The solid lines in the lower and upper graphs
give, respectively, the analog control signal
constructed from the digital outputs of the controller
and the resultant observed position y(t) of the arm.
• At the sampling rate shown here, the analog and
digital versions are essentially the same
The sold lines in (b) give the behaviour of the when the sampling period is increased by five
digital version when the sampling period is times, as shown in figure (c) the arm requires
increased by 2.5 times. larger control to stay in the desired position; when
The oscillatory motion of the arm is more this occurs,the system is said to have become
pronounced but remains small enough to be unstable
acceptable.
• In general the faster a plant can respond to changes in the reference input, the faster is the input to its
actuator varies, and the shorter the sampling period.
• We can measure the responsive ness of the overall system by its rise time R.
• This term refers to the amount of time that the plant takes to reach some small neighborhood around the
final state in response to a step change in the reference input.
Multirate Systems : A plant typically has more than one degree of freedom. Its state is defined by multiple
state variables (eg, the rotation speed, temperature, ete. of an engine or the tension and position of a video
tape). Therefore, it is monitored by multiple sensors and controlled by multiple actuators.
This mutirate controller controls only flight dynamics. The control system on board an aircraft is considerably
more complex which typically contains many other equally critical subsystems
(eg, air inlet fuel hydraulic, brakes, and anti ice controllers) and many not so critical subsystems (e.g. lighting
and environment temperature controllers)
• So, in addition to the flight control-law computations, the system also computes the control laws of these
subsystems.
• Controllers in a complex monitor and control system are typically organized hierarchically. One or more digital
controllers at the best level directly control the physical plant.
• Each output of a higher- level controller is a reference input of one or more beer-evil controllers.
• For example, a patient care system may consist of microprocessor-based controllers that monitor and control the
patient's blood pressure, respiration glucose, etc.
• There my be a higher-level controller (eg; an expert system, which interacts with the operator (a nurse or
doctor) and chooses the desired wages of these health indicators.
• While the computation done by each digital controller is simple and nearly deterministic, the computation of a
high level controller is likely to be far more complex and variable.
The Air Traffic Control (ATC) system is at the highest level. It regulates the flow of flights to each destination
airport
o It does so by assigning to each air craft an arrival time at
each metering en route to the destination.
o The aircraft is supposed to arrive at the metering fix at the
assigned arrival time.
o At any time while in flight, the assigned arrival time to the
next metering fix is a reference input to the on-board flight
management system.
o The cruise speed, turn radius, decent/accent rates, and so
forth required to follow the chosen time-referenced flight
path are the reference inputs to the flight controller at the
lowest level of the control hierarchy.
• The ATC system directly controls the embedded components in low level of the control hierarchy.
• The ATC system gathers information on the state of each aircraft via one or more active radars.
• The ATC system processes messages from aircraft and stores the state information thus obtained in a database.
• This information is picked up and processed by display processors. At the same time, a surveillance
system continuously analyzes the scenario and alerts the operators whenever it detects any potential lizard
(e.g., a possible collision).
• As another example for higher level of control, let us consider a control system of robots that perform
assembly tasks in a factory for example Path and trajectory planners at the second level determine the
trajectory to be followed by each industrial robot.
• These planners typically take as an input the plan generated by a task planner, which chooses the sequence of
assembly to be performed.
• In a space robot control system there may be a scenario planner, which determines how a repair function
should be performed. The plan generated by this planner is an input of the task planner.
THE END