366
W. Chang et al.
leave some low-priority tasks waiting indefinitely. A solution to this problem is
ageing. Ageing involves gradually increasing the priority of tasks that wait in the
system for a long time.
There are many other scheduling algorithms that will not be discussed in
detail here, such as the round-robin scheduling and multilevel scheduling. For
RTOS, latency becomes the most critical factor. Common scheduling algorithms
include the rate-monotonic scheduling, earliest-deadline-first (EDF) scheduling,
proportional share scheduling, etc. Note that in the above we focus on scheduling
of a single processor. For the multi-processor system, the scheduling becomes more
complicated and a number of issues need to be considered, such as processor affinity
and load balancing.
7.2.2 Physical Components
CPS often involve control applications. A control application is responsible for controlling a plant or dynamical system. For linear single-input single-output (SISO)
control applications, the dynamic behavior is modelled by a set of differential
equations:
˙
x(t) = Ax(t) + Bu(t),
y(t) = Cx(t),
where x(t) ∈ R l is the system state, ˙
x(t) is the derivative of x(t) with respect to time,
y(t) is the system output, and u(t) is the control input. The number of system states
is l. The system (or state) matrix is A. The input matrix is B. The output matrix is
C. These matrices A, B, and C are physical properties of the plant. System poles are
eigenvalues of A. In a state-feedback control algorithm, u(t) is computed utilizing
x(t) (feedback signals) and then applied to the plant, which is expected to achieve
certain desired behavior.
In most applications, the controller is implemented in a digital fashion on a
computer. This implies that the system states must be sampled when measured by
the sensors. Assuming the sampling period to be h, the sampled system state is
denoted as
x [k] = x (t k ) , t k = kh, k = 0, 1, 2, 3, · · · .
Similarly, the sampled system output is
y [k] = y (t k ) .
Précédent

- 371/647

Suivant