An Approach for Building of Man-Machine Interface for a Real-Time System

An Approach for Building of Man-Machine Interface for a Real-Time System

TECHNIQUES FOR LOW COST AUTOMATION Copyright © IFAC Low Cost Automation 1986 Valencia, Spain , 1986 AN APPROACH FOR BUILDING OF MAN-MACHINE INTERFAC...

907KB Sizes 2 Downloads 36 Views

TECHNIQUES FOR LOW COST AUTOMATION

Copyright © IFAC Low Cost Automation 1986 Valencia, Spain , 1986

AN APPROACH FOR BUILDING OF MAN-MACHINE INTERFACE FOR A REAL-TIME SYSTEM Tz. B. Bournaska Bulgarian Academy of Sciences, Central Lab of Control Systems, 1113 Sofia , Bulgaria, POB 79

Abstract. Designing and programming of a man-machine interface of an automatical real-time control system is discussed. The interactive subsystem structure of the control system is modelled by a dendroid graph. A generalised program or an automatic synthesis are used for coding of programs having the same logical structure. Efficient use of computer and programmer resources is achieved by the proposed approach. Ke~ords. Man-machine system, program design; computer mo eiiing; interactive system.

INTRODUCTION

programming,

TASK SPCIFICATION AND REQUIREMENTS

The implementation of cheap automation is a bilateral process. On the one hand, the objective is expenditures reduction by the introduction of automated systems,and on the other hand, the automation should provide for minimum running costs. The creators of software products haunt the same goals.

The creation of an interactive subsystem (IS) of the software system for an realtime automatical system for mobile objects control is considered. The IS should allow the user to exert control actions on the control system,to provide for him the required dynamic and static data of system state as a whole and of its components, objects etc.

The experience from the building of a man machine interface for a real-time automatical control system of mobile objects is outlined in this paper. For the system under consideration, the feasibility of cost decrease in deSigning and programming of the man-machine interface is emphasized.

The control system is monitoring a large number of parameters of the controlled objects and processing the inCOming dynaming informations by use of a computer. The major part of the resources of the computing facility is being used for this purpose. This necessitates taking into account during designing and programming the minimization of the main memory usage by the IS software.

The software reliability determines the number of errors found during normal operatiOns and hence the cost for debugging. Therefore the good deSign proves to be of a considerable importance. The basis for writing of reliable software system (the creation of correct, error-free programs) is viewing at the programs as mathematical objects, subject to logical considerations and rules of formal conversions (whether it is performed any actions upon numbers, or upon texts and arbitrary objects)(Linger,1982~ The precise project is a result of thorough simplifications of the specification's sophisticated logics, that frequently involves big creative efforts. As a consequence, such a project is easy to implement, and any modifications are readily introduced during operations. This often leading to the reduction of labour and costs involved in this development. Some necessary steps are outlined in this paper, related to the building of an interactive system, implementing the manmachine interface, that might secure the higher overall reliability of interactive system.

Another requirement is the implementation of the man-machine interface in natural language and minimum training and background of the user. DESIGN APPROACH The interaction between system and user is menu-based (the terminal screen is filled with numbered options). The menu selection allows for the building of a search tree (Sllneiderman,1984). The top-down approach is selected the deSign of the IS.

for

The overall task is specified for the IS as a whole. The same is being broken down into parts, in order to represent by an equivalent structure the subtasks interrelated in a certain way. Each of the subtasks provides the partial solution of the source task, at the same time being simpler than the latter. If some of the subtasks are still complex, those

187

Tz . B. Bournaska

188

are subdivided into subsubtasks. This process continues until sufficiently simple tasks are reached, their solution providing the solution of the sourse tasks of the overall IS. Based on the above decomposition and the possibilities of menu selection, a dendroid graph, presenting the IS structure (given in Fig. 1) is built. A unique mutual correspondence is established among the set of nodes belonging to the graph, and set of programs. implementing the source task, and satisfying the following conditions I - an interactive system program corresponds to every node of the graph and vice versal - processing of the data is performed only within a program corresponding to a node that has no branches, and vice versa I - a program corresponding to a branched node executes a dialog to determine to which of the programs related to a subbranch of the branch under consideration to transfer the control,and vice versa;

level

0

...

1

level

K-1

level

K

level

K+1

level

.2~6 ,/

.. I

I

/

I

~I+2

"

J~I+4 1+8

1+9

~I+13

/

~N-3

!I

Fig. 1.

"-

1+7

,

• • • level

1

"

....

IN-2 "..N:.1"-.....N

Structure of the interactive subsystem ANALYSIS OF THE DESIGN APPROACH

The top-down design implies an deep analysis of the source task as a whole. It allows for establishing a natural design approach towards the software system being built. It requires more efforts by the desgners compared to the down-top design, however the work invested pays for the linking and debugging of programs. The building up of the system is being done via its expansion at each of the following levels, the linking of the ready programs being done during the programming itself rather than upon the complection of all programs. This allows for a flexibility during system design. If errors had been made during the design and programming steps,those could be found and removed at an early stage, without the necessity of restarting from the scratch. the menu selection does not necessitate user's preliminary background and has the advantage of prompting user response

to the proposed system possibilities. Means for debugging and user assistance might be readily provided. PROGlWDIING APPROACH

The programs have been written in FORrRAN using an S1.I-4 minicomputer. I t is satisfied the requirement all of the programs to be build in module principle. The overlay structure of IS had been adopted. Rarely used programs are kept on a disk. Frequently used programs are being optimized. The programming is done from top downward zero The program corresponding to level (root) of the dendroid graph (Fig. 1) is developed under the first stage. The transfer of parameters between program modules is done in common areas. All common areas used by the IS, as well as type and size of variables in those areas are declared in this program. Under '.;he next stage, all programs corresponding to the first level of the dendroid graph are being programmed. Upon completion of coding of a branched node program, the further coding can be done by a team of programmers. Each of them might develop programs, related to specific subnodes of the node under consideration,independently of the rest of team and within the overall software structure. The debugging and testing are done sequentially at every completed specific level K (K=1,2, ••• ,M). The missing programs of a lower level K+1 are being replaced by dummy ones in order to check the correctness of the whole program complex. In paralel to the development of separate programs, the proving of their correctness is carried out. The confidence in a structured program rightness is based on the correctness of its parts disclosed in succession (Linger , 1982; Anderson, 1982). The programs. corresponding to branching nodes have the same logical structure, as shown in Fig. 2. An interactive program is developed

that can synthesize those programs automatically. A transformation method for logical synthesis is utilized. The synthesized programs are produced gradually, converting the initial task specification by use of a set of rules, containing the knowledge needed for problem solution. In a dialog with the programmer, the synthesizing program gets input data in the form of menu function text, as well as the name of the appropriate program performing the respective function. The output is the FORTRAN text of the synthesizing program. An alternative approach for programming of the _above programs had been utilized. The same logical structure determines the way of deneralized progr~g. A generalized program is developed that uses as input data file describing the structure of the dendroid graph,corresponding to the specific task. This description includes:

189

Man-Machine interface

Design time I time

De bugging

=

1

I

1

I

Programming time I Testing time 4

I

1.

=

Decreasing the total number of programs being developed keeps the deSign time unch~ed, however the programming time, debugging time and testing time are reduoed. The higher the number of branched nodes, the higher the time reduction.

TYPING OF THE MJmU 1

The proposed two approaches in ooding programs for branohed nodes (the first one by an automatio synthesis, and the second one by a generalized program) are oompared in terms of ratio of required main memory size, the necessity of modifications when the source system struoture is changed,and in term of their logical complexity. The analysis had shown thatl

QUESTION FOR THE CHOUSEN MENU FUNCTION

READING OF THE USU'S ANSWER (U.1)

- the increase of number of dendroid graph levels causes an increase of the required main memory in the first approach, and no alteration in the second onel - the structure changes of the initial task necessitates local modifications of programs with the former approach and changes in the description of the dendroid graph only with the latter approaohl - the logical complexity of programs implementing the second method is relatively higher than that with the first one.

START OF .1 PROGRAM RE.1LI ZED THE CHOUSEN

FUNCTION

Fig. 2.

CONCLUSION

The and tem for the

Common structure of the branched node program.

- subordination relationship between each pair of nodes, specified by a matrix Z, as formulated in the Appendix 11 - for eaoh node of the graph, the text of the respective menu function to be performed entering upon this node;

proposed approach for the design programming of an interactive subsysimplementing a man-machine interface a real-time control system features following main advantages I

- in-depth analysis of the specified

tas~

- saving of main memory due to replacemeIJt of the branched node programs by a generalized one and by storing on disk of seldom used programs;

- for every non-branching node, the name of the respective program carrying out the specific information processing.

- efficient utilization of the computer facility by an optimization of frequently used programs and a reduction of the time for debugging and testingl

A program is developed that creates, updates and modifies the above file in a dialog with the programmer.

- efficient use of programmer's work by use of automatic synthesis of programs having the same lOgioal structure, or by their generalized programming.

ANALYSIS OF THE PROGlWOIING APPROACH

REFERENCES

The top-down programming allows for debugging and testing of the completed programs at each level, that reducing to a minimum the number of errors, and at the same time decreasing the probability of appearance of interacting interrelated errors. In order to get an idea of time efforts saved when using the proposed methods of development of programs branched nodes, starting from following relationship (Tassel,1979)1

and two for the

Anderson, R.B. (1982). Provin~pro~rams correct. In D. B. PodShiv ov *Ed.)., fllir, MOskva (in Russian). Linger, R. C., H. D. Mills, and B. Witt (1982). Structured pro~~1 Theoty and Practice. In s. D.aeev (Ea.)., Mir, MoskVa (in Russian). Shneiderman, B. (1984). SoftWare Pr;rhlogr Human factors in com~uter and omaHd!; systems. In V.. MartlnUk (Ea.). Ra 0 i sViaz Moskva (in Russian). Tassel, D. v. (1979). Program stYlet design, efficiency, debug~Ing and estInge TechriIka, Sona In BUigai'ian).

190

Tz. B. Bournaska

APPENDIX 1

Assume the dendroid graph nodes are numbered i. 1, 2 t ••• t N. If node 1 belongs to level K of the graPh the element zi;l of the matrix Z l s detel.'mined as follows I 1

t

-1

t

O.

when node j belongs to level K-1 and node 1 1s a subnode of node ;I I when node j belongs level K+1 and node j a subnode of node i I in all other cases.

to 1s