DataMuseum.dk

Presents historical artifacts from the history of:

CR80 Wang WCS documentation floppies

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about CR80 Wang WCS documentation floppies

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦26df08634⟧ Wang Wps File

    Length: 33861 (0x8445)
    Types: Wang Wps File
    Notes: CPS/SDS/029               
    Names: »1740A «

Derivation

└─⟦20fb15aa2⟧ Bits:30006084 8" Wang WCS floppy, CR 0130A
    └─ ⟦this⟧ »1740A « 

WangText



4   4…05…3…09…3…0e…3
3   3…05…3…06…3…07…2…08…2…09…2…0a…2…0b…2…0f…2 2…06…1…08…1…0a…1…0c…1…00…1
1…07……86…1   
      
      
      
      
      
      
      …02…
      
     …02… 
  …02…    
    

…02…CPS/SDS/029

…02… 820514…02……02…
SYSTEM
 STATUS
 AND CONTROL
DETAILED
 DESIGN
 SPECIFICATION…02……02…CAMPS








4.2.8    W̲A̲M̲C̲O̲ ̲(̲W̲a̲t̲c̲h̲d̲o̲g̲ ̲M̲o̲n̲i̲t̲o̲r̲i̲n̲g̲ ̲a̲n̲d̲ ̲C̲o̲n̲t̲r̲o̲l̲)̲



4.2.8.1  F̲u̲n̲c̲t̲i̲o̲n̲a̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

         The WAMCO functions are shown on fig. 4.2.8.1-1 and
         described in the following subsections.







                      Fig. 4.2.8.1-1


4.2.8.1.1    I̲n̲i̲t̲i̲a̲l̲i̲z̲a̲t̲i̲o̲n̲

         WAMCO can be started either as part of the Active PU
         or as part of the standby PU.

         a)  P̲U̲ ̲a̲c̲t̲i̲v̲e̲

             -   The environment of the WDP ̲VDU is initialized
                 to the FORMAT ̲HANDLER.

                 o   Format file and directory
                 o   Control tables
                 o   Format data area

             -   The internal used data are initialized.

         b)  P̲U̲ ̲S̲t̲a̲n̲d̲b̲y̲

             -   The internal used data are initialized.



4.2.8.1.2    W̲D̲P̲ ̲L̲i̲n̲e̲ ̲E̲v̲e̲n̲t̲

         Every change of the line from:

         -   the PU to the WDP
         -   the WDP to the WDP ̲ROP (NA in STANDBY PU)
         -   the WDP to the WDP ̲VDU (NA in STANDBY PU)

         is reported to WAMCO.

         WAMCO:

         -   creates
         -   dismantles
         -   offers

         the above mentioned lines and updates the WDP ̲VDU configuration
         display.





4.2.8.1.3    I̲n̲f̲o̲r̲m̲ ̲C̲M̲I̲

         The CMI is informed of the present state of the VDU
         and ROP lines i.e. if:

         -   WDP ̲VDU up, the offered connections to the WDP
             ̲VDU command split and format split and their interface
             numbers are sent to the CMI.

         -   WDP ̲VDU down, the CMI is requested to remove its
             WDP ̲VDU connection.

         -   WDP ̲ROP up, the offered WDP ̲ROP connection is given
             to the CMI.

         -   WDP ̲ROP down, the CMI is requested to dismantle
             its WDP ̲ROP connection.



4.2.8.1.4    C̲h̲e̲c̲k̲p̲o̲i̲n̲t̲ ̲T̲h̲e̲ ̲T̲i̲m̲e̲ ̲O̲f̲ ̲D̲a̲y̲

         Every minute the TMP is requested to checkpoint the
         time of day (System parameter CURRENT ̲TIME).



4.2.8.1.5    U̲p̲d̲a̲t̲e̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲l̲o̲c̲k̲

         The command split of the WDP ̲VDU contains a TIME ̲OF
         ̲DAY field in the upper right most corners.

         This clock is updated once a minute by WAMCO.



4.2.8.1.6    S̲e̲n̲d̲ ̲K̲e̲e̲p̲ ̲A̲l̲i̲v̲e̲ ̲M̲e̲s̲s̲a̲g̲e̲

         The Timer Monitor sends a timeout once a second to
         the WAMCO.

         Hereafter WAMCO sends a keep alive message to the watchdog
         (WDP).  Furthermore, WAMCO in the Active PU includes
         the time of day once a minute.





4.2.8.1.7    W̲D̲P̲ ̲r̲e̲p̲o̲r̲t̲s̲

         Reports received from the watchdog via the WDP ̲CON
         is sent on to the CFH in COPSY and the next receive
         is initiated.



4.2.8.1.8    E̲r̲r̲o̲r̲ ̲H̲a̲n̲d̲l̲i̲n̲g̲

         WAMCO recognizes the following software error types:

         a)  E̲x̲t̲e̲r̲n̲a̲l̲

             These errors relate to validity checks in input
             data.  In case of error, a report is sent to the
             garble queue (GAQ).

         b)  I̲n̲t̲e̲r̲n̲a̲l̲

             These errors relate to errors from system calls
             and internal logical errors.  System call errors
             are reported via the procedure ANALYSE ̲ERROR (CC).
              Internal logical program errors are reported via
             the procedure SEND ̲GARBLE.



4.2.8.2  S̲o̲f̲t̲w̲a̲r̲e̲ ̲S̲t̲r̲u̲c̲t̲u̲r̲e̲

         The WAMCO consists of four modules each implemented
         as a coroutine (except ONLINE CONFIG).  Each coroutine
         consists of a mainprocedure and a number of subprocedures
         of which some are common to the SSC package.  The WAMCO
         module is shown on fig. 4.2.8.2-1.

         The functions described in section 4.2.8.1 are mapped
         onto the modules.








                      Fig. 4.2.8.2-1


4.2.8.3  D̲a̲t̲a̲ ̲F̲l̲o̲w̲ ̲a̲n̲d̲ ̲C̲o̲n̲t̲r̲o̲l̲ ̲L̲o̲g̲i̲c̲

         The figures 4.2.8.3-1 to 4.2.8.3-5 shows the data flow
         and control logic for the WAMCO modules and procedures.






          Fig. 4.2.8.3-1…01…Blockdiagram for WAMCO







Fig. 4.2.8.3-2…01…Data Flow of the Receive Operational Commands Module





Fig. 4.2.8.3-3a…01…Data Flow for the Online Config. Module Procedures






Fig. 4.2.8.3-3b…01…Data Flow for Online Config Module Procedures






Fig. 4.2.8.3-4…01…Data Flow for the WDP Monitoring Report Module Procedures






Fig. 4.2.8.3-5…01…Data Flow for the Send Keep Alive Module Procedures


4.2.8.4  M̲o̲d̲u̲l̲e̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲



4.2.8.4.1    R̲e̲c̲e̲i̲v̲e̲ ̲O̲p̲e̲r̲a̲t̲i̲o̲n̲a̲l̲ ̲C̲o̲m̲m̲a̲n̲d̲s̲



4.2.8.4.1.1 F̲u̲n̲c̲t̲i̲o̲n̲a̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

         Receive the commands from CFH and EHD.

         The commands from CFH which are:

         -   Start up active
         -   Start up standby

         result in creating the WDP environment (i.e. VDU, ROP,
         WDP connection) and start WAMCOs two other coroutines
         if the WDP is present.

         EHD commands are only received during online operation
         (i.e. subsequent to start-up).  These commands are
         served in the Online config. module.



4.2.8.4.1.2 I̲n̲t̲e̲r̲f̲a̲c̲e̲

         NA.



4.2.8.4.1.3 C̲o̲m̲p̲o̲n̲e̲n̲t̲s̲

         The following components are included:

         -   Receive Operational commands
         -   Start Config.
         -   Start WAMCO Active
         -   Start WAMCO Standby



4.2.8.4.1.4 D̲a̲t̲a̲ ̲D̲e̲s̲c̲r̲i̲p̲t̲i̲o̲n̲

         a1) T̲y̲p̲e̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

             LONG ̲OP ̲TYPE   cf. sec. 4.1.4.4.b
             FDCB ̲INDEX     DBD



         a2) D̲a̲t̲a̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

             WAMCO ̲OS       cf. sec. 4.1.4.4.a
             LONG ̲OS        cf. sec. 4.1.4.4.a
             WAMCO ̲MON ̲OS   cf. sec. 4.1.4.4.a
             MAP ̲CON        cf. sec. 4.1.4.2.1 a
             PHYS ̲WDP ̲CON   cf. sec. 4.1.4.2.1
             WAMCO ̲INT ̲CMD
             CFH ̲LONG ̲TYPE  cf. sec. 4.1.4.7

         b)  E̲x̲t̲e̲r̲n̲a̲l̲ ̲D̲a̲t̲a̲

             WDP ̲STATUS ̲REC cf. sec. 4.1.4.7 (m)
         
         c)  L̲o̲c̲a̲l̲ ̲D̲a̲t̲a̲

             DEVICE ̲CON:    FDCB ̲INDEX
             PERIODIC
             PRC ̲Q, TIM ̲SUB.Q:  QUEUE ̲REFERENCE

             TYPE INT ̲CMD ̲TYPE = (START ̲UP ̲INT, CLOSE ̲DOWN ̲INT)
             VAR WAMCO ̲S:   WAMCO ̲STATES
             TYPE WAMCO ̲STATES = (ACTIVE ̲W, STANDBY ̲W)



4.2.8.4.1.5 D̲e̲s̲i̲g̲n̲ ̲R̲e̲c̲e̲i̲v̲e̲ ̲O̲p̲e̲r̲a̲t̲i̲o̲n̲a̲l̲ ̲C̲o̲m̲m̲a̲n̲d̲s̲

         The module contains the main procedure RECEIVE ̲OPERATIONAL
         ̲COMMANDS (a) and the subprocedures START ̲CONFIG (b),
         START ̲UP ̲WAMCO ̲STANDBY (c), START ̲UP ̲WAMCO ̲ACTIVE (d).



4.2.8.4.1.5.a P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲R̲E̲C̲E̲I̲V̲E̲ ̲O̲P̲E̲R̲A̲T̲I̲O̲N̲A̲L̲ ̲C̲O̲M̲M̲A̲N̲D̲S̲

         N̲a̲r̲r̲a̲t̲i̲v̲e̲

         The following commands are received via the WAMCO ̲OS
         (semaphore).

         -   From CFH (configuration handler)

             o   Start-up-active
             o   Start-up-standby



         -   From CMD (command dispatcher)

             o   WDP ̲ON
             o   WDP ̲OFF
             o   WDP ̲VDU ̲ON
             o   WDP ̲VDU ̲OFF
             o   WDP ̲ROP ̲ON
             o   WDP ̲ROP ̲OF

         The handling of the commands are given over to the
         procedure:

         -   START ̲CONFIG (from CFH)
         -   ONLINE ̲CONFIG (from CMD)

         F̲l̲o̲w̲g̲r̲a̲m̲

         Ref. fig. 4.2.8.4.1.5-1


         PROCEDURE RECEIVE ̲OPERATIONAL ̲COMMANDS


         INITIALIZE



         LOOP FOREVER

            WAIT ̲OPSEM (WAMCO ̲OS)(OP:  LONG ̲OP ̲TYPE)


            CASE OP.CMD ̲TYPE OF:

             CFH ̲LONG ̲CMD ? - S̲T̲A̲R̲T̲ ̲C̲O̲N̲F̲I̲G̲ (OP) (WDP.STATUS
             ̲REC)


             DEVICE ̲ERROR ? - O̲N̲L̲I̲N̲E̲ ̲C̲O̲N̲F̲I̲G̲ (OP) (WDP
             ̲STATUS ̲REC)

             OTHERS ? - COPSY ̲SEND ̲GARBLE (CONTINUE)
              

            END CASE

            SIGNAL ̲OPSEM (LONG ̲OS, OP)

         END LOOP

         END RECEIVE ̲OPEATIONAL ̲COMMANDS














              Fig. 4.2.8.4.1.5.a-1


4.2.8.4.5.1.6 P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲S̲T̲A̲R̲T̲ ̲C̲O̲N̲F̲I̲G̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The start up type is read and from this,
             one of the procedures:

             -   start-up ̲WAMCO ̲active or
             -   start-up ̲WAMCO ̲standby is called


             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.5.1.b-1


         PROCEDURE START ̲CONFIG (OP:  LONG ̲OP ̲TYPE)
                              (WDP ̲STATUS ̲REC:  WDP
                            ̲STATUS ̲RECS)


         CASE OP.CMD OF:

            START ̲AC - ? S̲T̲A̲R̲T̲ ̲U̲P̲ ̲W̲A̲M̲C̲O̲ ̲A̲C̲T̲I̲V̲E̲ (  
           ) (WDP ̲STATUS ̲REC)


            START ̲SB - ? S̲T̲A̲R̲T̲ ̲U̲P̲ ̲W̲A̲M̲C̲O̲ ̲S̲T̲A̲N̲D̲B̲Y̲ ( 
           ) (WDP ̲STATUS ̲REC)


            OTHERS ? - COPSY ̲SEND ̲GARBLE (CONTINUE)


         END CASE

         END START ̲CONFIG






























              Fig. 4.2.8.4.1.5.b-1


4.2.8.4.5.1.c    P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲S̲T̲A̲R̲T̲ ̲U̲P̲ ̲W̲A̲M̲C̲O̲ ̲S̲T̲A̲N̲D̲B̲Y̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             If Watchdog is present, the periodical
             timeouts are requested.

             F̲l̲o̲w̲g̲r̲a̲m̲

             PROCEDURE ̲START ̲UP ̲WAMCO ̲STANDBY

             WAMCO ̲S = STANDBY ̲W



             WDP ̲STATUS ̲REC.WDP ̲STATUS EQ FALSE ?


             R̲E̲S̲E̲R̲V̲E̲ ̲T̲I̲M̲E̲O̲U̲T̲S̲ (PERIODIC, PRC ̲Q,TIM
             ̲SUBQ, 1,1)

             WAIT ̲OPSEM (LONG ̲OS)(OP:  LONG ̲OP ̲TYPE)

             OP.CMD ̲TYPE = WAMCO ̲INT ̲CMD

             OP.CMD = START ̲UP ̲INT

             SIGNAL ̲OPSEM (WAMCO ̲MON ̲OS.OP)

             END START ̲UP ̲WAMCO ̲STANDBY



4.2.8.4.5.1.d P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲S̲T̲A̲R̲T̲ ̲U̲P̲ ̲W̲A̲M̲C̲O̲ ̲A̲C̲T̲I̲V̲E̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The VDU connections are created (either
             on the WDP subdevice or the MAP device).

             The configuration is displayed on the
             WDP ̲VDU.

             The CMI is started.

             If WDP is present:

             -   periodical timeouts are requested
                 (TMON)
             -   the WDP ̲MONITORING ̲REPORTS coroutine
                 is started.

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.5.1.d-1


         PROCEDURE START ̲UP ̲WAMCO ̲ACTIVE



         WAMCO ̲S = ACTIVE ̲W

         VDU ̲STATE = INI ̲FORMAT


         WDP ̲STATUS ̲REC.WDP ̲STATUS EQ FALSE ? - DEVICE
         ̲CON = MAP ̲CON



         DEVICE ̲CON = PHYS ̲WDP ̲CON


         C̲R̲E̲A̲T̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲O̲N̲N̲E̲C̲T̲I̲O̲N̲S̲ (DEVICE ̲CON)

         WDP ̲STATUS ̲REC.WDP ̲STATUS EQ FALSE ?

              "START OF WAMCO COROUTINES"

         R̲E̲S̲E̲R̲V̲E̲ ̲T̲I̲M̲E̲O̲U̲T̲S̲ (PERIODIC, PRC ̲Q, TIM ̲SUB
         ̲Q, 1, 1)


         WAIT ̲OPSEM (LONG ̲OS)(OP:LONG ̲OP ̲TYPE)


         OP.CMD ̲TYPE = WAMCO ̲INT ̲CMD


         OP.CMD = START ̲UP ̲INT


         SIGNAL ̲OPSEM (WAMCO ̲MON ̲OS, OP)


         END START ̲UP ̲WAMCO ̲ACTIVE









              Fig. 4.2.8.4.5.1.d-1


4.2.8.4.2    O̲n̲l̲i̲n̲e̲ ̲C̲o̲n̲f̲i̲g̲u̲r̲a̲t̲i̲o̲n̲



4.2.8.4.2.1 F̲u̲n̲c̲t̲i̲o̲n̲a̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

             The module receives the reports containing
             changes of the WDP devices (i.e. WDP,
             WDP ̲VDU, WDP ̲ROP).  The actions to be
             taken are given in sec. 4.2.8.1.3.



4.2.8.4.2.2 I̲n̲t̲e̲r̲f̲a̲c̲e̲

             C̲a̲l̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

             a)  ONLINE ̲CONFIG (CMD:  PROFILE ̲TYPE
                                      OP:   LONG ̲OP
                                      ̲TYPE)
                                  (WDP ̲STATUS ̲REC:
                             WDP ̲STATUS ̲RECS)

             b)  ONLINE ̲CONFIG (R3, R4, R5, R6)

             R̲e̲g̲i̲s̲t̲e̲r̲ ̲C̲o̲n̲v̲e̲n̲t̲i̲o̲n̲

             C̲a̲l̲l̲ ̲R̲e̲g̲i̲s̲t̲e̲r̲s̲

             R3  CMD
             R4  OP
             R6  LINK

             R̲e̲t̲u̲r̲n̲ ̲R̲e̲g̲i̲s̲t̲e̲r̲s̲

             R5  Pointer to WDP ̲STATUS ̲REC



4.2.8.4.3    M̲o̲d̲u̲l̲e̲ ̲C̲o̲m̲p̲o̲n̲e̲n̲t̲s̲

             The following components are included:

             -   ONLINE ̲CONFIG
             -   HANDLE ̲WDP
             -   HANDLE ̲WDP ̲ROP
             -   HANDLE ̲WDP ̲VDU
             -   DISMANTLE ̲WDP
             -   DISMANTLE ̲WDP ̲VDU ̲CON
             -   CREATE ̲MAP ̲ENVIRON
             -   CREATE ̲WDP ̲VDU ̲CONNECTIONS
             -   SEND ̲CMI (common procedure)
             -   DISPLAY ̲CONF (common procedure)
             -   CREATE ̲VDU ̲TERMINALS (common procedure)


4.2.8.4.2.4 D̲a̲t̲a̲ ̲D̲e̲s̲c̲r̲i̲p̲t̲i̲o̲n̲

             a1) T̲y̲p̲e̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 PROFILE ̲TYPE                                    4.1.4.21
                                                                 c
                 LONG ̲OP ̲TYPE                                    4.1.4.4
                                                                 b
                 TMS ̲INF ̲TYPE                                    4.1.4.7
                 CONF ̲CMD             4.1.4.7

             a2) D̲a̲t̲a̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 CMD,
                 OP: I/F data

                 PHYS ̲WDP ̲CON,                                   4.1.4.2.1
                                                                 a
                 WDP ̲ROP ̲CON
                 WDP ̲VDU ̲CON
                 WDP ̲ROP ̲OF ̲CON
                 WDP ̲SPLIT ̲CON ̲BUF

             b)  E̲x̲t̲e̲r̲n̲a̲l̲ ̲D̲a̲t̲a̲

                 OP.TMS ̲INF:  TMS ̲INF ̲TYPE

                 WDP ̲STATUS ̲REC                                  cf.
                                                                 sec.
                                                                 4.1.4.7
                                                                 (m)
                 COMMAND ̲SPLIT
                 CONFIG ̲SPLIT:                                   cf.
                                                                 sec.
                                                                 4.1.4.7
                                                                 (m)

             c)  L̲o̲c̲a̲l̲ ̲D̲a̲t̲a̲

                 VAR STATUS:          DISK ̲STATUS/HW
                                      ̲STATUS/ROP ̲STATUS
                                      ref. sec. 4.1.4.7

                 VAR WDP ̲SPLIT ̲CON ̲BUF = ARRAY (1..6)
                 of FDCB ̲INDEX
                 VAR OFFER ̲CON ̲BUF = ARRAY (1..4) of
                 OFFER ̲IDS



4.2.8.4.2.5 O̲n̲l̲i̲n̲e̲ ̲C̲o̲n̲f̲i̲g̲u̲r̲a̲t̲i̲o̲n̲ ̲D̲e̲s̲i̲g̲n̲

             The module contains the main procedure
             ONLINE ̲CONFIG (a) and the subprocedures:

             -   HANDLE ̲WDP (b)
             -   HANDLE ̲WDP ̲ROP (c)
             -   HANDLE ̲WDP ̲VUD (d)
             -   DISMANTLE ̲WDP (e)
             -   DISMANTLE ̲WDP ̲VUD ̲CON (f)
             -   CREATE ̲MAP ̲ENVIRON (g)
             -   CREATE ̲WDP ̲VUD ̲CONNECTIONS (h)


4.2.8.4.2.5.a P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲O̲N̲L̲I̲N̲E̲ ̲C̲O̲N̲F̲I̲G̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             A change in the status of the WDP devices
             is reported from the CMD.

             Depending on the CMD (PROFILE ̲TYPE), the
             further handling is dispatch to one of
             the subprocedures (b, c or d).

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.2.5.a-1


         PROCEDURE ONLINE ̲CONFIG (OP:   LONG ̲OP ̲TYPE)
                               (WDP ̲STATUS ̲REC:  WDP
                            ̲STATUS ̲RECS)


         CASE OP.CMD

            PHYS ̲WDP ̲P, WDP ̲P ? - H̲A̲N̲D̲L̲E̲ ̲W̲D̲P̲ (OP) (WDP
         ̲STATUS ̲REC)


            WDP ̲VDU ̲P ?           H̲A̲N̲D̲L̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ (OP)(WDP
         ̲STATUS ̲REC)


            WDP ̲ROP ̲P ?           H̲A̲N̲D̲L̲E̲ ̲W̲D̲P̲ ̲R̲O̲P̲ (OP)(WDP
         ̲STATUS ̲REC)

            OTHERS ? - COPSY ̲SEND ̲GARBLE (CONTINUE)


         END CASE


         END ONLINE ̲CONFIG


























              Fig. 4.2.8.4.2.5.a-1


4.2.8.4.2.5.b P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲H̲A̲N̲D̲L̲E̲ ̲W̲D̲P̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The asynchronous WDP reports (U ̲SDID.PROFILE
             = WDP ̲P/PHYS ̲WDP ̲P) are:

             a)  WDP power down
             b)  WDP failure
             c)  WDP ̲ROP ̲POWER ̲UP ̲AND ̲KEY ̲ON
             d)  WDP ̲ROP ̲PAPER ̲ON
             e)  WDP ̲ROP ̲KEY ̲ON
             f)  WDP power up

             Actions to report a, b are:

             -   report CMI if WDP ̲VDU = TRUE
             -   dismantle WDP
             -   update conf-table
             -   update WDP status record
             -   create TREE

             Actions to report c, d, e are:

             -   create ROP connections
             -   offer ROP connection
             -   report CMI
             -   update configuration
             -   update WDP-status record

             Action to WDP power up (f)

             ref. MAP environment. sec. 4.2.8.4.2.5.g

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.2.5.f-1


         PROCEDURE HANDLE ̲WDP (OP:  LONG ̲OP ̲TYPE)
                            (WDP ̲STATUS ̲REC:  WDP ̲STATUS
                            ̲RECS)


         CASE OP.TMS ̲INF OF


            POWER ̲DOWN, FAILURE ?  -  D̲I̲S̲M̲A̲N̲T̲L̲E̲ ̲W̲D̲P̲
         (  ) (WDP ̲STATUS ̲REC)


            WDP ̲ROP ̲POWER ̲UP ̲AND ̲KEY ̲ON

            WDP ̲ROP ̲KEY ̲ON

            WDP ̲ROP ̲PAPAR.ON? - C̲R̲E̲A̲T̲E̲ ̲W̲D̲P̲ ̲R̲O̲P̲ (PHYS
         ̲WDP ̲CON)
                                                                 (WDP
                                                                 ̲ROP
                                                                 ̲CON)

                              CASE OFFER (WDP ̲ROP ̲CON,ROP
                            ̲ACC)
                                            (WDP ̲ROP
                                      ̲OF ̲CON,CC): 
                                      ERROR DONE

                                 ERROR ? - ANALYZE
                            ̲ERROR (CC, 1, HW)
                                           REPORT ̲ERROR
                            (WAMCO ̲CC, WARP)

                              END CASE

                              S̲E̲N̲D̲ ̲C̲M̲I̲ (ROP ̲UP)

                              WDP ̲STATUS ̲REC.WDP ̲ROP
                            = TRUE

                              D̲I̲S̲P̲L̲A̲Y̲ ̲C̲O̲N̲F̲ (SET ̲STATUS,WDP
                            ̲ROP,IN ̲SERVICE ̲S)


            POWER ̲UP ? - C̲R̲E̲A̲T̲E̲ ̲M̲A̲P̲ ̲E̲N̲V̲I̲R̲O̲N̲ ( ) (WDP
         ̲STATUS ̲REC)


            OTHERS ?     COPSY ̲SEND ̲GARBLE (CONTINUE)


         END CASE

         END HANDLE ̲WDP







              Fig. 4.2.8.4.2.5.b-1


4.2.8.4.2.5.c-1 P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲H̲A̲N̲D̲L̲E̲ ̲W̲D̲P̲ ̲R̲O̲P̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The asynchronous WDP ̲ROP reports (U.SDID.PROFILE
             = WDP ̲ROP ̲P) are.

             -   Paper down
             -   Key off
             -   Power down

             is handled by this procedure.

             The actions taken are:

             -   report CMI ROP condition
             -   dismantle connections
             -   update configuration display (WDP
                 ̲VDU)
             -   Update WDP status record

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. Fig. 4.2.8.4.2.5.c-1


         PROCEDURE HANDLE ̲WDP ̲ROP (OP:  LONG ̲OP ̲TYPE)
                                (WDP ̲STATUS ̲REC:  WDP
                            ̲STATUS ̲RECS)


         CASE OP.ACTION ̲TYPE OF:

            PAPER ̲OUT ? - STATUS = PAPER ̲OUT ̲S

            POWER ̲DOWN ? - STATUS = POWER ̲DOWN ̲S
         
            KEY ̲OFF ?  ̲ STATUS = KEY ̲OFF ̲S


            OTHERS ? COPSY ̲SEND ̲GARBLE (CONTINUE)


         END CASE


         S̲E̲N̲D̲ ̲C̲M̲I̲ (ROP ̲DOWN)

         CASE DISMANTLE (SDP ̲ROP ̲CON)(CC):  ERROR ̲DONE

            ERROR ? - ANALYZE ̲ERROR (CC, 1, HW)
                 REPORT ̲ERROR (WAMCO ̲CC, WARP)

         END CASE


         D̲I̲S̲P̲L̲A̲Y̲ ̲C̲O̲N̲F̲ (SET ̲STATUS, WDP ̲ROP, STATUS)

         WDP ̲STATUS ̲REC.WDP ̲ROP ̲STATUS = FALSE

         END HANDLE ̲WDP ̲ROP















              Fig. 4.2.8.4.2.5.c-1


4.2.8.4.2.5.d P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲H̲A̲N̲D̲L̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The asynchronous WDP ̲VDU reports (U ̲SDID.PROFILE
             = WDP ̲VDU ̲P) are:

             a)  KEY ̲ON

             b)  POWER ̲UP ̲KEY ̲ON

             c)  KEY ̲OFF

             d)  POWER ̲DOWN

             e)  FAILURE

             The actions taken to a, b are

             -   create terminals
             -   report CMI
             -   display configuration
             -   update WDP ̲STATUS ̲RECORD

             The actions taken to c, d, e

             -   if MAP ̲WDP ̲VDU = TRUE (VDU direct
                 on PU)

                 o   report CMI
                 o   dismantle WDP ̲VDU
                 o   update WDP ̲status record
                 o   create tree

             -   else

                 o   report CMI
                 o   dismantle terminals
                 o   update WDP ̲STATUS record

             Flowgram:

             Ref. fig. 4.2.8.4.2.5.d-1







         PROCEDURE HANDLE ̲WDP ̲VDU (OP:  LONG ̲OP ̲TYPE)
                                (WDP ̲STATUS ̲REC:  WDP
                            ̲STATUS ̲RECS)



         CASE OP.ACTION ̲TYPE OF


            KEY ̲ON,

            POWER ̲UP ̲KEY ̲ON ? - C̲R̲E̲A̲T̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲O̲N̲N̲E̲C̲T̲I̲O̲N̲S̲
         (WDP ̲VDU ̲CON,
                                                                 
                                                                 
                                                                 
                                                                 
                                                                 
                                                                 
                                                                 
                                                                 
                                                                 TERMINALS)

            KEY ̲OFF, POWER ̲DOWN,

            FAILURE? - MAP ̲WDP ̲VDU EQ TRUE? - D̲I̲S̲M̲A̲N̲T̲L̲E̲
         ̲W̲D̲P̲ ( )(WDP ̲STATUS ̲REC)

                  S̲E̲N̲D̲ ̲C̲M̲I̲ (VDU DOWN)

                  D̲I̲S̲M̲A̲N̲T̲L̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲O̲N̲


            OTHERS ?   SEND ̲GARBLE 

         END CASE

         END HANDLE ̲WDP ̲VDU




















              Fig. 4.2.8.4.2.5.d-1


4.2.8.4.2.5.e P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲D̲I̲S̲M̲A̲N̲T̲L̲E̲ ̲W̲D̲P̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             Dismantle the connections from the MAP
             ̲CON and down.  The Booleans in the WDP
             ̲STATUS ̲REC are update for each "terminal"
             dismantled.

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.4.2.5.e-1


         PROCEDURE DISMANTLE ̲WDP
         WDP ̲STATUS ̲REC.VDU ̲STATUS EQ FALSE ?
         S̲E̲N̲D̲ ̲C̲M̲I̲ (VDU ̲DOWN)
         D̲I̲S̲M̲A̲N̲T̲L̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲O̲N̲
         WDP ̲STATUS ̲REC.VDU ̲STATUS = FALSE
         WDP ̲STATUS ̲REC.WDP ̲ROP ̲STATUS EQ FALSE ?
         S̲E̲N̲D̲ ̲C̲M̲I̲ (ROP ̲DOWN)
         CASE DISMANTLE (WDP ̲ROP ̲CON) (CC):  ERROR ̲OK
            ERROR ? - ANALYZE ̲ERROR (CC, 1, HW)
                 REPORT ̲ERROR (WAMCO ̲CC, WARP)
         END CASE
         WDP ̲STATUS ̲REC.WDP ̲ROP ̲STATUS = FALSE
         WDP ̲STATUS ̲REC.WDP ̲STATUS NE TRUE ?
         C̲A̲N̲C̲E̲L̲.̲R̲E̲S̲ ̲T̲I̲M̲E̲O̲U̲T̲S̲ (PRC ̲Q, TIM ̲SUBQ, 1, 1)
         WAIT ̲OPSEM (LONG ̲OS) (OP)
         OP.CMD ̲TYPE = WAMCO ̲INT ̲CMD
         OP.CMD = STOP
         SIGNAL ̲OP ̲SFM (WDP ̲MON ̲OS)(OP)
         WDP ̲STATUS ̲REC.WDP ̲STATUS = FALSE
         CASE DISMANTLE (WDP ̲CON)(CC):  ERROR ̲DONE
              ERROR ? - ANALYZE ̲ERROR (CC, 1, HW)
                   REPORT ̲ERROR (WAMCO ̲CC, WARP)
         END CASE
         CASE DISMANTLE (PHYS ̲WDP ̲CON)(CC): ERROR DONE
              ERROR ? - ANALYZE ̲ERROR (CC, 1, HW)
                   REPORT ̲ERROR (WAMCO ̲CC, WARP)
         END CASE
         C̲R̲E̲A̲T̲E̲ ̲T̲R̲E̲E̲
         END DISMANTLE ̲WDP



                                 Fig. 4.2.8.4.2.5.e-1


4.2.8.4.2.5.f P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲D̲I̲S̲M̲A̲N̲T̲L̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲O̲N̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The connections to the WDP ̲VDU terminals
             and the WDP ̲VDU are dismantled.

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.2.5.f-1



         PROCEDURE DISMANTLE ̲WDP ̲VDU ̲CON


         REMOVE ̲TERMINAL (CONFIG ̲SPLIT) (CC):  ERROR
         ̲OK

         REMOVE ̲TERMINAL (COMMAND ̲SPLIT) (CC):  ERROR
         ̲OK

         MAXCOUNT = NUMBER ̲OF ̲SPLITS

         COUNT = 0


         LOOP

            COUNT = COUNT + 1

            CASE DISMANTLE (WDP ̲SPLIT ̲CON ̲BUF (COUNT))(CC):
          ERROR DONE

              ERROR ? - ANALYZE ̲ERROR (CC)

            END CASE

            COUNT EQ MAXCOUNT ?  EXIT

         END LOOP

         END DISMANTLE ̲WDP ̲VDU ̲CON




















              Fig. 4.2.8.4.2.5.f-1


4.2.8.4.2.5.g P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲C̲R̲E̲A̲T̲E̲ ̲M̲A̲P̲ ̲E̲N̲V̲I̲R̲O̲N̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             Sends "who am I" report to the WDP:

             -   if no Answer create "ONLINE ̲A TREE"
                 from the MAP device (only ACTIVE PU).

             -   if Answer (PU ̲NO), create "ONLINE
                 ̲B TREE" from the WDP ̲SUB ̲DEVICE (only
                 ACTIVE PU) update the WDP ̲STATUS ̲REC.


             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.2.5.g-1


         PROCEDURE CREATE ̲MAP ̲ENVIRON


         S̲E̲N̲D̲ ̲W̲H̲O̲ ̲A̲M̲ ̲I̲ ( ) (PU ̲NO)


         PU ̲NO EQ NIL? - D̲I̲S̲M̲A̲N̲T̲L̲E̲ ̲T̲R̲E̲E̲

                    WAMCO EQ STANDBY ̲W?

                    C̲R̲E̲A̲T̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲O̲N̲N̲ (CONNECTION.MAP
                 ̲CON)


         WAMCO.S EQ STANDBY.W ?

         S̲E̲N̲D̲ ̲C̲O̲N̲F̲I̲G̲

         C̲R̲E̲A̲T̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲O̲N̲N̲ (WDP ̲VDU ̲CON,TERMINAL
         ̲S)



                 start of WAMCO coroutines"

         R̲E̲S̲E̲R̲V̲E̲ ̲T̲I̲M̲E̲O̲U̲T̲S̲ (PERIODIC, PRC ̲Q, TIM ̲SUBQ,
         1, 1)

         WAIT ̲OPSEM (LONG ̲OS) (OP)

         OP.CMD ̲TYPE = WAMCO ̲INIT ̲CMD

         OP.CMD = START ̲UP ̲INT

         SIGNAL ̲OPSEM (WAMCO ̲MON ̲OS, OP)


         END CREATE ̲MAP ̲ENVIRON












              Fig. 4.2.8.4.2.5.g-1



4.2.8.4.2.5.h P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲C̲R̲E̲A̲T̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲O̲N̲N̲E̲C̲T̲I̲O̲N̲S̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             If the procedure is part of the start
             active command from the CFH, the VDU environment
             is specified to the FORMAT ̲HANDLER.

             Hereafter, the procedure is the same as
             for online operation (CMD commands):

             -   create the terminals (splits)
             -   offer the connections
             -   init the configuration split
             -   output the configuration
             -   send-CMI start

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.2.5.h-1






         PROCEDURE CREATE ̲WDP ̲VDU ̲CONNECTIONS (DEVICE
         ̲CON:  IFCB ̲INDEX,
                                               (VDU
                                      ̲STATE:   VDU
                                      ̲STATES)

         VDU ̲STATE NE INI ̲FORMAT ?

         INIT ̲FORMAT (WDP ̲SPLITS, FORMATS, SSC ̲FORMATS)
         (CC)


         DEFINE ̲FORMAT ̲AREA (SPLIT ̲COMMAND ̲REC) (INTERFACE
         ̲NO, CC)

         COMMAND ̲SPLIT = INTERFACE ̲NO

         DEFINE ̲FORMAT ̲AREA (SPLIT ̲CONFIG ̲REC) (INTERFACE
         ̲NO, CC)

         CONFIG ̲SPLIT = INTERFACE ̲NO

         DEFINE ̲FORMAT ̲AREA (SPLIT ̲FORMAT ̲REC)(INTERFACE
         ̲NO,CC)

         FORMAT ̲SPLIT = INTERFACE ̲NO

         VDU ̲STATE EQ TERMINALS ?

         C̲R̲E̲A̲T̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ (DEVICE ̲CON)(WDP ̲VDU ̲CON)

         C̲R̲E̲A̲T̲E̲ ̲V̲D̲U̲ ̲T̲E̲R̲M̲I̲N̲A̲L̲S̲ (WDP ̲VDU ̲CON, 1, WDP
         ̲VDU ̲P)(WDP ̲SPLIT ̲CON ̲BUF)

         O̲F̲F̲E̲R̲ ̲V̲D̲U̲ ̲C̲O̲N̲N̲E̲C̲T̲I̲O̲N̲S̲(WDP ̲SPLIT ̲CON ̲BUF,COUNT,WDP
         ̲VDU ̲ACC)
                                                                       (OFFER.CON
                                                                       ̲BUF)

         FORMAT ̲INIT ̲TERMINAL(CONFIG ̲SPLIT,TMS ̲ID,WDP
         ̲SPLIT ̲CONF ̲BUF (1),
                             WDP ̲SPLIT ̲CONF ̲BUF (2))
                            (CC):  ERROR ̲OK

         FORMAT ̲INIT ̲TERMINAL(COMMAND ̲SPLIT,TMS ̲ID,WDP
         ̲SPLIT ̲CONF ̲BUF(3)
                             WDP ̲SPLIT ̲CONF ̲BUF (4))(CC):
                            ERROR ̲OK

         C̲O̲N̲F̲ ̲D̲I̲S̲P̲L̲A̲Y̲ (DISPLAY ̲ALL)

         S̲E̲N̲D̲ ̲C̲M̲I̲ (START)


         END CREATE ̲WDP ̲VDU ̲CONNECTIONS






              Fig. 4.2.8.4.2.5.h-1


4.2.8.4.3    W̲D̲P̲ ̲M̲O̲N̲I̲T̲O̲R̲I̲N̲G̲ ̲R̲E̲P̲O̲R̲T̲



4.2.8.4.3.1  F̲u̲n̲c̲t̲i̲o̲n̲a̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

             The module collects the data sent from
             the watchdog (WDP) and sends on the commands
             to the Configuration Handler CFH.



4.2.8.4.3.2 I̲n̲t̲e̲r̲f̲a̲c̲e̲

             N/A

             "started of the coroutine
             "receive operational command, which
             "sends a start (close) command to
             "the WDP ̲MON ̲OS



4.2.8.4.3.3 C̲o̲m̲p̲o̲n̲e̲n̲t̲s̲

             The following components are included:

             -   WDP ̲MONITORING.REPORT
             -   READ ̲LINE
             -   CLEAN ̲IO



4.2.8.4.3.4 D̲a̲t̲a̲ ̲D̲e̲s̲c̲r̲i̲p̲t̲i̲o̲n̲

             a1) T̲y̲p̲e̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 LONG ̲OP ̲TYPE;                                         4.1.4.4.b
                 BLE,
                 FILADD;                                               DBD

             a2) D̲a̲t̲a̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 WDP ̲MON ̲OS,
                 LONG ̲OS,
                 CFH ̲OS;                                               4.1.4.4
                                                                       a
                 WDP ̲CON;             4.1.4.2.1 a

             b)  E̲x̲t̲e̲r̲n̲a̲l̲ ̲D̲a̲t̲a̲



             c)  L̲o̲c̲a̲l̲ ̲D̲a̲t̲a̲

                 VAR COUNT,
                     MAXCOUNT,
                     INDEX:  INTEGER



                 VAR WAMBLE = ARRAY (1..2) OF BLE

                 VAR WAM ̲FILADD = ARRAY (1..2) OF FIL
                     ADD

                 VAR WAMCO ̲OP = ARRAY (1..2) OF OPERATION
                     %
                 ASSO ̲OP  = ARRAY (1..2) OF OPERATION
                 %

                 TYPE       OPERATION % :                              POINTER


4.2.8.4.3.5  W̲D̲P̲ ̲M̲O̲N̲I̲T̲O̲R̲I̲N̲G̲ ̲R̲E̲P̲O̲R̲T̲ ̲D̲e̲s̲i̲g̲n̲

             The module is implemented as a coroutine
             with the main procedure WDP ̲MONITORING
             ̲REPORT (a) and the sub procedures READ
             ̲LINE (b), CLEAN ̲ID c) see fig. 4.3.8.3-4.



4.2.8.4.3.5.a P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲W̲D̲P̲ ̲M̲O̲N̲I̲T̲O̲R̲I̲N̲G̲ ̲R̲E̲P̲O̲R̲T̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             Receive the operation from WAMCO ̲MON ̲OS.

             The operations are:

             -   start;  initiate io operation
             -   io operation; send to CFH ̲OS
             -   stop dismantle io operation

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.3.5.a-1


         PROCEDURE WDP ̲MONITORING ̲REPORT

         LOOP "Main

            WAIT ̲OPSEM (WDP ̲MON ̲OS)(OP:  LONG ̲OP ̲TYPE)

            OP.CMD ̲TYPE NEWAMCO ̲INT ̲CMD OR
                                                                       ?
                                                                       
                                                                       COPSY
                                                                       ̲SEND
                                                                       ̲GARBLE
                                                                       (CONTINUE)
            OP.CMD NE START ̲UP ̲INIT               
                                )

            COUNT = 0, MAX ̲COUNT = 2

            LOOP "Init

              COUNT = COUNT + 1

              OP.CMD ̲TYPE = IO ̲OP, OP.CMD = COUNT

              ASSO ̲OP (COUNT) = OP %

              WAIT ̲OPSEM (LONG ̲OS)(READ ̲OP:  LONG ̲OP
         ̲TYPE)

              WAMCO ̲OP(COUNT) = READ ̲OP %

              WAMBLE (COUNT) = READ ̲OP.CMD ̲TYPE %

              INIT ̲READBYTES (WDP ̲CON,WAM ̲FILADD(COUNT),WAMBLE(COUNT),
                                      ASSO ̲OP(COUNT))

              COUNT EQ MAX ̲COUNT ? EXIT

              WAIT ̲OPSEM (LONG ̲OS)(OP:  LONG ̲OP ̲TYPE)

            END LOOP "init

            LOOP "Associate

              ASSOCIATE (WDP ̲MON ̲OS, ASSO ̲OP (COUNT))

              COUNT = COUNT - 1

              COUNT EQ 0 ?   EXIT

            END LOOP "Associate

            R̲E̲A̲D̲ ̲L̲I̲N̲E̲

         END LOOP MAIN

         END WDP ̲MONITORING ̲REPORT

              Fig. 4.2.8.4.3.5.a-1


4.2.8.4.3.5.b P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲R̲E̲A̲D̲ ̲L̲I̲N̲E̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The READ ̲LINE awaits the operations sent
             to the WDP ̲MON ̲OS.

             The operations to be accepted are:

             -   io operation
             -   stop operation

             The io operation is sent on to the CFH
             ̲OS and another IO call is set up.

             The stop operation results in a clean
             up (c) and a return to the main procedure
             (a).

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.3.5.b-1



         PROCEDURE READ ̲LINE

         LOOP    "UNTIL STOP ̲INT

            WAIT ̲OPSEM (WDP ̲MON ̲OS)(OP:  LONG ̲OP ̲TYPE)

            NEW ̲OP = OP, INDEX = OP.CMD

            CASE NEW ̲OP.CMD ̲TYPE OF:

              IO ̲OP ? - WAIT ̲SYSTEM ̲CALL (NEW ̲OP)(
                            )

                   SIGNAL ̲OPSEM (CFH ̲OS,WAMCO ̲OP(INDEX))

                   WAIT ̲OPSEM (LONG ̲OS)(OP:  LONG ̲OP
                 ̲TYPE)

                   WAM ̲BLE (INDEX) = OP.CMD ̲TYPE

                   WAMCO ̲OP (INDEX) = OP

                   INIT ̲READBYTES (WDP ̲CON,WAM ̲FILADD(INDEX)
                                         WAM ̲BLE (INDEX),
                                      ASSO ̲OP(COUNT)

                   ASSOCIATE (WDP ̲MON ̲OS, ASSO ̲OP(COUNT))


              WAMCO ̲INT ̲CMD ? - NEW ̲OP.CMD EQ STOP
         ̲INT ? - CLEAN ̲IO

                                                                        
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        EXIT
                                                                        ̲FL
                                                                        =
                                                                        TRUE

              OTHERS ? SEND ̲GARBLE

            END CASE

            EXIT ̲FL EQ TRUE ?   EXIT

         END LOOP

         END READ ̲LINE








              Fig. 4.2.8.4.3.5.b-1


4.2.8.4.3.5.c P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲C̲L̲E̲A̲N̲ ̲I̲O̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The outstanding IO requests are cancelled
             and the operations used for IO are returned
             to the pol LONG ̲OS.

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.4.5.c-1


         PROCEDURE CLEAN ̲IO


         COUNT = 0


         MAXCOUNT = 2


         LOOP


            COUNT = COUNT + 1

            CANCEL ̲SYSTEM CALL (ASSO ̲OP(COUNT))

            WAIT ̲SYSTEM ̲CALL (ASSO ̲OP(COUNT))

            SIGNAL ̲OPSEM (LONG ̲OS, ASSO ̲OP(COUNT))

            SIGNAL ̲OPSEM (LONG ̲OS, WAMCO ̲OP(COUNT))

            COUNT EQ MAXCOUNT ?   EXIT

         END LOOP

         END CLEAN ̲IO




















              Fig. 4.2.8.4.4.5.c-1


4.2.8.4.5    K̲E̲E̲P̲ ̲A̲L̲I̲V̲E̲



4.2.8.4.5.1 F̲u̲n̲c̲t̲i̲o̲n̲a̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

             Send a "Keep alive" message to the WDP
             once a second.

             Each minute the time of day is:

             -   included in the keep alive message
             -   checkpointed on disk
             -   sent to the WDP ̲VDU command split



4.2.8.4.5.2 I̲n̲t̲e̲r̲f̲a̲c̲e̲

             N/A
             "The coroutine waits on a timeout as
             "a start command.  A cancel timeout QFL
             "is used as a stop command



4.2.8.4.5.3 C̲o̲m̲p̲o̲n̲e̲n̲t̲s̲

             The following components are included:

             -   KEEP ALIVE
             -   SERVE ̲TIME ̲EVENTS
             -   UPDATE ̲WDP ̲VDU ̲CLOCK



4.2.8.4.5.4 D̲a̲t̲a̲ ̲D̲e̲s̲c̲r̲i̲p̲t̲i̲o̲n̲

             a1) T̲y̲p̲e̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 ATTRIBUTES
                 QUEUE ̲REFERENCE
                 BLE
                 FILEADD

             a2) D̲a̲t̲a̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 TIME ̲ATTRIBUTES      ref. CSF 4.1.7.2.2.3
                 WDP ̲BUFFER           ref. SSC 4.1.7
                 COMMAND ̲SPLIT ̲FIELDS

         …86…1…02…        …02…   …02…   …02…   …02…      …02…         …02…        
                          
         b)  E̲x̲t̲e̲r̲n̲a̲l̲ ̲D̲a̲t̲a̲

             c)  L̲o̲c̲a̲l̲ ̲D̲a̲t̲a̲

                 VAR TOD:   BOOLEAN
                 VAR TIME ̲COUNT:  INTEGER
                 VAR KEEP ̲ATTRIBUTES:  ATTRIBUTES
                 CONST ONE ̲MINUTE = 59
                 VAR KEEP ̲ALIVE ̲QUEUE:  QUEUE ̲REFERENCE
                 INIT KEEP ̲ALIVE ̲QUEUE = PRC ̲Q, TIM
                 ̲SUBQ
                 VAR KEEP ̲BUF:  WDP ̲BUFFER
                 VAR WDP ̲BLE:  BLE, WDP ̲FILEADD



4.2.8.4.4.5 K̲E̲E̲P̲ ̲A̲L̲I̲V̲E̲ ̲D̲e̲s̲i̲g̲n̲

             The KEEP ̲ALIVE module is designed as a
             coroutine with the mainprocedure (a) KEEP
             ̲ALIVE and the subprocedures (b) START
             ̲SEND ̲KEEP ̲ALIVE, (c) TIME ̲EVENT, (d) UPDATE
             ̲WDP ̲VDU ̲CLOCK.

             The procedures are shown on fig. 4.2.8.3-5.



4.2.8.4.4.5.a P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲K̲E̲E̲P̲ ̲A̲L̲I̲V̲E̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             Wait for timeouts and send a keep alive
             message.

             SUBTYPE = TIME OUT ?

             -   increment TIME-COUNT
             -   if TIME ̲COUNT = ONE ̲MIN, TOO = TRUE
             -   call SERVE ̲TIME ̲EVENTS

             SUBTYPE = TIMEOUT ̲CANCELLED ?

             -   TIME ̲COUNT = ONE ̲MIN-1

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.4.5.a-1


         PROCEDURE KEEP ̲ALIVE

         LOOP "Main

            CASE RECEIVE ̲FIRST ̲QEL (TRUE, KEEP ̲ALIVE
         ̲QUEUE)
                                 (KEEP ̲ATTRIBUTES,
                            QEL, SUBQUEUE, CC): 
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       ERROR
                                                                       ̲OK

              ERROR ? ANALYZE ̲ERROR (CC, 1, HW)
                 REPORT ̲ERROR (WAMCO ̲CC, WARP)

            END CASE

            KEEP ̲ATTRIBUTES.OBJECT ̲TYPE NE TIME ̲OUT
                      .MAINTYPE    NE TIME ̲OUT    ?
                          COPSY ̲SEND ̲GARBLE 
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       (CONTINUE)
                                                                       

                      .FLAGS       NE 1           
                                        )

            CASE KEEP ̲ATTRIBUTES.SUBTYPE OF:

               TIME ̲OUT ? - FIRST ̲TIMEOUT EQ TRUE ?
         - S̲E̲N̲D̲ ̲S̲T̲A̲R̲T̲ ̲K̲E̲E̲P̲ ̲A̲L̲I̲V̲E̲

                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       
                                                                       FIRST
                                                                       ̲TIMEOUT
                                                                       =
                                                                       FALSE

                       TIME ̲COUNT = TIME ̲COUNT + 1

                       TIME ̲COUNT NE ONE ̲MIN ? - TOD
                     = FALSE

                       TOD = TRUE, TIME ̲COUNT = 0

                       S̲E̲R̲V̲E̲ ̲T̲I̲M̲E̲ ̲E̲V̲E̲N̲T̲S̲ (TOD)

              TIME ̲OUT ̲CANCELLED ? - TIME ̲COUNT = ONE
         ̲MIN-1
                                   FIRST ̲TIMEOUT =
                            TRUE

              OTHERS ? - SEND ̲GARBLE


            END CASE

         END LOOP








              Fig. 4.2.8.4.4.5.a-1


4.2.8.4.4.5.b P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲S̲T̲A̲R̲T̲ ̲S̲E̲N̲D̲ ̲K̲E̲E̲P̲ ̲A̲L̲I̲V̲E̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             A command is sent to the WDP indicating
             that from now on, keep alive messages
             are to be expected.

             F̲l̲o̲w̲g̲r̲a̲m̲

             N/A



4.2.8.4.4.5.c P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲S̲E̲R̲V̲E̲ ̲T̲I̲M̲E̲ ̲E̲V̲E̲N̲T̲S̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             If TOD = TRUE and WAMCO = ACTIVE:

             -   read time
             -   send keep alive with time included
             -   checkpoint time
             -   update WDP ̲VDU clock
             
             If TOD = FLASE or WAMCO = STANDBY then
             only:

             -   send keep alive

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. fig. 4.2.8.4.4.5.c-1


         PROCEDURE SERVE ̲TIME ̲EVENTS (TOD:  BOOLEAN)

         WAMCO EQ STANDBY OR
         TOD EQ FALSE         ? BYTE ̲LENGTH = KEEP
         ̲ALIVE ̲SIZE

         BYTE ̲LENGTH ̲KEEP ̲ALIVE ̲SIZE + TIME ̲SIZE

         READ ̲TIME (F ̲DTG ̲TYPE)(KEEP ̲BUF.INF)


         UPDATE ̲WDP ̲VDU ̲CLOCK (KEEP ̲BUF.INF)


         CHECKPOINT ̲TIME ̲ON ̲DISK (KEEP ̲BUF.INF)



         WDP ̲BLE.BYTE ̲LENGTH = BYTE ̲LENGTH

         WDP ̲BLE.ADDRESS = KEEP ̲BUF

         CASE APPENDBYTES (WDP ̲FILEADD, WDP ̲BLE, WDP
         ̲CON)
                     (CC):  ERROR ̲OK

              ERROR ? - ANALYZE ̲ERROR (CC, 1, HW)
                   REPORT ̲ERROR (WAMCO ̲CC, WARP)

         END CASE


         END SERVE ̲TIME ̲EVENTS

















              Fig. 4.2.8.4.4.5.c-1


4.2.8.4.4.5.d P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲U̲P̲D̲A̲T̲E̲ ̲W̲D̲P̲ ̲V̲D̲U̲ ̲C̲L̲O̲C̲K̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             This procedure is only called if WAMCO
             = ACTIVE.

             The procedure updates via the format HANDLER
             the WDP ̲VDU ̲CLOCK in the first line of
             the COMMAND SPLIT.

             F̲l̲o̲w̲g̲r̲a̲m̲

             N/A



4.2.8.5  C̲o̲m̲m̲o̲n̲ ̲W̲A̲M̲C̲O̲ ̲d̲a̲t̲a̲

             The data used in WAMCO is either local
             to the modules or common to the SSC package.



4.2.8.6  C̲o̲m̲m̲o̲n̲ ̲W̲A̲M̲C̲O̲ ̲P̲r̲o̲c̲e̲d̲u̲r̲e̲s̲

             Because some of the procedures marked
             as common are used by the CFH during start
             up of the CAMPS system and hereafter adopted
             by the WAMCO, these procedures have been
             described in section 4.1.5.

             The following common procedures are only
             used by WAMCO:

             -   Reserve Timeouts
             -   Cancel Timeouts



4.2.8.6.1    R̲e̲s̲e̲r̲v̲e̲ ̲T̲i̲m̲e̲o̲u̲t̲s̲



4.2.8.6.1.1 F̲u̲n̲c̲t̲i̲o̲n̲a̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

             Requests the Timer Monitor for periodical
             or single timeouts.





4.2.8.6.1.2 I̲n̲t̲e̲r̲f̲a̲c̲e̲

             C̲a̲l̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

             a)  RESERVE ̲TIMEOUTS (TIMEOUT:  TIMEOUT
                 ̲TYPE
                                         MAIN ̲QUEUE:
                                       CAPABILITY ̲INDEX
                                         SUB ̲QUEUE:
                                         TIME:  INTEGER
                                         EVENT ̲ID:
                                       0..15)

             b)  RESERVE ̲TIMEOUTS (R1, R2, R3, R4,
                 R5, R6)

             R̲e̲g̲i̲s̲t̲e̲r̲ ̲C̲o̲n̲v̲e̲n̲t̲i̲o̲n̲

             C̲a̲l̲l̲ ̲R̲e̲g̲i̲s̲t̲e̲r̲s̲

             R1  TIMEOUT
             R2  MAIN ̲QUEUE
             R3  SUB ̲QUEUE
             R4  TIME
             R5  EVENT ̲ID

             R̲e̲l̲e̲a̲s̲e̲ ̲R̲e̲g̲i̲s̲t̲e̲r̲s̲

             N/A



4.2.8.6.1.3 D̲a̲t̲a̲ ̲D̲e̲s̲c̲r̲i̲p̲t̲i̲o̲n̲ 

             a1) T̲y̲p̲e̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 REQUEST ̲TIME                                    DBD
                                                                 TMON

             a2) D̲a̲t̲a̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 TIME OUT,
                 MAIN ̲QUEUE,
                 SUB ̲QUEUE,
                 TIME,
                 EVENT ̲ID:  I/F data

             b)  E̲x̲t̲e̲r̲n̲a̲l̲ ̲D̲a̲t̲a̲

             c)  L̲o̲c̲a̲l̲ ̲D̲a̲t̲a̲

                 VAR TIMMON ̲REG:  REQUEST ̲TIME


4.2.8.6.1.4 P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲R̲E̲S̲E̲R̲V̲E̲ ̲T̲I̲M̲E̲O̲U̲T̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The TIMMON ̲REC is completed and sent to
             the TMON.

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. Fig. 4.2.8.6.1.4-1


         PROCEDURE RESERVE ̲TIMEOUTS(TIMEOUT,MAIN ̲QUEUE,SUB
         ̲QUEUE,
                                        TIME:  INTEGER,
                                      EVENT ̲ID: 0..15)

            TIMMON ̲REG.TIMEOUT = TIMEOUT

            TIMMON ̲REC.QUEUE = MAINQUEUE, SUBQUEUE

            TIMMON ̲REC.TIME = TIME

            TIMMON ̲REC.EVENT ̲ID = EVENT ̲ID

            REQUEST ̲TIMEOUT (TIMMON ̲REC) (CC):  ERROR
         ̲OK


            END REQUEST ̲TIMEOUTS
































               Fig. 4.2.8.6.1.4-1


4.2.8.6.2    C̲a̲n̲c̲e̲l̲ ̲R̲e̲c̲e̲i̲v̲e̲d̲ ̲T̲i̲m̲e̲o̲u̲t̲



4.2.8.6.2.1 F̲u̲n̲c̲t̲i̲o̲n̲a̲l̲ ̲S̲p̲e̲c̲i̲f̲i̲c̲a̲t̲i̲o̲n̲

             Request the Timer Monitor to cancel the
             specified timeout.



4.2.8.6.2.2 I̲n̲t̲e̲r̲f̲a̲c̲e̲

             a)  CANCEL ̲RES ̲TIMEOUTS (TIMEOUT:    
                 TIMEOUT ̲TYPE;
                                            MAIN ̲QUEUE:
                                       CAPABILITY ̲INDEX;
                                            SUB ̲QUEUE:
                                        SUBQUEUE ̲INDEX
                                            TIME: 
                                            INTEGER
                                            EVENT ̲ID:
                                         0..15)

             b)  CANCEL ̲RES ̲TIMEOUTS (R1, R2, R3, R4,
                 R5, R6)

             R̲e̲g̲i̲s̲t̲e̲r̲ ̲C̲o̲n̲v̲e̲n̲t̲i̲o̲n̲

             C̲a̲l̲l̲ ̲R̲e̲g̲i̲s̲t̲e̲r̲s̲

             R1  TIMEOUT
             R2  MAIN ̲QUEUE
             R3  SUB ̲QUEUE
             R4  TIME
             R5  EVENT ̲ID

             R̲e̲t̲u̲r̲n̲ ̲R̲e̲g̲i̲s̲t̲e̲r̲s̲

             N/A



4.2.8.6.2.3 D̲a̲t̲a̲ ̲D̲e̲s̲c̲r̲i̲p̲t̲i̲o̲n̲

             a1) T̲y̲p̲e̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 REQUEST ̲TIME                                    DBD
                                                                 TMON

             a2) D̲a̲t̲a̲ ̲R̲e̲f̲e̲r̲e̲n̲c̲e̲s̲

                 TIMEOUT,
                 MAIN ̲QUEUE,
                 SUB ̲QUEUE,
                 TIME,
                 EVENT ̲IO:  I/F data



             b)  E̲x̲t̲e̲r̲n̲a̲l̲ ̲D̲a̲t̲a̲

             c)  L̲o̲c̲a̲l̲ ̲D̲a̲t̲a̲

                 VAR C ̲TIMMON ̲REG:  REQUEST ̲TIME



4.2.8.6.2.4 P̲r̲o̲c̲e̲d̲u̲r̲e̲ ̲C̲A̲N̲C̲E̲L̲ ̲R̲E̲S̲ ̲T̲I̲M̲E̲O̲U̲T̲S̲

             N̲a̲r̲r̲a̲t̲i̲v̲e̲

             The C ̲TIMMON ̲REC is completed and the
             TMON is requested to cancel the outstanding
             timeout.

             F̲l̲o̲w̲g̲r̲a̲m̲

             Ref. Fig. 4.2.8.6.2.4-1







         PROCEDURE CANCEL ̲RES ̲TIMEOUTS(TIMEOUT,MAINQUEUE,SUBQUEUE,
         TIME,
                                                                 EVENT
                                                                 ̲ID)


         C ̲TIMMON ̲REC.TIMEOUT = TIMEOUT


         C ̲TIMMON ̲REC.QUEUE.MAINQUEUE = MAINQUEUE

         C ̲TIMMON ̲REC.QUEUE ̲SUBQUEUE = SUBQUEUE

         C ̲TIMMON ̲REC.TIME = TIME


         C ̲TIMMON ̲REC.EVENT ̲ID = EVENT ̲ID


         CANCEL ̲TIMEOUT (C ̲TIMMON ̲REC)(CC):  ERROR
         ̲OK



         END CANCEL ̲PERIODICAL ̲TIMEOUTS


























               Fig. 4.2.8.6.2.4-1


4.2.8.7  S̲u̲b̲p̲a̲c̲k̲a̲g̲e̲ ̲I̲n̲t̲e̲r̲f̲a̲c̲e̲

             Ref. sec. 4.1.7.3.