-MCD
nodule
ns that
pened;
vent 1
v DCP
at 2 is
aracter
1 word
| Waits
sitions
1 20th,
s, any
r until
> deals
sed to
inning
or the
length
. been
use it
to the
th the
der to
) state
of the
> of a
ppens
one of
ore, a
TR3 - During the situation of conflict, this state holds the
system in case of an event 0 occurrence. That means, a
probable beginning of a new message has happened;
ZR3 - Analogue to ZR1 and ZR2, in this case dealing with
situation of conflict;
SC3 - Analogue to SC1, in this case dealing with situation of
conflict;
RIN - This state holds the system whenever the following
situation happens: the last message has probably been
received wrong. In order to confirm that error, the
message standard which occurs in the beginning of the
message header has to be searched for in the message data
field;
TR4, ZR4 - Analogue to TR2 and ZR2, in this case dealing
with the identification of the wrong message;
END - The final state in which the system closes the messages
block analysis.
The action, which has to be taken in each state of the system
when an associated event occurs, is represented in the FIGURE
3 by the symbols Ai, where i is the number of the action. The
actions are responsible to make conclusions in each specific
case of the finite state automaton. In addition, the actions
always read the next character in the message in order to
identify the next event. As presented in FIGURE 3, the
following actions are executed by this finite state automaton:
A] - It identifies the characters which represent the pattern of
the beginning of the message header;
A2 - It is executed whenever an EOF character is found without
none message header pattern has been recognized. That
means, the message is unknown. It is stored in the data
base as a special data in order to be analyzed later on;
A3 - It is executed whenever a message header pattern is
supposed to be considered data field;
A4 - It is executed whenever, in the message beginning, a
different character is read instead of the expected
character in the message header;
AS - It is executed whenever an EOF character is found just
after the last DCP message in the messages block being
completed. That means, although some additional
characters have been found at the end of the message
block, the last DCP message is successful;
A6 - It is executed whenever an EOF character is found in the
message data field. That means, the last DCP message in
the messages block is truncated;
A7 - It is executed whenever an EOF character is found
immediately after the last DCP message in the messages
block being completed. That means, the last DCP
message is successful;
AS8 - It is executed whenever the header standard of a new
message is identified immediately after the last message
being successful completed. As a conclusion, the last
message format analysis was successful and a new DCP
message is in analysis right then;
A9 - It is executed whenever an EOF character is found during
the recognition process of the pattern that identifies a new
DCP message in the messages block. Therefore, the
conclusion in that case is that the last DCP message is
wrong;
135
A10 - It is executed whenever, during a situation of conflict, the
pattern that identifies a new DCP message in the
messages block, is found. That means, the last DCP
message has been considered truncated or some extra
characters have been aggregated to it. Anyway, a new
DCP message is in analysis right then;
All - It is executed after the three first octets of the message
header being recognized. It works on the other header
fields of the message in order to consume them, until
matching the synchronism word;
A12 - It is executed after a synchronism word being successful
detected. It works on data field consumption;
A13 - Although the pattern which represents the beginning of a
new DCP message has been found, the action A13 is
executed whenever the synchronism word has not been
matched. That means, the last message is considered
wrong;
A14 - It is executed whenever, during a situation of conflict, an
EOF character is found, just before the synchronism word
being verified. In that case, the situation of conflict has
not been well solved. As a conclusion, the last DCP
message in the messages block is considered wrong.
3. IMPLEMENTATION
In order to implement the SCMCD acquisition module, the
finite state automaton which was designed to analyze the DCP
message format and presented in FIGURE 3 was mapped in a
decision table. This table was implemented in C-language,
using a matrix where their rows represent the automaton states
and their columns characterize the associated events. The
elements of the matrix define both the action which has to be
taken in every state of the system for each event occurrence,
and the next state in which the system shall remain waiting for
the next event occurrence.
The advantage of the decision table implementation is
concerned with the walkthrough facility on the table. This
mechanism of control is independent of the actions, events and
states which are managed by the decision table. Therefore, this
kind of implementation allows the code re-utilization. In case
another finite state automaton implementation is required,
beside the actions specific code, only the decision table contents
have to be changed.
Another relevant aspect of the SCMCD acquisition module
implementation refers to its capacity of distinguishing the
different message formats. That is done by associating each
message to a logical channel which is designed by software
mechanisms. This is so because the original sites of the
messages are different.
4. GENERALIZATIONS
Just like the finite state automaton presented for DCP message
analysis in SDID format, other finite state automatons have
been implemented in the SCMCD software acquisition module
International Archives of Photogrammetry and Remote Sensing. Vol. XXXI, Part B1. Vienna 1996