Information Technology Reference
In-Depth Information
into positions that allow traversal of the chosen route (as described by the point
position table), and when the points have been switched it requests the entry
signal to show a GO aspect (as described by the signal setting table) indicating
that the tram may enter the route. As soon as the tram has passed the entry
signal, the signal is requested to show STOP, and when the tram has left the
route, the route is deallocated by removing its reservation.
Each control system is implemented using a main loop, so that each execution
cycle has four phases: In the input phase all current values of input interfaces
(actual states) are copied to (global) shadow variables, in the processing phase in-
terfaces are neither read nor updated, but global or local variables are processed.
In the wait phase the system “spins” in an active wait loop without side effects
(this is to ensure constant loop frequency), and in the output phase the states
of global variables shadowing outputs are copied to the corresponding output
interfaces (requested states).
SystemC Model for Physical Domain. For each signal S there is a transition
rule instantiated from the following pattern:
1
if ( ((t >= reqsigtm[S] + delta_s) || (nondet_signal[S]))
2
&& (reqsig[S] != actsig[S20]) ) {
3
actsig[S] = reqsig[S];
4 }
It states that the signal actsig[S] ( “actual state” ) has to switch to the new
state reqsig[S] ( “requested state” ) issued by the controller (line 3). A signal
without failures has to switch within the specified switching deadline delta s .
To determine whether delta s time units have elapsed, the time of the request
reqsigtm[S] for this signal is compared to the time t of the tram control system
(line 1). In line 1 an auxiliary state component ( nondet signal[S] )isusedto
model nondeterminism: It is set with an arbitrary value in each execution cycle
and enables a state transition at arbitrary time ticks between the time of the
request and the time limit for the transition. Of course, state transitions for
the signals are only necessary if the actual state actsig[S] differs from the
requested state reqsig[S] (line2).
For points the transition rules are similar to the rules for signals.
For each sensor G , there are two rules, one for transitions from LOW to HIGH
and one for transitions from HIGH to LOW .The HIGH to LOW rule has the following
form:
1
if ( (sen[G] == SEN_HIGH) && (t>=delta_l + sentm_G) ) {
2
sen[G] = SEN_LOW;
3 }
It states that the sensor has to be stable in state HIGH for exactly delta l time
units (line 1) (so that the controller is able to recognise the HIGH state) before
going from state HIGH to state LOW .
The conditions in the LOW to HIGH rule depend on the sensor location. We do
notreportallthese conditions here.
Search WWH ::




Custom Search