DataMuseum.dk

Presents historical artifacts from the history of:

RC3500

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

See our Wiki for more about RC3500

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download

⟦6a6cb80ec⟧ TextFileVerbose

    Length: 134400 (0x20d00)
    Types: TextFileVerbose
    Names: »tsatclst«

Derivation

└─⟦a41ae585a⟧ Bits:30001842 SW-save af projekt 1000, Alarm-system
    └─⟦72244f0ef⟧ 
        └─⟦this⟧ »tsatclst« 

TextFileVerbose

\f

outlst      81.06.24.   17.09.                                                    page     1

   10    1        PROCESS atconnector(
   20    2          op_sem               : sempointer;
   30    3          VAR
   40    4          main_sem             ,              (* Pointer to ATC's main semaphore.
   50    5          -                                   All messages are received here *)
   60    6          queue_sem            : !ts_pointer; (* Pointers to the queue semaphore, that
   70    7          -                                   holds control an test messages while ATC is busy *)
   80    8          VAR
   90    9          ath_sem              ,              (* Pointer to the main semaphore of ATH *)
  100   10          driver_sem           ,              (* Pointer to main semaphore of LAM driver *)
  110   11          com_pool             : !sempointer; (* Pointer to the semaphore that holds
  120   12          -                                   the vacant message resources of the TS *)
  130   13          VAR
  140   14          activity             : connector_state;
  150   15          VAR
  160   16          delay                : integer;
  170   17          <*p
  180   18          VAR
  190   19          node_test_frequency  : !integer;
  200   20          VAR
  210   21          traffic_counter      : integer;
  220   22          p*>
  230   23          VAR
  240   24          dc_macro             ,              (* Macro address of own dc *)
  250   25          ts_macro             : !macroaddr;  (* Macro address of own ts *)
  260   26          own_addr             : !integer;    (* Micro address of this ATC inarnation *)
  270   27          channel_no           : !byte );     (* i/o channel number used by this ATC incarnation *)
  280   28          
  290   29          
  300   30        CONST
  310   31          version              = "vers  3.12 /";
  320   32           
\f

outlst      81.06.24.   17.09.                                                    page     2

 1010   33            (*********************************************************************************
 1020   34            *
 1030   35            * description      : The purpose and function of the AT_CONNECTOR is mainly to
 1040   36            *                    run the protocol with an AT. The ATC is the master of
 1050   37            *                    this communication.
 1060   38            *                    The state of the transmission line is monitored by ATC
 1070   39            *                    and alarms concerning the conditions of transmission are
 1080   40            *                    signalled to PAC or DC.
 1090   41            *                    Furthermore commands originating from DC and AC are executed
 1100   42            *                    and alarms from AT are signalled to an AC.
 1110   43            *                    AT_CONNECTOR participates in the module supervision in
 1120   44            *                    the TS.
 1130   45            *
 1140   46            * externals        : check5
 1150   47            *                    testopen
 1160   48            *                    testout
 1170   49            *                    receipt_message
 1180   50            *                    reject_message
 1190   51            *
 1200   52            * environment      : alarm environment (latest version)
 1210   53            *
 1220   54            * author           : NLA
 1230   55            *
 1240   56            *********************************************************************************)
 1250   57           
\f

outlst      81.06.24.   17.09.                                                    page     3

 2010   58            (*********************************************************************************
 2020   59            *
 2030   60            * PSEUDO CODE of AT_CONNECTOR
 2040   61            *
 2050   62            * process atconnector
 2060   63            *
 2070   64            * constant, type and variable declaration parts
 2080   65            *   1) shielded types
 2090   66            *   2) telegrams from TS to AT
 2100   67            *   3) telegrams from AT to TS
 2110   68            *   4) state telegrams from AT to TS
 2120   69            *   5) operation codes and formats
 2130   70            *   6) watch central table and management of it
 2140   71            *   7) management of states and protocol
 2150   72            *   8) supervision of transmission line
 2160   73            *   9) miscellaneous
 2170   74            *
 2180   75            * forward declaration part
 2190   76            *
 2200   77            * subroutine declaration part
 2210   78            *
 2220   79            *
 2230   80            * begin
 2240   81            *
 2250   82            *   initialize;
 2260   83            *
 2270   84            *   restrict_protocol;
 2280   85            *     <* end of initialize sequence *>
 2290   86            *
 2300   87            *   repeat <* forever *>
 2310   88            *
 2320   89            *     if conversation = idle then
 2330   90            *      begin
 2340   91            *        if open( queue ) then <* preprocess queue *>
 2350   92            *         begin
 2360   93            *           wait( msg, queue );
 2370   94            *           initiate_conversation <* messages in the queue always involve AT *>
 2380   95            *         end
 2390   96            *        else
 2400   97            *         begin
 2410   98            *           sendtimer( delay_msg );
 2420   99            *           send_telegram( poll, 0 )
 2430  100            *         end
 2440  101            *      end;
 2450  102            *
 2460  103            *     wait( msg, main );
\f

outlst      81.06.24.   17.09.                                                    page     4

 2470  104            *
 2480  105            *     if ownertest( driver_pool, msg ) then
 2490  106            *      driver_msg :=: msg
 2500  107            *     else
 2510  108            *      case message_origin of
 2520  109            *
 2530  110            *        ATH:
 2540  111            *          begin
 2550  112            *            if operation_code in (.control, testi1, testi2, teste.) then
 2560  113            *             signal( msg, queue )
 2570  114            *            else
 2580  115            *             read_write( msg ) <* AT not involved, execute at once *>
 2590  116            *          end;
 2600  117            *
 2610  118            *        DRIVER:
 2620  119            *         if transmission_error and limit_overflow then
 2630  120            *           signal( call_limit_alarm, ATH )
 2640  121            *          else
 2650  122            *           begin
 2660  123            *             if limit_underflow then
 2670  124            *              signal( recall_limit_alarm, ATH );
 2680  125            *
 2690  126            *             case AT_operation_code of
 2700  127            *
 2710  128            *              p_ack: conversation:= idle;
 2720  129            *
 2730  130            *              au_alarm:
 2740  131            *               if no_of_bytes = AVC_block_lth then
 2750  132            *                signal( au_alarm, AVC )
 2760  133            *               else
 2770  134            *                send_telegram( poll, 0 );
 2780  135            *
 2790  136            *              addr:
 2800  137            *               begin
 2810  138            *                 search_address_code;
 2820  139            *                 send_telegram( poll, 0 )
 2830  140            *               end;
 2840  141            *
 2850  142            *              state_alarm:
 2860  143            *               if state_byte <> current_state then
 2870  144            *                begin
 2880  145            *                  update_current_state;
 2890  146            *                  signal( state_alarm, PAC )
 2900  147            *                end;
 2910  148            *
 2920  149            *              d_ack:
\f

outlst      81.06.24.   17.09.                                                    page     5

 2930  150            *               if no_of_bytes = block_lth then
 2940  151            *                signal( control_receipt, sender )
 2950  152            *               else
 2960  153            *                send_telegram( cntrl, next_cntrl_byte );
 2970  154            *
 2980  155            *              t_ack,
 2990  156            *              e_ack:
 3000  157            *               begin
 3010  158            *                 signal( test_receipt, sender );
 3020  159            *                 conversation:= idle
 3030  160            *               end;
 3040  161            *
 3050  162            *             end <* case AT_operation_code *>
 3060  163            *
 3070  164            *           end
 3080  165            *
 3090  166            *     end <* case message origin *>
 3100  167            *
 3110  168            *   until forever
 3120  169            *
 3130  170            * end. <* process AT_CONNECTOR *>
 3140  171            *
 3150  172            *********************************************************************************)
 3160  173          
 3170  174          
 3180  175          
 3190  176          
 3200  177           
\f

outlst      81.06.24.   17.09.                                                    page     6

 4010  178            (*********************************************************************************
 4020  179            *
 4030  180            * ABBREVIATION LIST
 4040  181            *
 4050  182            * aac          alternative alarm centre
 4060  183            * ac, AC       alarm centre
 4070  184            * at, AT       alarm terminal
 4080  185            * atc, ATC     alarm terminal connector
 4090  186            * ath, ATH     alarm terminal (connector) handler
 4100  187            * au           alarm unit
 4110  188            * dc, DC       district centre
 4120  189            * driver       lam driver
 4130  190            * msg          reference to a message
 4140  191            * pac, PAC     primary alarm centre
 4150  192            * r_w          read_write
 4160  193            * sem          semaphore
 4170  194            * s_a..        stop activity (e.g. s_a_limit)
 4180  195            * t_e../..t_e  transmission error (e.g. t_e_counter)
 4190  196            * TS, ts       terminal station
 4200  197            *
 4210  198            *
 4220  199            *
 4230  200            *
 4240  201            *
 4250  202            *
 4260  203            *
 4270  204            *
 4280  205            *
 4290  206            *
 4300  207            *
 4310  208            *
 4320  209            *********************************************************************************)
 4330  210          
 4340  211           
\f

outlst      81.06.24.   17.09.                                                    page     7

 5010  212            (*********************************************************************************
 5020  213            * declaration part 1: shielded types
 5030  214            *********************************************************************************)
 5040  215          
 5050  216        VAR
 5060  217          
 5070  218            (* pools. Allocation takes place with main_sem as answer semaphore *)
 5080  219          
 5090  220          driver_pool          : pool 1 OF integer; (* driver message is allocated from this pool *)
 5100  221          delay_pool           : pool 1;    (* delay message is allocated from this pool *)
 5110  222          
 5120  223            (* reference variables *)
 5130  224          
 5140  225          delay_msg,                        (* holds delay out message while it's unused *)
 5150  226          ath_msg,                          (* holds message from ATH while waiting for response from AT *)
 5160  227          driver_msg,                       (* holds message from DRIVER while while it's unused *)
 5170  228          alarm_msg,                        (* general use. Holds alarm message while it's updated *)
 5180  229          atc_msg              : reference; (* holds message from input semaphore
 5190  230                                            while it's classified *)
 5200  231           
\f

outlst      81.06.24.   17.09.                                                    page     8

 6010  232            (*********************************************************************************
 6020  233            * declaration part 2: telegrams from master (TS) to slave (AT)
 6030  234            *
 6040  235            *********************************************************************************)
 6050  236          
 6060  237        CONST
 6070  238            (* operation codes *)
 6080  239          poll_opc             = 0;
 6090  240          atc_cntrl            = 1;
 6100  241          atc_testi            = 2;
 6110  242          atc_teste            = 3;
 6120  243          
 6130  244            (* data bytes *)
 6140  245          poll_byte            = 0;
 6150  246          testi1_byte          = 0;
 6160  247          testi2_byte          = 1;
 6170  248          
 6180  249        TYPE
 6190  250          atc_op_codes         = poll_opc..atc_teste;
 6200  251          
 6210  252          atc_format           = PACKED RECORD
 6220  253                                        !  out_data      : byte;
 6230  254                                        !  atc_opc       : atc_op_codes;
 6240  255                                        !  serial_number : boolean;
 6250  256                                        !  checkbits     : 0..31
 6260  257                                        END;
 6270  258          
 6280  259        VAR
 6290  260          last_telegram        : atc_format   := atc_format( 0, 0, false, 0 );
 6300  261          
 6310  262           
\f

outlst      81.06.24.   17.09.                                                    page     9

 7010  263            (*********************************************************************************
 7020  264            * declaration part 3: telegrams from slave (AT) to master (TS)
 7030  265            *
 7040  266            *********************************************************************************)
 7050  267          
 7060  268        CONST
 7070  269            (* operation codes *)
 7080  270          p_ack                = 0;
 7090  271          state                = 1;
 7100  272          au_alarm             = 2;
 7110  273          addr                 = 3;
 7120  274          d_ack                = 4;
 7130  275          t_ack                = 5;
 7140  276          e_ack                = 6;
 7150  277          n_ack                = 7;
 7160  278          
 7170  279        TYPE
 7180  280          at_op_codes          = p_ack..n_ack;
 7190  281          
 7200  282          at_format            = PACKED RECORD
 7210  283                                        !  in_data   : byte;
 7220  284                                        !  at_opc    : at_op_codes;
 7230  285                                        !  checkbits : 0..31
 7240  286                                        END;
 7250  287           
\f

outlst      81.06.24.   17.09.                                                    page    10

 8010  288            (*********************************************************************************
 8020  289            * declaration part 4: state telegrams from slave (AT) to master (TS)
 8030  290            *
 8040  291            *********************************************************************************)
 8050  292          
 8060  293        CONST
 8070  294            (* at state bits *)
 8080  295          unused               = 0;
 8090  296          at_time_out          = 1;
 8100  297          hs_error             = 2;
 8110  298          au_error             = 3;
 8120  299          serif_error          = 4;
 8130  300          restart              = 5;
 8140  301          batt_limit           = 6;
 8150  302          batt_supply          = 7;
 8160  303          
 8170  304        TYPE
 8180  305          state_bits           = unused..batt_supply;
 8190  306          state_byte           = SET OF state_bits;
 8200  307          
 8210  308        VAR
 8220  309          state_bit            : state_bits  := unused;
 8230  310           
\f

outlst      81.06.24.   17.09.                                                    page    11

 9010  311            (*********************************************************************************
 9020  312            * declaration part 5: alarm net operation codes
 9030  313            *
 9040  314            *********************************************************************************)
 9050  315          
 9060  316        CONST
 9070  317            (* pac log operation code *)
 9080  318          pac_alarm_log        = #h01;
 9090  319          
 9100  320            (* garbage message *)
 9110  321          reject_opc           = #h12;
 9120  322          
 9130  323            (* alarms *)
 9140  324          au_alarm_opc         = #h30;
 9150  325          line_alarm           = #h31;
 9160  326          state_alarm          = #h32;
 9170  327          service_alarm        = #h34;
 9180  328          s_a_alarm            = #h35;
 9190  329          
 9200  330            (* control *)
 9210  331          ts_cntrl             = #h40;
 9220  332          group_cntrl          = #h44;
 9230  333          
 9240  334            (* tests *)
 9250  335          ts_testi1            = #h80;
 9260  336          ts_testi2            = #h82;
 9270  337          ts_teste             = #h84;
 9280  338          
 9290  339            (* change of activity *)
 9300  340          ts_newactivity       = #h90;
 9310  341          
 9320  342          connect_test         = #h92;
 9330  343          
 9340  344            (* updating of alarm centre table *)
 9350  345          upd_ac_table         = #ha0;
 9360  346          
 9370  347            (* read package counter *)
 9380  348          read_package_count   = #hb4;
 9390  349          
 9400  350            (* read or update of parameter *)
 9410  351          r_w_tec              = #hb2;
 9420  352          r_w_service_limit    = #hb6;
 9430  353          r_w_s_a_limit        = #hba;
 9440  354          r_w_max_succ_t_e     = #hbc;
 9450  355           
\f

outlst      81.06.24.   17.09.                                                    page    12

10010  356          node_test            = #hc0;
10020  357          
10030  358          dummy_alarm          = #hc8;
10040  359          
10050  360          break_proc_end       = #hce;
10060  361           
\f

outlst      81.06.24.   17.09.                                                    page    13

11010  362            (*********************************************************************************
11020  363            * declaration part 6: alarm centre table and the management of it
11030  364            *
11040  365            *********************************************************************************)
11050  366          
11060  367        VAR
11070  368          ac_tbl               : ac_address_table;
11080  369          
11090  370          actual_ac_index      : ac_table_range       := pac_index;
11100  371          top_aac_index        : upper_ac_tbl_index   := 0;
11110  372           
\f

outlst      81.06.24.   17.09.                                                    page    14

12010  373            (*********************************************************************************
12020  374            * declaration part 7: management of states and protocol
12030  375            *
12040  376            *********************************************************************************)
12050  377          
12060  378        TYPE
12070  379          type_of_conversation = (
12080  380                                  idle,                       (* no telegram pending *)
12090  381                                  busy,                       (* poll pending *)
12100  382                                  control,                    (* control pending *)
12110  383                                  testi,                      (* testi1 or testi2 telegram pending *)
12120  384                                  teste,                      (* test extern pending *)
12130  385                                  coll_alarm1 ,               (* ATC is collecting multi byte alarm *)
12140  386                                  coll_alarm2 );              (* a poll is pending to look for a new alarm *)
12150  387          
12160  388        VAR
12170  389          reject_code          : result_range         := not_ready;
12180  390          
12190  391          conversation         : type_of_conversation := idle;
12200  392           
\f

outlst      81.06.24.   17.09.                                                    page    15

13010  393            (*********************************************************************************
13020  394            * declaration part 8: supervision of transmission line
13030  395            *
13040  396            *********************************************************************************)
13050  397          
13060  398        TYPE
13070  399          valid_set            = SET OF at_op_codes;
13080  400          
13090  401          t_e_kind_type        = (
13100  402                                  no_error,
13110  403                                  time_excess,                (* reported from DRIVER *)
13120  404                                  not_ack,                    (* n_ack operation code received *)
13130  405                                  bit_error,                  (* error in checksum *)
13140  406                                  ill_opc,                    (* unexpected operation code in response *)
13150  407                                  channel_error );            (* reported from DRIVER *)
13160  408          
13170  409        VAR
13180  410          t_e_step             : integer := trans_err_rate;   (* increment of t_e_counter
13190  411                                                              when a transmission error occurs *)
13200  412          service_limit        : integer := service_lim;      (* t_e_counter service_limit. *)
13210  413          s_a_limit            : integer := stop_poll_lim;    (* t_e_counter stop activity limit. *)
13220  414          max_succ_t_e         : integer := max_succ_lin_err; (* number of successive
13230  415                                                              transmission errors before line alarm *)
13240  416          
13250  417          t_e_counter,                                        (* transmission error counter *)
13260  418          no_succ_t_e          : integer           := 0;
13270  419          
13280  420          valid_response       : ARRAY( busy..coll_alarm2 ) OF valid_set;
13290  421          
13300  422          t_e_kind             :  t_e_kind_type    := no_error;
13310  423          
13320  424          line_state           : (
13330  425                                  low,                        (* t_e_counter below service limit *)
13340  426                                  serv_lim_excess,            (* service_limit exceeded *)
13350  427                                  s_a_lim_excess ) := low;    (* stop activity limit exceeded *)
13360  428          
13370  429          
13380  430          
13390  431           
\f

outlst      81.06.24.   17.09.                                                    page    16

14010  432            (*********************************************************************************
14020  433            * declaration part 9: miscellaneous
14030  434            *
14040  435            *********************************************************************************)
14050  436          
14060  437        TYPE
14070  438          receipt_route        = ARRAY( netc_route..netc_route1 ) OF byte;
14080  439          
14090  440        CONST
14100  441          route_vect           = receipt_route( at_route, at_route1 );
14110  442          override             = false;
14120  443          dummy                = 0;
14130  444          
14140  445        TYPE
14150  446          create_ch_format     = ARRAY( 0..1 ) OF byte;
14160  447          
14170  448        VAR
14180  449          package_count        : integer           := 0;      (* is counted circular from 0
14190  450                                                              through 32766 = ( max_int - 1) *)
14200  451          
14210  452          delay3, delay4       : byte;                        (* contents u3 and u4 values of delay message *)
14220  453          
14230  454          at_op_code           : at_op_codes       := 0;
14240  455          at_data              : byte              := 0;
14250  456          
14260  457          z                    : zone;
14270  458           
\f

outlst      81.06.24.   17.09.                                                    page    17

15010  459            (*********************************************************************************
15020  460            * forward declaration part
15030  461            *
15040  462            *********************************************************************************)
15050  463          
15060  464          PROCEDURE restrict_protocol;
15070  465          FORWARD;
15080  466          
15090  467          
15100  468            <*p
15110  469            PROCEDURE exception( excode: integer );
15120  470            FORWARD;
15130  471            p*>
15140  472           
\f

outlst      81.06.24.   17.09.                                                    page    18

16010  473            <*t PROCEDURE print_telegram( VAR msg: reference; transmit: boolean; param: byte );
16020  474            
16030  475            TYPE
16040  476            hexa                 = ARRAY( 0..15 ) OF char;
16050  477            
16060  478            CONST
16070  479            hex_convert          = hexa( "0", "1", "2", "3", "4", "5", "6", "7", "8", "9",
16080  480            "a", "b", "c", "d", "e", "f" );
16090  481            
16100  482            VAR
16110  483            string               : alfa   := alfa( "            " );
16120  484            
16130  485            BEGIN
16140  486            
16150  487            IF transmit THEN
16160  488            LOCK msg AS locvar: atc_format DO
16170  489            WITH locvar DO
16180  490            BEGIN
16190  491            
16200  492            string(  1 ):= "T";
16210  493            string(  4 ):= hex_convert( atc_opc );
16220  494            string(  6 ):= hex_convert( ord( serial_number ) );
16230  495            string(  8 ):= hex_convert( checkbits DIV 16 );
16240  496            string(  9 ):= hex_convert( checkbits MOD 16 );
16250  497            string( 11 ):= hex_convert( out_data DIV 16 );
16260  498            string( 12 ):= hex_convert( out_data MOD 16 )
16270  499            
16280  500            END (* lock msg *)
16290  501            ELSE
16300  502            LOCK msg AS locvar: at_format DO
16310  503            WITH locvar DO
16320  504            BEGIN
16330  505            
16340  506            string(  1 ):= "R";
16350  507            string(  6 ):= hex_convert( at_opc );
16360  508            string(  8 ):= hex_convert( checkbits DIV 16 );
16370  509            string(  9 ):= hex_convert( checkbits MOD 16 );
16380  510            string( 11 ):= hex_convert( in_data DIV 16 );
16390  511            string( 12 ):= hex_convert( in_data MOD 16 )
16400  512            
16410  513            END; (* lock msg *)
16420  514            
16430  515            testout( z, string, param )
16440  516            
16450  517            END;(* procedure print_telegram *) t*>
16460  518           
\f

outlst      81.06.24.   17.09.                                                    page    19

17010  519          PROCEDURE create_channel;
17020  520            
17030  521              (*********************************************************************************
17040  522              * description      : Updates and sends a create channel message to DRIVER
17050  523              *
17060  524              * globals          : driver_msg
17070  525              *                    conversation
17080  526              *********************************************************************************)
17090  527            
17100  528          BEGIN
17110  529    1     ! 
17120  530    2     ! LOCK driver_msg AS locvar: create_ch_format DO
17130  531    3     !   WITH driver_msg^ DO
17140  532    4     !     BEGIN
17150  533    5     !     ! 
17160  534    6     !     ! u1:= create_at_ch;
17170  535    7     !     ! u2:= channel_no;
17180  536    8     !     ! u3:= at_route;
17190  537    9     !     ! 
17200  538   10     !     ! locvar( 0 ):= at_control;
17210  539   11     !     ! locvar( 1 ):= con_lam_time
17220  540   12     !     ! 
17230  541   13     !     END; (* lock *)
17240  542   14     ! 
17250  543   15     ! conversation:= busy;
17260  544   16     ! 
17270  545   17     ! signal( driver_msg, driver_sem^ )
17280  546   18     ! 
17290  547   19     END; (* procedure create_channel *)
17300  548           
\f

outlst      81.06.24.   17.09.                                                    page    20

18010  549          PROCEDURE send_telegram(
18020  550            new_opc              : atc_op_codes;
18030  551            data_byte            : byte;
18040  552            new_serial_no        ,
18050  553            transmission_error   : boolean
18060  554            );
18070  555            
18080  556              (*********************************************************************************
18090  557              * description      : Updates and sends a telegram to AT (through DRIVER) and
18100  558              *                    requests a delay message from TIMER
18110  559              *
18120  560              * call value       : new_opc            = operation code of telegram or unsignificant
18130  561              *                    data_byte          = data byte of telegram or unsignificant
18140  562              *                    new_serial_no      = indicates whether serial number of
18150  563              *                                         telegram is to be alternated. Significant
18160  564              *                                         only if a transmission error is detected.
18170  565              *                    transmision_error  = indicates whether last telegram is to be
18180  566              *                                         repeated.
18190  567              * return value     :                      all are unchanged
18200  568              * globals          : driver_msg         = nil after the call
18210  569              *                    last_telegram      = updated
18220  570              *********************************************************************************)
18230  571            
18240  572          BEGIN
18250  573    1     ! 
18260  574    2     ! IF transmission_error AND ( NOT new_serial_no ) THEN      (* repeat last telegram *)
18270  575    3     !   LOCK driver_msg AS locvar: atc_format DO
18280  576    4     !     locvar:= last_telegram (* end lock driver_msg *)
18290  577    5     !   ELSE
18300  578    6     !     WITH last_telegram DO
18310  579    7     !       BEGIN
18320  580    8     !       ! 
18330  581    9     !       ! IF NOT transmission_error THEN         (* set up new telegram *)
18340  582   10     !       !   BEGIN
18350  583   11     !       !   ! 
18360  584   12     !       !   ! atc_opc:= new_opc;
18370  585   13     !       !   ! serial_number:= NOT serial_number;
18380  586   14     !       !   ! out_data:= data_byte
18390  587   15     !       !   ! 
18400  588   16     !       !   END
18410  589   17     !       ! ELSE
18420  590   18     !       !   IF new_serial_no THEN
18430  591   19     !       !     serial_number:= NOT serial_number;
18440  592   20     !       ! 
18450  593   21     !       ! LOCK driver_msg AS locvar: atc_format DO
18460  594   22     !       !   locvar:= last_telegram; (* end lock driver_msg *)
\f

outlst      81.06.24.   17.09.                                                    page    21

18470  595   23     !       ! 
18480  596   24     !       ! IF check5( driver_msg, generate ) THEN;
18490  597   25     !       ! 
18500  598   26     !       ! LOCK driver_msg AS locvar: atc_format DO
18510  599   27     !       !   last_telegram:= locvar (* end lock driver_msg *)
18520  600   28     !       !   
18530  601   29     !       END;
18540  602   30     ! 
18550  603   31     !   <*t print_telegram( driver_msg, true, ord( conversation ) ); t*>
18560  604   32     ! 
18570  605   33     ! IF NOT nil( delay_msg ) THEN
18580  606   34     !   WITH delay_msg^ DO
18590  607   35     !     BEGIN
18600  608   36     !     ! 
18610  609   37     !     ! u3:= delay3;
18620  610   38     !     ! u4:= delay4;
18630  611   39     !     ! 
18640  612   40     !     ! sendtimer( delay_msg )
18650  613   41     !     ! 
18660  614   42     !     END;
18670  615   43     ! 
18680  616   44     ! WITH driver_msg^ DO
18690  617   45     !   BEGIN
18700  618   46     !   ! 
18710  619   47     !   ! u1:= write_read_at;
18720  620   48     !   ! u2:= channel_no
18730  621   49     !   ! 
18740  622   50     !   END;
18750  623   51     ! 
18760  624   52     ! signal( driver_msg, driver_sem^ )
18770  625   53     ! 
18780  626   54     END; (* procedure send_telegram *)
18790  627           
\f

outlst      81.06.24.   17.09.                                                    page    22

19010  628          PROCEDURE handle_queue(
19020  629            VAR
19030  630            msg                  : reference;
19040  631            reject_cause         : result_range
19050  632            );
19060  633            
19070  634              (*********************************************************************************
19080  635              * description      : Selects a message from the queue with a legal operation
19090  636              *                    code. Messages illegal for the moment are receipted
19100  637              *                    with result = reject_cause.
19110  638              * call value       : msg          = nil or reference to a uncompleted message
19120  639              * return value     : reject_cause = cause of rejection
19130  640              *                    msg          = nil or a reference to a legal message
19140  641              * globals          : ath_msg, queue_sem
19150  642              *********************************************************************************)
19160  643            
19170  644          BEGIN
19180  645    1     ! 
19190  646    2     ! IF NOT nil( msg ) OR open( queue_sem.w^ ) THEN
19200  647    3     !   REPEAT
19210  648    4     !   ! 
19220  649    5     !   ! IF nil( msg ) THEN
19230  650    6     !   !   wait( msg, queue_sem.w^ );
19240  651    7     !   ! 
19250  652    8     !   ! WITH msg^ DO
19260  653    9     !   !   IF ( u3 = dummy_route ) THEN
19270  654   10     !   !     return( msg )
19280  655   11     !   !   ELSE
19290  656   12     !   !     BEGIN
19300  657   13     !   !     ! 
19310  658   14     !   !     ! IF ( u4 IN (.ts_cntrl, group_cntrl, ts_teste.) ) THEN
19320  659   15     !   !     !   package_count:= ( package_count + 1 ) MOD max_int;
19330  660   16     !   !     ! 
19340  661   17     !   !     ! CASE reject_cause OF
19350  662   18     !   !     ! ! 
19360  663   19     !   !     ! ! accepted          :
19370  664   20     !   !     ! ! ;
19380  665   21     !   !     ! ! 
19390  666   22     !   !     ! ! state_hs_error    :
19400  667   23     !   !     ! !   IF ( u4 = ts_teste ) THEN
19410  668   24     !   !     ! !     receipt_message( msg, ath_sem, route_vect( u3 ), 0, reject_cause )
19420  669   25     !   !     ! ! ;
19430  670   26     !   !     ! ! 
19440  671   27     !   !     ! ! state_power_error ,
19450  672   28     !   !     ! ! transmit_error    ,
19460  673   29     !   !     ! ! no_resources      ,
\f

outlst      81.06.24.   17.09.                                                    page    23

19470  674   30     !   !     ! ! no_connection     ,
19480  675   31     !   !     ! ! breaked           ,
19490  676   32     !   !     ! ! not_ready         ,
19500  677   33     !   !     ! ! passivated        :
19510  678   34     !   !     ! !   receipt_message( msg, ath_sem, route_vect( u3 ), 0, reject_cause )
19520  679   35     !   !     ! ! ;
19530  680   36     !   !     ! ! 
19540  681   37     !   !     ! ! illegal_operation ,
19550  682   38     !   !     ! ! state_au_error    ,
19560  683   39     !   !     ! ! state_serif_error :
19570  684   40     !   !     ! !   IF ( u4 IN (.ts_cntrl, group_cntrl, ts_teste.) ) THEN
19580  685   41     !   !     ! !     receipt_message( msg, ath_sem, route_vect( u3 ), 0, reject_cause )
19590  686   42     !   !     ! ! ;
19600  687   43     !   !     ! ! 
19610  688   44     !   !     ! ! OTHERWISE
19620  689   45     !   !     ! ! testout( z, "reject code: ", reject_cause )
19630  690   46     !   !     ! ! 
19640  691   47     !   !     ! END
19650  692   48     !   !     ! 
19660  693   49     !   !     END
19670  694   50     !   !     
19680  695   51     !   UNTIL NOT nil( msg ) OR passive( queue_sem.w^ )
19690  696   52     !   
19700  697   53     END; (* procedure handle_queue *)
19710  698           
\f

outlst      81.06.24.   17.09.                                                    page    24

20010  699          FUNCTION get_message(
20020  700            VAR
20030  701            msg                  : reference;
20040  702            operation_code       ,
20050  703            block_lth            : byte;
20060  704            rec_macro            : macroaddr;
20070  705            rec_micro            ,
20080  706            ac_index             : integer
20090  707            ): boolean;
20100  708            
20110  709              (*********************************************************************************
20120  710              * description      : Waits max delay seconds for a message from com_pool.
20130  711              *                    If ATC is timed out and ath_msg or queue_sem holds
20140  712              *                    resources, these are receipted and another effort is
20150  713              *                    made.
20160  714              *                    A alarm net label is entered in the message.
20170  715              * call value       : msg          = nil
20180  716              * return value     : get_message  = true if a message is received, otherwise false.
20190  717              *                    msg          = nil or reference to the message.
20200  718              *                    msg^.u1      = number of bytes to enter in data part
20210  719              *                    msg^.u2      = 0 ( will be used for counting )
20220  720              * globals            ath_msg
20230  721              *                    queue_sem
20240  722              *********************************************************************************)
20250  723            
20260  724          BEGIN
20270  725    1     ! 
20280  726    2     ! definetimer( true );
20290  727    3     ! 
20300  728    4     ! REPEAT
20310  729    5     ! ! 
20320  730    6     ! ! CASE waitsd( msg, com_pool^, wait_sem_delay ) OF
20330  731    7     ! ! ! 
20340  732    8     ! ! ! a_semaphore:
20350  733    9     ! ! !   LOCK msg AS locvar: alarmlabel DO
20360  734   10     ! ! !     WITH msg^, locvar DO
20370  735   11     ! ! !       BEGIN
20380  736   12     ! ! !       ! 
20390  737   13     ! ! !       ! u1:= block_lth;
20400  738   14     ! ! !       ! u2:= 0;
20410  739   15     ! ! !       ! u3:= at_route;
20420  740   16     ! ! !       ! u4:= operation_code;
20430  741   17     ! ! !       ! 
20440  742   18     ! ! !       ! rec.macro:= rec_macro;
20450  743   19     ! ! !       ! rec.micro:= rec_micro;
20460  744   20     ! ! !       ! 
\f

outlst      81.06.24.   17.09.                                                    page    25

20470  745   21     ! ! !       ! send.macro:= ts_macro;
20480  746   22     ! ! !       ! send.micro:= own_addr;
20490  747   23     ! ! !       ! 
20500  748   24     ! ! !       ! ts_add( 0 ):= ac_index
20510  749   25     ! ! !       ! 
20520  750   26     ! ! !       END (* lock *)
20530  751   27     ! ! ! ;
20540  752   28     ! ! ! 
20550  753   29     ! ! ! a_delay:
20560  754   30     ! ! !   BEGIN
20570  755   31     ! ! !   ! 
20580  756   32     ! ! !   !   <*trace( #h0f );t*>
20590  757   33     ! ! !   ! handle_queue( ath_msg, no_resources );
20600  758   34     ! ! !   ! 
20610  759   35     ! ! !   !   (* obs!!! clean up main if ATC must keep trying *)
20620  760   36     ! ! !   ! 
20630  761   37     ! ! !   END
20640  762   38     ! ! ! ;
20650  763   39     ! ! ! 
20660  764   40     ! ! ! OTHERWISE
20670  765   41     ! ! ! 
20680  766   42     ! ! END
20690  767   43     ! ! 
20700  768   44     ! UNTIL passive( queue_sem.w^ ) OR NOT nil( msg );
20710  769   45     ! 
20720  770   46     ! definetimer( false );
20730  771   47     ! 
20740  772   48     ! get_message:= NOT nil( msg )
20750  773   49     ! 
20760  774   50     END; (* function get_message *)
20770  775           
\f

outlst      81.06.24.   17.09.                                                    page    26

21010  776          FUNCTION ready_byte_msg(
21020  777            VAR
21030  778            msg                  : reference;
21040  779            data_byte            : byte
21050  780            ): boolean;
21060  781            
21070  782              (*********************************************************************************
21080  783              * description      : Enters one data byte in the message data part.
21090  784              * call value       : msg            = references message to fill
21100  785              *                    msg^.u1        = number of bytes to enter
21110  786              *                    msg^.u2        = last byte entered
21120  787              *                    data_byte      = byte in question
21130  788              * return value     : ready_byte_msg = true if filling is completed
21140  789              *                    msg^.u2        = last byte entered.
21150  790              *                    data_byte      = unchanged
21160  791              * globals          : none
21170  792              *********************************************************************************)
21180  793            
21190  794          BEGIN
21200  795    1     ! 
21210  796    2     ! LOCK msg AS locvar: al_form_byte DO
21220  797    3     !   WITH msg^, locvar, al_label DO
21230  798    4     !     BEGIN
21240  799    5     !     ! 
21250  800    6     !     ! IF ( u1 > u2 ) THEN
21260  801    7     !     !   BEGIN
21270  802    8     !     !   ! 
21280  803    9     !     !   ! u2:= u2 + 1;
21290  804   10     !     !   ! data( u2 ):= data_byte
21300  805   11     !     !   ! 
21310  806   12     !     !   END;
21320  807   13     !     ! 
21330  808   14     !     ! ready_byte_msg:= ( u2 = u1 )
21340  809   15     !     ! 
21350  810   16     !     END
21360  811   17     !     
21370  812   18     END; (* function ready_byte_msg *)
21380  813           
\f

outlst      81.06.24.   17.09.                                                    page    27

22010  814          PROCEDURE finish_message(
22020  815            VAR
22030  816            msg                  : reference;
22040  817            res                  : result_range;
22050  818            log_to_pac           : boolean
22060  819            );
22070  820            
22080  821              (***********************************************************************************
22090  822              * description      : Updates the user fields and message label part and sends
22100  823              *                    the message to ATH.
22110  824              *                    A log of an alarm may be send to PAC through ATH.
22120  825              * call value       : msg           = references message to be send
22130  826              *                    msg^.u2       = number of bytes except for alarmlabel.
22140  827              *                    res           = message label information
22150  828              *                    log_to_pac    = true if the alarm is to be logged at PAC
22160  829              * return value     : msg           = nil
22170  830              * globals          : none
22180  831              ************************************************************************************)
22190  832            
22200  833            
22210  834          VAR
22220  835            alarm_bytes        : data_bytes;
22230  836            block_lth          : byte;
22240  837            
22250  838          BEGIN
22260  839    1     ! 
22270  840    2     ! LOCK msg AS locvar: al_form_byte DO
22280  841    3     !   WITH msg^, locvar, locvar.al_label DO
22290  842    4     !     BEGIN
22300  843    5     !     ! 
22310  844    6     !     ! no_of_by:= label_size + u2;
22320  845    7     !     ! result:= res;
22330  846    8     !     ! 
22340  847    9     !     ! IF log_to_pac THEN
22350  848   10     !     !   BEGIN
22360  849   11     !     !   ! 
22370  850   12     !     !   ! block_lth:= u2;
22380  851   13     !     !   ! 
22390  852   14     !     !   ! IF ( block_lth > 0 ) THEN
22400  853   15     !     !   !   FOR u2:= 1 TO block_lth DO
22410  854   16     !     !   !     alarm_bytes( u2 ):= data( u2 )
22420  855   17     !     !   !     
22430  856   18     !     !   END;
22440  857   19     !     ! 
22450  858   20     !     ! IF u4 IN (.pac_alarm_log, au_alarm_opc, line_alarm, state_alarm.) THEN
22460  859   21     !     !   package_count:= ( package_count + 1 ) MOD max_int
\f

outlst      81.06.24.   17.09.                                                    page    28

22470  860   22     !     !   
22480  861   23     !     END; (* lock msg *)
22490  862   24     ! 
22500  863   25     ! signal( msg, ath_sem^ );
22510  864   26     ! 
22520  865   27     ! IF log_to_pac THEN
22530  866   28     !   WITH ac_tbl( pac_index ) DO
22540  867   29     !     IF get_message( msg, pac_alarm_log, block_lth, dummy_macro, dummy, sac_rac_ix ) THEN
22550  868   30     !       BEGIN
22560  869   31     !       ! 
22570  870   32     !       ! LOCK msg AS locvar: al_form_0001 DO
22580  871   33     !       !   WITH msg^, locvar, al_label, aac_address DO
22590  872   34     !       !     BEGIN
22600  873   35     !       !     ! 
22610  874   36     !       !     ! micro:= ac_tbl( actual_ac_index ).sac_rac_ix;
22620  875   37     !       !     ! 
22630  876   38     !       !     ! IF ( block_lth > 0 ) THEN
22640  877   39     !       !     !   FOR u2:= 1 TO block_lth DO
22650  878   40     !       !     !     data( u2 ):= alarm_bytes( u2 );
22660  879   41     !       !     ! 
22670  880   42     !       !     ! u2:= block_lth + 4
22680  881   43     !       !     ! 
22690  882   44     !       !     END;
22700  883   45     !       ! 
22710  884   46     !       ! finish_message( msg, res, NOT log_to_pac )
22720  885   47     !       ! 
22730  886   48     !       END
22740  887   49     !       
22750  888   50     END; (* procedure finish_message *)
22760  889           
\f

outlst      81.06.24.   17.09.                                                    page    29

23010  890          FUNCTION search_addr_code( table_key: byte; VAR table_index: ac_table_range ): boolean;
23020  891            
23030  892              (**********************************************************************************
23040  893              * description      : Searches ac address table for the address code of a
23050  894              *                    alarm centre.
23060  895              *
23070  896              * call value       : table_key        = address code to search
23080  897              *                    table_index      = undefined
23090  898              * return value     : search_addr_code = true if the entry is found else false
23100  899              *                    table_key        = unchanged
23110  900              *                    table_index      = indices entry if it exists
23120  901              * globals          : ac_tbl           = unchanged
23130  902              *********************************************************************************)
23140  903            
23150  904          BEGIN
23160  905    1     ! 
23170  906    2     ! table_index:= pac_index;
23180  907    3     ! 
23190  908    4     ! WHILE ( table_index < top_aac_index ) AND
23200  909    5     !   ( table_key <> ac_tbl( table_index ).addr_code ) DO
23210  910    6     !   table_index:= table_index + 1;
23220  911    7     ! 
23230  912    8     ! search_addr_code:= ( top_aac_index > 0 ) AND ( table_key = ac_tbl( table_index ).addr_code )
23240  913    9     ! 
23250  914   10     END; (* function search_addr_code *)
23260  915          
23270  916          
23280  917           
\f

outlst      81.06.24.   17.09.                                                    page    30

24010  918          FUNCTION search_ac_index( table_key: integer; VAR table_index: ac_table_range ): boolean;
24020  919            
24030  920              (*********************************************************************************
24040  921              * description      : Searches ac address table for the index of a alarm centre.
24050  922              *
24060  923              * call value       : table_key       = entry to search
24070  924              *                    table_index     = undefined
24080  925              * return value     : search_ac_index = true if the entry is found, otherwise false
24090  926              *                    table_key       = unchanged
24100  927              *                    table_index     = indices entry if it exists
24110  928              * globals          : ac_tbl          = unchanged
24120  929              *********************************************************************************)
24130  930            
24140  931          BEGIN
24150  932    1     ! 
24160  933    2     ! table_index:= pac_index;
24170  934    3     ! 
24180  935    4     ! WHILE ( table_index < top_aac_index ) AND
24190  936    5     !   ( table_key <> ac_tbl( table_index ).sac_rac_ix ) DO
24200  937    6     !   table_index:= table_index + 1;
24210  938    7     ! 
24220  939    8     ! search_ac_index:= ( top_aac_index > 0 ) AND ( table_key = ac_tbl( table_index ).sac_rac_ix )
24230  940    9     ! 
24240  941   10     END; (* function search_ac_index *)
24250  942           
\f

outlst      81.06.24.   17.09.                                                    page    31

25010  943          PROCEDURE transm_cntrl(
25020  944            VAR  at_op_code      : at_op_codes;
25030  945            VAR  at_data         : byte;
25040  946            valid_response       : valid_set );
25050  947            
25060  948              (*********************************************************************************
25070  949              * description      : Monitors the conditions of transmission and manages the
25080  950              *                    sending of messages concerning the state of the transmission line.
25090  951              *                    Alarms are hold back when ATC is in service_poll.
25100  952              *                    The counters are not updated if AT state says no power
25110  953              * call value       : at_op_code        = undefined
25120  954              *                    at_data           = undefined
25130  955              *                    valid_response    = the set of responses from AT (slave) which are
25140  956              *                                        valid in relation to the telegram send
25150  957              * return value     : at_op_code        = the operation code of the telegram
25160  958              *                                        if this is found to be valid
25170  959              *                    at_data           = data byte from telegram if transmission
25180  960              *                                        isn't disturbed
25190  961              *                    valid_response    = unchanged
25200  962              * globals          : reject_code       = updated
25210  963              *                    t_e_counter       = updated
25220  964              *                    no_succ_line_err  = updated
25230  965              *                    line_state        = updated
25240  966              *                    t_e_kind          = updated acc. to state/kind of transmission
25250  967              *                    max_succ_t_e, service_limit, s_a_limit
25260  968              *                                      = unchanged
25270  969              ********************************************************************************)
25280  970             
\f

outlst      81.06.24.   17.09.                                                    page    32

26010  971            PROCEDURE send_line_state( op_code, data: byte );
26020  972              
26030  973                (*********************************************************************************
26040  974                * description      : Sends a message to DC or PAC concerning the state of
26050  975                *                    the transmission line
26060  976                * call value       : op_code         = line, service or stop_activity alarm
26070  977                *                    data            = call (may be time out) or recall
26080  978                * return value     :                   both are unchanged
26090  979                * globals          : none
26100  980                *********************************************************************************)
26110  981              
26120  982            VAR
26130  983              msg                  : reference;
26140  984              
26150  985            BEGIN
26160  986    1       ! 
26170  987    2       ! IF ( activity = start_code ) THEN
26180  988    3       !   WITH ac_tbl( pac_index ) DO
26190  989    4       !     IF get_message( msg, op_code, 1, dc_macro, dc_erh_mic_addr, sac_rac_ix ) THEN
26200  990    5       !       IF ready_byte_msg( msg, data ) THEN
26210  991    6       !         finish_message( msg, accepted, override )
26220  992    7       !         
26230  993    8       END; (* procedure send_line_state *)
26240  994             
\f

outlst      81.06.24.   17.09.                                                    page    33

27010  995          BEGIN (* procedure transm_cntrl *)
27020  996    1     ! 
27030  997    2     ! IF ( driver_msg^.u2 = ok_result ) THEN       (* no error result from DRIVER *)
27040  998    3     !   BEGIN
27050  999    4     !   ! 
27060 1000    5     !   ! IF check5( driver_msg, check ) = false THEN   (* bit error *)
27070 1001    6     !   !   t_e_kind:= bit_error
27080 1002    7     !   ! ELSE
27090 1003    8     !   !   LOCK driver_msg AS locvar: at_format DO
27100 1004    9     !   !     WITH locvar DO
27110 1005   10     !   !       BEGIN
27120 1006   11     !   !       ! 
27130 1007   12     !   !       ! IF ( at_opc = n_ack ) THEN
27140 1008   13     !   !       !   t_e_kind:= not_ack
27150 1009   14     !   !       ! ELSE
27160 1010   15     !   !       !   IF at_opc IN valid_response THEN
27170 1011   16     !   !       !     BEGIN
27180 1012   17     !   !       !     ! 
27190 1013   18     !   !       !     ! t_e_kind:= no_error;
27200 1014   19     !   !       !     ! at_op_code:= at_opc;
27210 1015   20     !   !       !     ! at_data:= in_data
27220 1016   21     !   !       !     ! 
27230 1017   22     !   !       !     END
27240 1018   23     !   !       !   ELSE
27250 1019   24     !   !       !     t_e_kind:= ill_opc
27260 1020   25     !   !       !     
27270 1021   26     !   !       END (* lock driver_msg *)
27280 1022   27     !   !       
27290 1023   28     !   END
27300 1024   29     ! ELSE
27310 1025   30     !   BEGIN   (* driver_msg^.u2 <> ok_result: error result from DRIVER *)
27320 1026   31     !   ! 
27330 1027   32     !   ! IF ( driver_msg^.u2 = timeout_err ) THEN
27340 1028   33     !   !   t_e_kind:= time_excess
27350 1029   34     !   ! ELSE
27360 1030   35     !   !   t_e_kind:= channel_error
27370 1031   36     !   !   
27380 1032   37     !   END;
27390 1033   38     ! 
27400 1034   39     !   <*t print_telegram( driver_msg, false, ord( t_e_kind ) ); t*>
27410 1035   40     !  
\f

outlst      81.06.24.   17.09.                                                    page    34

28010 1036   41     ! IF ( reject_code <> state_power_error ) THEN
28020 1037   42     !   BEGIN
28030 1038   43     !   ! 
28040 1039   44     !   ! IF ( t_e_kind <> no_error ) THEN
28050 1040   45     !   !   BEGIN
28060 1041   46     !   !   ! 
28070 1042   47     !   !   ! t_e_counter:= t_e_counter +
28080 1043   48     !   !   ! ( ord( t_e_counter < s_a_limit ) ) * t_e_step; (* don't go too high *)
28090 1044   49     !   !   ! 
28100 1045   50     !   !   ! no_succ_t_e:= no_succ_t_e +
28110 1046   51     !   !   ! ( ord( no_succ_t_e < max_int ) ); (* don't overflow *)
28120 1047   52     !   !   ! 
28130 1048   53     !   !   ! IF ( no_succ_t_e = max_succ_t_e ) THEN (* send line alarm *)
28140 1049   54     !   !   !   BEGIN
28150 1050   55     !   !   !   ! 
28160 1051   56     !   !   !   ! send_line_state( line_alarm,
28170 1052   57     !   !   !   !   (**)           ( ord( t_e_kind = time_excess ) * ( timeout_err - 1 ) + call ) );
28180 1053   58     !   !   !   ! 
28190 1054   59     !   !   !   ! IF ( activity = start_code ) THEN
28200 1055   60     !   !   !   !   reject_code:= transmit_error
28210 1056   61     !   !   !   !   
28220 1057   62     !   !   !   END
28230 1058   63     !   !   !   
28240 1059   64     !   !   END
28250 1060   65     !   ! ELSE
28260 1061   66     !   !   BEGIN
28270 1062   67     !   !   ! 
28280 1063   68     !   !   ! t_e_counter:= t_e_counter - ord( t_e_counter > 0 ); (* freeze at zero point *)
28290 1064   69     !   !   ! 
28300 1065   70     !   !   ! IF ( no_succ_t_e >= max_succ_t_e ) THEN (* recall line alarm *)
28310 1066   71     !   !   !   BEGIN
28320 1067   72     !   !   !   ! 
28330 1068   73     !   !   !   ! send_line_state( line_alarm, recall );
28340 1069   74     !   !   !   ! 
28350 1070   75     !   !   !   ! IF ( activity = start_code ) THEN
28360 1071   76     !   !   !   !   IF reject_code = transmit_error THEN
28370 1072   77     !   !   !   !     reject_code:= accepted;
28380 1073   78     !   !   !   ! 
28390 1074   79     !   !   !   ! no_succ_t_e:= 0
28400 1075   80     !   !   !   ! 
28410 1076   81     !   !   !   END
28420 1077   82     !   !   !   
28430 1078   83     !   !   END;
28440 1079   84     !   !  
\f

outlst      81.06.24.   17.09.                                                    page    35

29010 1080   85     !   ! CASE line_state OF
29020 1081   86     !   ! ! 
29030 1082   87     !   ! ! low:
29040 1083   88     !   ! !   IF ( t_e_counter >= service_limit ) THEN (* send service alarm *)
29050 1084   89     !   ! !     BEGIN
29060 1085   90     !   ! !     ! 
29070 1086   91     !   ! !     ! send_line_state( service_alarm, call );
29080 1087   92     !   ! !     ! line_state:= serv_lim_excess
29090 1088   93     !   ! !     ! 
29100 1089   94     !   ! !     END;
29110 1090   95     !   ! ! 
29120 1091   96     !   ! ! serv_lim_excess:
29130 1092   97     !   ! !   IF ( t_e_counter < service_limit ) THEN   (* recall service alarm *)
29140 1093   98     !   ! !     BEGIN
29150 1094   99     !   ! !     ! 
29160 1095  100     !   ! !     ! send_line_state( service_alarm, recall );
29170 1096  101     !   ! !     ! line_state:= low
29180 1097  102     !   ! !     ! 
29190 1098  103     !   ! !     END
29200 1099  104     !   ! !   ELSE
29210 1100  105     !   ! !     IF ( t_e_counter >= s_a_limit ) THEN    (* send stop activity alarm *)
29220 1101  106     !   ! !       BEGIN
29230 1102  107     !   ! !       ! 
29240 1103  108     !   ! !       ! send_line_state( s_a_alarm, call );
29250 1104  109     !   ! !       ! line_state:= s_a_lim_excess
29260 1105  110     !   ! !       ! 
29270 1106  111     !   ! !       END;
29280 1107  112     !   ! ! 
29290 1108  113     !   ! ! s_a_lim_excess:
29300 1109  114     !   ! !   IF ( t_e_counter < s_a_limit ) THEN     (* recall stop activity alarm *)
29310 1110  115     !   ! !     BEGIN
29320 1111  116     !   ! !     ! 
29330 1112  117     !   ! !     ! send_line_state( s_a_alarm, recall );
29340 1113  118     !   ! !     ! line_state:= serv_lim_excess
29350 1114  119     !   ! !     ! 
29360 1115  120     !   ! !     END
29370 1116  121     !   ! !     
29380 1117  122     !   ! !     OTHERWISE
29390 1118  123     !   ! !     
29400 1119  124     !   ! END (* case line_state *)
29410 1120  125     !   ! 
29420 1121  126     !   END
29430 1122  127     !   
29440 1123  128     END; (* procedure transm_cntrl *)
29450 1124           
\f

outlst      81.06.24.   17.09.                                                    page    36

30010 1125          PROCEDURE initiate_conversation( VAR request_msg: reference );
30020 1126            
30030 1127              (*********************************************************************************
30040 1128              * description      : Initiates a conversation with the AT in accordance with
30050 1129              *                    the operation code in the message from ATH
30060 1130              * call value       : request_msg    = references message from ATH
30070 1131              * return value     : request_msg    = nil if the message is rejected,
30080 1132              *                                     otherwise u1 = number of bytes to AT.
30090 1133              *                                               u2 = 0 ( will be used for counting )
30100 1134              * globals          : conversation   = updated according to operation code
30110 1135              *                    t_e_kind       = unchanged
30120 1136              *                    ac_tbl         = unchanged
30130 1137              *********************************************************************************)
30140 1138            
30150 1139          VAR
30160 1140            result_code          : result_range := accepted;
30170 1141            steering_ac_index    : ac_table_range;
30180 1142            
30190 1143          BEGIN
30200 1144    1     ! 
30210 1145    2     ! LOCK request_msg AS locvar: al_form_byte DO
30220 1146    3     !   WITH request_msg^, locvar, al_label DO
30230 1147    4     !     
30240 1148    5     !     CASE u4 OF (* operation code *)
30250 1149    6     !     ! 
30260 1150    7     !     ! ts_cntrl,
30270 1151    8     !     ! group_cntrl:
30280 1152    9     !     !   IF search_ac_index( ts_add( 0 ), steering_ac_index ) THEN
30290 1153   10     !     !     BEGIN
30300 1154   11     !     !     ! 
30310 1155   12     !     !     ! IF ac_tbl( steering_ac_index ).steering THEN
30320 1156   13     !     !     !   BEGIN (* legal sender *)
30330 1157   14     !     !     !   ! 
30340 1158   15     !     !     !   ! u1:= no_of_by - label_size;
30350 1159   16     !     !     !   ! 
30360 1160   17     !     !     !   ! conversation:= control;
30370 1161   18     !     !     !   ! send_telegram( atc_cntrl, data( 1 ),
30380 1162   19     !     !     !   !   (**)         ( t_e_kind = ill_opc ), override (* ! *) )
30390 1163   20     !     !     !   !   (* ! override transmission error *)
30400 1164   21     !     !     !   ! 
30410 1165   22     !     !     !   END
30420 1166   23     !     !     ! ELSE
30430 1167   24     !     !     !   result_code:= not_steering
30440 1168   25     !     !     !   
30450 1169   26     !     !     END
30460 1170   27     !     !   ELSE
\f

outlst      81.06.24.   17.09.                                                    page    37

30470 1171   28     !     !     result_code:= unknown_sender;
30480 1172   29     !     ! 
30490 1173   30     !     ! ts_testi1, ts_testi2:
30500 1174   31     !     !   IF ( send.macro <> dc_macro ) THEN
30510 1175   32     !     !     result_code:= forbidden
30520 1176   33     !     !   ELSE
30530 1177   34     !     !     BEGIN
30540 1178   35     !     !     ! 
30550 1179   36     !     !     ! u1:= 1;
30560 1180   37     !     !     ! no_of_by:= no_of_by + 1;
30570 1181   38     !     !     ! 
30580 1182   39     !     !     ! conversation:= testi;
30590 1183   40     !     !     ! 
30600 1184   41     !     !     ! IF ( u4 = ts_testi1 ) THEN
30610 1185   42     !     !     !   send_telegram( atc_testi, testi1_byte,
30620 1186   43     !     !     !     (**)         ( t_e_kind = ill_opc ), override (* ! *) )
30630 1187   44     !     !     !     (* ! override transmission error *)
30640 1188   45     !     !     ! ELSE
30650 1189   46     !     !     !   send_telegram( atc_testi, testi2_byte,
30660 1190   47     !     !     !     (**)         ( t_e_kind = ill_opc ), override (* ! *) )
30670 1191   48     !     !     !     (* ! override transmission error *)
30680 1192   49     !     !     !   
30690 1193   50     !     !     END;
30700 1194   51     !     ! 
30710 1195   52     !     ! ts_teste:
30720 1196   53     !     !   BEGIN
30730 1197   54     !     !   ! 
30740 1198   55     !     !   ! u1:= no_of_by - label_size;
30750 1199   56     !     !   ! 
30760 1200   57     !     !   ! conversation:= teste;
30770 1201   58     !     !   ! send_telegram( atc_teste, data( 1 ),
30780 1202   59     !     !   !   (**)         ( t_e_kind = ill_opc ), override (* ! *) )
30790 1203   60     !     !   !   (* ! override transmission error *)
30800 1204   61     !     !   ! 
30810 1205   62     !     !   END;
30820 1206   63     !     ! 
30830 1207   64     !     ! OTHERWISE
30840 1208   65     !     ! 
30850 1209   66     !     END; (* lock, case request_msg^.u4 *)
30860 1210   67     ! 
30870 1211   68     ! IF ( result_code <> accepted ) THEN
30880 1212   69     !   receipt_message( request_msg, ath_sem, route_vect( request_msg^.u3 ), 0, result_code )
30890 1213   70     ! ELSE
30900 1214   71     !   request_msg^.u2:= 0
30910 1215   72     !   
30920 1216   73     END; (* procedure initiate_conversation *)
\f

outlst      81.06.24.   17.09.                                                    page    38

30930 1217           
\f

outlst      81.06.24.   17.09.                                                    page    39

31010 1218          PROCEDURE exec_conn_operation( VAR msg: reference );
31020 1219            
31030 1220              (********************************************************************************
31040 1221              * description      : Executes on request from ATH those operation types,
31050 1222              *                    that doesn't involve DRIVER and sends a receipt to ATH
31060 1223              * call value       : msg    = reference to message from ATH
31070 1224              * return value     : msg    = nil
31080 1225              * globals          : reject_code
31090 1226              *                    according to operation code:
31100 1227              *                      actual_ac_index, top_ac_index, ac_tbl
31110 1228              ********************************************************************************)
31120 1229            
31130 1230          VAR
31140 1231            res                  : result_range := accepted;
31150 1232            table_index          : ac_table_range;
31160 1233             
\f

outlst      81.06.24.   17.09.                                                    page    40

32010 1234            PROCEDURE connect_message( VAR msg: reference; user4: byte );
32020 1235              
32030 1236            VAR
32040 1237              work_addr     : alarmnetaddr;
32050 1238              
32060 1239            BEGIN
32070 1240    1       ! 
32080 1241    2       ! LOCK msg AS locvar: al_form_0902 DO
32090 1242    3       !   WITH msg^, locvar, al_label DO
32100 1243    4       !     BEGIN
32110 1244    5       !     ! 
32120 1245    6       !     ! u4:= user4;
32130 1246    7       !     ! 
32140 1247    8       !     ! work_addr:= send;
32150 1248    9       !     ! send:= al_net_addr;
32160 1249   10       !     ! al_net_addr:= work_addr
32170 1250   11       !     ! 
32180 1251   12       !     END
32190 1252   13       !     
32200 1253   14       END; (* procedure connect_message *)
32210 1254             
\f

outlst      81.06.24.   17.09.                                                    page    41

33010 1255            PROCEDURE compute_delay( param: integer );
33020 1256              
33030 1257                (*********************************************************************************
33040 1258                * description      : Computes delay to enter the u3 and u4 fields of the delay
33050 1259                *                    message as (u3*2^u4)
33060 1260                * call value       : param          = integer value of delay ( seconds )
33070 1261                * globals          : delay          = value of delay
33080 1262                *                    delay3, delay4 = altered according to formula above
33090 1263                *********************************************************************************)
33100 1264              
33110 1265            BEGIN
33120 1266    1       ! 
33130 1267    2       ! delay:= param;
33140 1268    3       ! 
33150 1269    4       ! delay4:= 0;
33160 1270    5       ! 
33170 1271    6       ! WHILE ( param > ( max_int DIV time_out_unit ) ) DO
33180 1272    7       !   BEGIN
33190 1273    8       !   ! 
33200 1274    9       !   ! param:= param DIV 2;
33210 1275   10       !   ! delay4:= delay4 + 1
33220 1276   11       !   ! 
33230 1277   12       !   END;
33240 1278   13       ! 
33250 1279   14       ! param:= param * time_out_unit;
33260 1280   15       ! 
33270 1281   16       ! WHILE ( param > max_byte ) DO
33280 1282   17       !   BEGIN
33290 1283   18       !   ! 
33300 1284   19       !   ! param:= param DIV 2;
33310 1285   20       !   ! delay4:= delay4 + 1
33320 1286   21       !   ! 
33330 1287   22       !   END;
33340 1288   23       ! 
33350 1289   24       ! delay3:= param
33360 1290   25       ! 
33370 1291   26       END; (* procedure compute_delay *)
33380 1292             
\f

outlst      81.06.24.   17.09.                                                    page    42

34010 1293            PROCEDURE rw_param( VAR parameter: integer );
34020 1294              
34030 1295                (*********************************************************************************
34040 1296                * description      : Reads or updates a parameter according to the operation code
34050 1297                *                    and the update field.
34060 1298                * call value       : parameter      = parameter en question
34070 1299                * return value     : parameter      = updated if update is insert_code
34080 1300                * globals          : none
34090 1301                *********************************************************************************)
34100 1302              
34110 1303            BEGIN
34120 1304    1       ! 
34130 1305    2       ! LOCK msg AS locvar: al_form_11__ DO
34140 1306    3       !   WITH locvar, locvar.al_label DO
34150 1307    4       !     IF ( send.macro <> dc_macro ) THEN
34160 1308    5       !       res:= forbidden
34170 1309    6       !     ELSE
34180 1310    7       !       
34190 1311    8       !       CASE update OF
34200 1312    9       !       ! 
34210 1313   10       !       ! read_code:
34220 1314   11       !       !   BEGIN
34230 1315   12       !       !   ! 
34240 1316   13       !       !   ! params( 1 ):= parameter;
34250 1317   14       !       !   ! no_of_by:= no_of_by + 2;
34260 1318   15       !       !   ! 
34270 1319   16       !       !   END;
34280 1320   17       !       ! 
34290 1321   18       !       ! insert_code:
34300 1322   19       !       !   IF ( msg^.u4 <> read_package_count ) THEN
34310 1323   20       !       !     parameter:= params( 1 )
34320 1324   21       !       !   ELSE
34330 1325   22       !       !     res:= forbidden
34340 1326   23       !       ! ;
34350 1327   24       !       ! 
34360 1328   25       !       ! OTHERWISE
34370 1329   26       !       ! res:= unknown_update
34380 1330   27       !       ! 
34390 1331   28       !       END (* case update *)
34400 1332   29       !       
34410 1333   30       END; (* procedure rw_param *)
34420 1334             
\f

outlst      81.06.24.   17.09.                                                    page    43

35010 1335          BEGIN (* procedure exec_conn_operation *)
35020 1336    1     ! 
35030 1337    2     !   <*t testout( z, "exec_conn_op", msg^.u4 ); t*>
35040 1338    3     ! 
35050 1339    4     ! CASE msg^.u4 OF (* operation code *)
35060 1340    5     ! ! 
35070 1341    6     ! ! reject_opc:
35080 1342    7     ! !   BEGIN
35090 1343    8     ! !   ! 
35100 1344    9     ! !   ! return( msg );
35110 1345   10     ! !   ! testout( z, "garb. return", msg^.u3 )
35120 1346   11     ! !   ! 
35130 1347   12     ! !   END;
35140 1348   13     ! ! 
35150 1349   14     ! ! ts_newactivity:
35160 1350   15     ! !   LOCK msg AS locvar: al_form_0900 DO
35170 1351   16     ! !     WITH locvar, al_label DO
35180 1352   17     ! !       IF ( send.macro <> dc_macro ) AND ( send.micro <> ath_mic_addr ) THEN
35190 1353   18     ! !         res:= forbidden
35200 1354   19     ! !       ELSE
35210 1355   20     ! !         CASE update OF
35220 1356   21     ! !         ! 
35230 1357   22     ! !         ! stop_code:
35240 1358   23     ! !         !   BEGIN
35250 1359   24     ! !         !   ! 
35260 1360   25     ! !         !   ! IF NOT nil( alarm_msg ) THEN
35270 1361   26     ! !         !   !   WITH ac_tbl( actual_ac_index ) DO
35280 1362   27     ! !         !   !     finish_message( alarm_msg, data_incomplete,
35290 1363   28     ! !         !   !       (**)          ( ac_tbl( pac_index ).sac_rac_ix <> sac_rac_ix ) );
35300 1364   29     ! !         !   ! 
35310 1365   30     ! !         !   ! IF nil( driver_msg ) THEN
35320 1366   31     ! !         !   !   conversation:= busy
35330 1367   32     ! !         !   ! ELSE
35340 1368   33     ! !         !   !   conversation:= idle;
35350 1369   34     ! !         !   ! 
35360 1370   35     ! !         !   ! activity:= stop_code;
35370 1371   36     ! !         !   ! reject_code:= passivated
35380 1372   37     ! !         !   ! 
35390 1373   38     ! !         !   END;
35400 1374   39     ! !         !  
\f

outlst      81.06.24.   17.09.                                                    page    44

36010 1375   40     ! !         ! start_code:
36020 1376   41     ! !         !   IF ( top_aac_index < pac_index ) THEN
36030 1377   42     ! !         !     res:= not_ready
36040 1378   43     ! !         !   ELSE
36050 1379   44     ! !         !     BEGIN
36060 1380   45     ! !         !     ! 
36070 1381   46     ! !         !     ! t_e_counter:= t_e_c_init;
36080 1382   47     ! !         !     ! 
36090 1383   48     ! !         !     ! compute_delay( frequence );
36100 1384   49     ! !         !     ! 
36110 1385   50     ! !         !     ! line_state:= low;
36120 1386   51     ! !         !     ! no_succ_t_e:= 0;
36130 1387   52     ! !         !     ! 
36140 1388   53     ! !         !     ! activity:= start_code;
36150 1389   54     ! !         !     ! reject_code:= accepted;
36160 1390   55     ! !         !     ! 
36170 1391   56     ! !         !     ! valid_response( busy ):= (.p_ack, au_alarm, addr, state, n_ack.);
36180 1392   57     ! !         !     ! valid_response( control ):= (.state, d_ack, n_ack.);
36190 1393   58     ! !         !     ! valid_response( testi ):= (.state, t_ack, n_ack.);
36200 1394   59     ! !         !     ! valid_response( teste ):= (.state, e_ack, n_ack.);
36210 1395   60     ! !         !     ! valid_response( coll_alarm1 ):= (.au_alarm, addr, state, n_ack.);
36220 1396   61     ! !         !     ! valid_response( coll_alarm2 ):= (.p_ack, au_alarm, addr, state, n_ack.);
36230 1397   62     ! !         !     ! 
36240 1398   63     ! !         !     ! IF nil( driver_msg ) THEN
36250 1399   64     ! !         !     !   conversation:= busy
36260 1400   65     ! !         !     ! ELSE
36270 1401   66     ! !         !     !   conversation:= idle
36280 1402   67     ! !         !     !   
36290 1403   68     ! !         !     END;
36300 1404   69     ! !         !  
\f

outlst      81.06.24.   17.09.                                                    page    45

37010 1405   70     ! !         ! service_code:
37020 1406   71     ! !         !   BEGIN
37030 1407   72     ! !         !   ! 
37040 1408   73     ! !         !   ! IF NOT nil( alarm_msg ) THEN
37050 1409   74     ! !         !   !   WITH ac_tbl( actual_ac_index ) DO
37060 1410   75     ! !         !   !     finish_message( alarm_msg, data_incomplete,
37070 1411   76     ! !         !   !       (**)          ( ac_tbl( pac_index ).sac_rac_ix <> sac_rac_ix ) );
37080 1412   77     ! !         !   ! 
37090 1413   78     ! !         !   ! compute_delay( frequence );
37100 1414   79     ! !         !   ! 
37110 1415   80     ! !         !   ! activity:= service_code;
37120 1416   81     ! !         !   ! reject_code:= illegal_operation;
37130 1417   82     ! !         !   ! 
37140 1418   83     ! !         !   ! valid_response( busy ):= (.p_ack, n_ack.);
37150 1419   84     ! !         !   ! valid_response( testi ):= (.t_ack, n_ack.);
37160 1420   85     ! !         !   ! 
37170 1421   86     ! !         !   ! IF nil( driver_msg ) THEN
37180 1422   87     ! !         !   !   conversation:= busy
37190 1423   88     ! !         !   ! ELSE
37200 1424   89     ! !         !   !   conversation:= idle
37210 1425   90     ! !         !   !   
37220 1426   91     ! !         !   END;
37230 1427   92     ! !         ! 
37240 1428   93     ! !         ! OTHERWISE
37250 1429   94     ! !         ! res:= unknown_update
37260 1430   95     ! !         ! 
37270 1431   96     ! !         END; (* case update, lock msg *)
37280 1432   97     ! !  
\f

outlst      81.06.24.   17.09.                                                    page    46

38010 1433   98     ! ! connect_test:
38020 1434   99     ! !   connect_message( msg, dummy_alarm - receipt )
38030 1435  100     ! ! ;
38040 1436  101     ! ! 
38050 1437  102     ! ! dummy_alarm:
38060 1438  103     ! ! ;
38070 1439  104     ! ! 
38080 1440  105     ! ! ( dummy_alarm + receipt ):
38090 1441  106     ! !   connect_message( msg, connect_test )
38100 1442  107     ! ! ;
38110 1443  108     ! ! 
38120 1444  109     ! ! upd_ac_table:
38130 1445  110     ! !   LOCK msg AS locvar: al_form_1000 DO
38140 1446  111     ! !     WITH locvar, ac_addr_tbl_e, al_label DO
38150 1447  112     ! !       IF ( send.macro <> dc_macro ) THEN
38160 1448  113     ! !         res:= forbidden
38170 1449  114     ! !       ELSE
38180 1450  115     ! !         CASE update OF (* change of ac address table *)
38190 1451  116     ! !         ! 
38200 1452  117     ! !         ! read_code:
38210 1453  118     ! !         !   IF search_addr_code( addr_code, table_index ) THEN
38220 1454  119     ! !         !     ac_addr_tbl_e:= ac_tbl( table_index )
38230 1455  120     ! !         !   ELSE
38240 1456  121     ! !         !     res:= not_found
38250 1457  122     ! !         ! ;
38260 1458  123     ! !         ! 
38270 1459  124     ! !         ! insert_code:
38280 1460  125     ! !         !   IF search_addr_code( addr_code, table_index ) THEN (* modify *)
38290 1461  126     ! !         !     ac_tbl( table_index ):= ac_addr_tbl_e
38300 1462  127     ! !         !   ELSE
38310 1463  128     ! !         !     IF ( top_aac_index < ac_table_lth ) THEN (* insert*)
38320 1464  129     ! !         !       BEGIN
38330 1465  130     ! !         !       ! 
38340 1466  131     ! !         !       ! top_aac_index:= top_aac_index + 1;
38350 1467  132     ! !         !       ! ac_tbl( top_aac_index ):= ac_addr_tbl_e
38360 1468  133     ! !         !       ! 
38370 1469  134     ! !         !       END
38380 1470  135     ! !         !     ELSE
38390 1471  136     ! !         !       res:= no_room (* no room in ac address table *)
38400 1472  137     ! !         ! ;
38410 1473  138     ! !         !  
\f

outlst      81.06.24.   17.09.                                                    page    47

39010 1474  139     ! !         ! remove_code: (* delete aac *)
39020 1475  140     ! !         !   IF search_addr_code( addr_code, table_index ) THEN
39030 1476  141     ! !         !     IF ( table_index = pac_index ) THEN
39040 1477  142     ! !         !       res:= illegal_operation
39050 1478  143     ! !         !     ELSE
39060 1479  144     ! !         !       BEGIN
39070 1480  145     ! !         !       ! 
39080 1481  146     ! !         !       ! top_aac_index:= top_aac_index - 1;
39090 1482  147     ! !         !       ! 
39100 1483  148     ! !         !       ! IF ( actual_ac_index > table_index ) THEN
39110 1484  149     ! !         !       !   actual_ac_index:= actual_ac_index - 1
39120 1485  150     ! !         !       ! ELSE
39130 1486  151     ! !         !       !   IF ( actual_ac_index = table_index ) THEN
39140 1487  152     ! !         !       !     actual_ac_index:= pac_index;
39150 1488  153     ! !         !       ! 
39160 1489  154     ! !         !       !   (* compress *)
39170 1490  155     ! !         !       ! FOR table_index:= table_index TO top_aac_index DO
39180 1491  156     ! !         !       !   ac_tbl( table_index ):= ac_tbl( table_index + 1 )
39190 1492  157     ! !         !       !   
39200 1493  158     ! !         !       END
39210 1494  159     ! !         !     ELSE
39220 1495  160     ! !         !       res:= not_found (* ac not found *)
39230 1496  161     ! !         ! ;
39240 1497  162     ! !         ! 
39250 1498  163     ! !         ! OTHERWISE
39260 1499  164     ! !         ! res:= unknown_update
39270 1500  165     ! !         ! 
39280 1501  166     ! !         END; (* case update, lock msg *)
39290 1502  167     ! !  
\f

outlst      81.06.24.   17.09.                                                    page    48

40010 1503  168     ! ! r_w_tec:
40020 1504  169     ! !   rw_param( t_e_counter )
40030 1505  170     ! ! ;
40040 1506  171     ! ! 
40050 1507  172     ! ! read_package_count:
40060 1508  173     ! !   rw_param( package_count )
40070 1509  174     ! ! ;
40080 1510  175     ! ! 
40090 1511  176     ! ! r_w_service_limit:
40100 1512  177     ! !   rw_param( service_limit )
40110 1513  178     ! ! ;
40120 1514  179     ! ! 
40130 1515  180     ! ! r_w_s_a_limit:
40140 1516  181     ! !   rw_param( s_a_limit )
40150 1517  182     ! ! ;
40160 1518  183     ! ! 
40170 1519  184     ! ! r_w_max_succ_t_e:
40180 1520  185     ! !   rw_param( max_succ_t_e )
40190 1521  186     ! ! ;
40200 1522  187     ! ! 
40210 1523  188     ! !   <*p
40220 1524  189     ! !   node_test:
40230 1525  190     ! !   BEGIN
40240 1526  191     ! !   
40250 1527  192     ! !   return( msg );
40260 1528  193     ! !   
40270 1529  194     ! !   IF ( activity = stop_code ) THEN
40280 1530  195     ! !   IF NOT nil( driver_msg ) THEN
40290 1531  196     ! !   create_channel
40300 1532  197     ! !   ELSE (* OBS!!! *)
40310 1533  198     ! !   ELSE (* OBS!!! *)
40320 1534  199     ! !   
40330 1535  200     ! !   END
40340 1536  201     ! !   ;
40350 1537  202     ! !   p*>
40360 1538  203     ! ! 
40370 1539  204     ! ! OTHERWISE
40380 1540  205     ! ! reject_message( msg, ath_sem, route_vect( msg^.u3 ), ts_macro, own_addr, unknown_opcode )
40390 1541  206     ! ! 
40400 1542  207     ! END; (* case operation code *)
40410 1543  208     ! 
40420 1544  209     ! IF NOT nil( msg ) THEN
40430 1545  210     !   receipt_message( msg, ath_sem, route_vect( msg^.u3 ), 0, res )
40440 1546  211     !   
40450 1547  212     END; (* procedure exec_conn_operation *)
40460 1548           
\f

outlst      81.06.24.   17.09.                                                    page    49

41010 1549            <*p
41020 1550            PROCEDURE supervise;
41030 1551            
41040 1552            BEGIN
41050 1553            
41060 1554            IF ( traffic_counter > ( abs( node_test_frequency ) + delay ) ) THEN
41070 1555            BEGIN (* ATH didn't clear traffic_counter in time *)
41080 1556            
41090 1557            activity:= stop_code;
41100 1558            
41110 1559            reject_code:= no_connection;
41120 1560            
41130 1561            (* OBS!!!
41140 1562            . handle_queue will clean up ath_msg and queue_sem when called with
41150 1563            . no_connection. Modifying runtimeset in this way mskes it impossible
41160 1564            . to get back to the original situation.
41170 1565            . outstanding:
41180 1566            .... a feasible reaction in this situation:
41190 1567            ...... stop poll ?
41200 1568            ...... modify runtimeset ?
41210 1569            ...... tell who ?
41220 1570            ...... recovery when/if ATH comes up with traffic_counter = 0
41230 1571            ...... does ATC find out ?
41240 1572            *)
41250 1573            
41260 1574            END
41270 1575            ELSE
41280 1576            traffic_counter:= traffic_counter + delay
41290 1577            
41300 1578            END; (* procedure supervise *)
41310 1579            p*>
41320 1580           
\f

outlst      81.06.24.   17.09.                                                    page    50

42010 1581          PROCEDURE finish_conversation;
42020 1582            
42030 1583              (*********************************************************************************
42040 1584              * description      : Takes the appropriate action in relation to a received
42050 1585              *                    response from DRIVER (AT)
42060 1586              * globals          : alarm_msg          = nil or holding a message
42070 1587              *                    driver_mes         = nil or holding driver message
42080 1588              *                    reject_code        = updated
42090 1589              *                    conversation       = updated
42100 1590              *                    ac_tbl             = unchanged
42110 1591              *                    actual_ac_index    = updated
42120 1592              *                    state_bit          = updated
42130 1593              *********************************************************************************)
42140 1594            
42150 1595          BEGIN
42160 1596    1     ! 
42170 1597    2     ! IF ( t_e_kind <> no_error ) THEN
42180 1598    3     !   
42190 1599    4     !   CASE conversation OF
42200 1600    5     !   ! 
42210 1601    6     !   ! busy:
42220 1602    7     !   !   conversation:= idle;
42230 1603    8     !   ! 
42240 1604    9     !   ! testi, teste, control, coll_alarm1, coll_alarm2:
42250 1605   10     !   !   IF ( no_succ_t_e < max_succ_t_e ) THEN
42260 1606   11     !   !       (* try to get through with the last telegram *)
42270 1607   12     !   !     send_telegram( dummy, dummy, ( ( no_succ_t_e > 1 ) AND ( t_e_kind = ill_opc ) ),
42280 1608   13     !   !       (**)         ( t_e_kind <> no_error ) )
42290 1609   14     !   !   ELSE
42300 1610   15     !   !     BEGIN
42310 1611   16     !   !     ! 
42320 1612   17     !   !     ! IF NOT nil( alarm_msg ) THEN
42330 1613   18     !   !     !   WITH ac_tbl( actual_ac_index ) DO
42340 1614   19     !   !     !     finish_message( alarm_msg, data_incomplete,
42350 1615   20     !   !     !       (**)          ( ac_tbl( pac_index ).sac_rac_ix <> sac_rac_ix ) );
42360 1616   21     !   !     ! 
42370 1617   22     !   !     ! IF NOT nil( ath_msg ) THEN
42380 1618   23     !   !     !   WITH ath_msg^ DO
42390 1619   24     !   !     !     receipt_message( ath_msg, ath_sem, route_vect( u3 ), u2 - u1, data_incomplete );
42400 1620   25     !   !     ! 
42410 1621   26     !   !     ! conversation:= idle
42420 1622   27     !   !     ! 
42430 1623   28     !   !     END;
42440 1624   29     !   ! 
42450 1625   30     !   ! OTHERWISE
42460 1626   31     !   ! 
\f

outlst      81.06.24.   17.09.                                                    page    51

42470 1627   32     !   END (* case conversation *)
42480 1628   33     ! ELSE
42490 1629   34     !    
\f

outlst      81.06.24.   17.09.                                                    page    52

43010 1630   35     !     (* not transmission error *)
43020 1631   36     !   
43030 1632   37     !   CASE at_op_code OF
43040 1633   38     !   ! 
43050 1634   39     !   ! p_ack:
43060 1635   40     !   !   conversation:= idle;
43070 1636   41     !   ! 
43080 1637   42     !   ! au_alarm:
43090 1638   43     !   !   WITH ac_tbl( actual_ac_index ) DO
43100 1639   44     !   !     IF nil( alarm_msg ) THEN
43110 1640   45     !   !       IF get_message( alarm_msg, au_alarm_opc, block_lth,
43120 1641   46     !   !         dummy_macro, dummy, sac_rac_ix ) THEN
43130 1642   47     !   !         BEGIN
43140 1643   48     !   !         ! 
43150 1644   49     !   !         ! IF ready_byte_msg( alarm_msg, at_data ) THEN
43160 1645   50     !   !         !   BEGIN (* au alarm is collected *)
43170 1646   51     !   !         !   ! 
43180 1647   52     !   !         !   ! WITH ac_tbl( actual_ac_index ) DO
43190 1648   53     !   !         !   !   finish_message( alarm_msg, accepted,
43200 1649   54     !   !         !   !     (**)          ( ac_tbl( pac_index ).sac_rac_ix <> sac_rac_ix ) );
43210 1650   55     !   !         !   ! 
43220 1651   56     !   !         !   ! IF ( conversation = coll_alarm2 ) THEN
43230 1652   57     !   !         !   !   conversation:= idle
43240 1653   58     !   !         !   ! ELSE
43250 1654   59     !   !         !   !   BEGIN (* poll immediately *)
43260 1655   60     !   !         !   !   ! 
43270 1656   61     !   !         !   !   ! conversation:= coll_alarm2;
43280 1657   62     !   !         !   !   ! send_telegram( poll_opc, poll_byte,
43290 1658   63     !   !         !   !   !   (**)         ( t_e_kind = ill_opc ), ( t_e_kind <> no_error ) )
43300 1659   64     !   !         !   !   ! 
43310 1660   65     !   !         !   !   END
43320 1661   66     !   !         !   !   
43330 1662   67     !   !         !   END
43340 1663   68     !   !         ! ELSE
43350 1664   69     !   !         !   BEGIN (* collect multi byte alarm *)
43360 1665   70     !   !         !   ! 
43370 1666   71     !   !         !   ! IF ( conversation <> coll_alarm2 ) THEN
43380 1667   72     !   !         !   !   conversation:= coll_alarm1;
43390 1668   73     !   !         !   ! 
43400 1669   74     !   !         !   ! send_telegram( poll_opc, poll_byte,
43410 1670   75     !   !         !   !   (**)         ( t_e_kind = ill_opc ), ( t_e_kind <> no_error ) )
43420 1671   76     !   !         !   ! 
43430 1672   77     !   !         !   END
43440 1673   78     !   !         !   
43450 1674   79     !   !         END
43460 1675   80     !   !       ELSE
\f

outlst      81.06.24.   17.09.                                                    page    53

43470 1676   81     !   !         conversation:= idle
43480 1677   82     !   ! ;
43490 1678   83     !   !  
\f

outlst      81.06.24.   17.09.                                                    page    54

44010 1679   84     !   ! addr:
44020 1680   85     !   !   BEGIN
44030 1681   86     !   !   ! 
44040 1682   87     !   !   ! IF NOT nil( alarm_msg ) THEN (* finish not completed alarm *)
44050 1683   88     !   !   !   WITH ac_tbl( actual_ac_index ) DO
44060 1684   89     !   !   !     finish_message( alarm_msg, data_incomplete,
44070 1685   90     !   !   !       (**)          ( ac_tbl( pac_index ).sac_rac_ix <> sac_rac_ix ) )
44080 1686   91     !   !   ! ;
44090 1687   92     !   !   ! 
44100 1688   93     !   !   ! IF NOT search_addr_code( at_data, actual_ac_index ) THEN (* troubles with block_lth !!! *)
44110 1689   94     !   !   !   actual_ac_index:= pac_index;
44120 1690   95     !   !   ! 
44130 1691   96     !   !   ! WITH ac_tbl( actual_ac_index ) DO
44140 1692   97     !   !   !   IF get_message( alarm_msg, au_alarm_opc, block_lth,
44150 1693   98     !   !   !     dummy_macro, dummy, sac_rac_ix ) THEN
44160 1694   99     !   !   !       (* send a poll immediately *)
44170 1695  100     !   !   !     BEGIN
44180 1696  101     !   !   !     ! 
44190 1697  102     !   !   !     ! conversation:= coll_alarm1;
44200 1698  103     !   !   !     ! send_telegram( poll_opc, poll_byte,
44210 1699  104     !   !   !     !   (**)         ( t_e_kind = ill_opc ), ( t_e_kind <> no_error ) )
44220 1700  105     !   !   !     ! 
44230 1701  106     !   !   !     END
44240 1702  107     !   !   !   ELSE
44250 1703  108     !   !   !     conversation:= idle
44260 1704  109     !   !   !     
44270 1705  110     !   !   END;
44280 1706  111     !   !  
\f

outlst      81.06.24.   17.09.                                                    page    55

45010 1707  112     !   ! state:
45020 1708  113     !   !   BEGIN
45030 1709  114     !   !   ! 
45040 1710  115     !   !   ! IF NOT nil( alarm_msg ) THEN (* finish not completed alarm *)
45050 1711  116     !   !   !   WITH ac_tbl( actual_ac_index ) DO
45060 1712  117     !   !   !     finish_message( alarm_msg, data_incomplete,
45070 1713  118     !   !   !       (**)          ( ac_tbl( pac_index ).sac_rac_ix <> sac_rac_ix ) )
45080 1714  119     !   !   ! ;
45090 1715  120     !   !   ! 
45100 1716  121     !   !   ! WITH ac_tbl( pac_index ) DO
45110 1717  122     !   !   !   IF get_message( alarm_msg, state_alarm, 1, dummy_macro, dummy, sac_rac_ix ) THEN
45120 1718  123     !   !   !     IF ready_byte_msg( alarm_msg, at_data ) THEN
45130 1719  124     !   !   !       finish_message( alarm_msg, accepted, override )
45140 1720  125     !   !   ! ;
45150 1721  126     !   !   ! 
45160 1722  127     !   !   ! LOCK driver_msg AS locvar: state_byte DO
45170 1723  128     !   !   !   BEGIN
45180 1724  129     !   !   !   ! 
45190 1725  130     !   !   !   ! IF ( locvar >= (.batt_limit, batt_supply.) ) THEN
45200 1726  131     !   !   !   !   reject_code:= state_power_error
45210 1727  132     !   !   !   ! ELSE
45220 1728  133     !   !   !   !   IF ( serif_error IN locvar ) THEN
45230 1729  134     !   !   !   !     reject_code:= state_serif_error
45240 1730  135     !   !   !   !   ELSE
45250 1731  136     !   !   !   !     IF ( au_error IN locvar ) THEN
45260 1732  137     !   !   !   !       reject_code:= state_au_error
45270 1733  138     !   !   !   !     ELSE
45280 1734  139     !   !   !   !       IF ( hs_error IN locvar ) THEN
45290 1735  140     !   !   !   !         reject_code:= state_hs_error
45300 1736  141     !   !   !   !       ELSE
45310 1737  142     !   !   !   !         reject_code:= accepted
45320 1738  143     !   !   !   !         
45330 1739  144     !   !   !   END; (* lock driver_msg *)
45340 1740  145     !   !   ! 
45350 1741  146     !   !   ! conversation:= idle
45360 1742  147     !   !   ! 
45370 1743  148     !   !   END;
45380 1744  149     !   !  
\f

outlst      81.06.24.   17.09.                                                    page    56

46010 1745  150     !   ! d_ack,
46020 1746  151     !   ! t_ack,
46030 1747  152     !   ! e_ack:
46040 1748  153     !   !   WITH ath_msg^ DO
46050 1749  154     !   !     IF ready_byte_msg( ath_msg, at_data ) THEN
46060 1750  155     !   !         (* send result of control, testi1, testi2, teste to ATH *)
46070 1751  156     !   !       BEGIN
46080 1752  157     !   !       ! 
46090 1753  158     !   !       ! receipt_message( ath_msg, ath_sem, route_vect( u3 ), 0, accepted );
46100 1754  159     !   !       ! 
46110 1755  160     !   !       ! conversation:= idle
46120 1756  161     !   !       ! 
46130 1757  162     !   !       END
46140 1758  163     !   !     ELSE
46150 1759  164     !   !         (* multi byte control/test: send the next data_byte *)
46160 1760  165     !   !       LOCK ath_msg AS locvar: al_form_byte DO
46170 1761  166     !   !         WITH last_telegram, locvar, al_label DO
46180 1762  167     !   !           send_telegram( atc_opc, data( u2 + 1 ),
46190 1763  168     !   !             (**)         ( t_e_kind = ill_opc ), ( t_e_kind <> no_error ) )
46200 1764  169     !   ! ; (* end lock ath_msg *)
46210 1765  170     !   ! 
46220 1766  171     !   ! OTHERWISE
46230 1767  172     !   ! 
46240 1768  173     !   END (* case at_op_code *)
46250 1769  174     !   
46260 1770  175     END; (* procedure finish_conversation *)
46270 1771           
\f

outlst      81.06.24.   17.09.                                                    page    57

47010 1772          PROCEDURE restrict_protocol;
47020 1773            
47030 1774              (*********************************************************************************
47040 1775              * description      : Handles the situation, where ATC isn't allowed to
47050 1776              *                    communicate with the AT.
47060 1777              *                    The reason being either:
47070 1778              *                    initiating or stop activity ordered from DC.
47080 1779              * globals          : all globals may be used
47090 1780              *********************************************************************************)
47100 1781            
47110 1782          BEGIN
47120 1783    1     ! 
47130 1784    2     ! REPEAT
47140 1785    3     ! ! 
47150 1786    4     ! ! handle_queue( ath_msg, reject_code );
47160 1787    5     ! ! 
47170 1788    6     ! ! wait( atc_msg, main_sem.w^ );
47180 1789    7     ! ! 
47190 1790    8     ! ! IF ownertest( delay_pool, atc_msg ) THEN
47200 1791    9     ! !   delay_msg :=: atc_msg (* hold the message *)
47210 1792   10     ! ! ELSE
47220 1793   11     ! !   CASE atc_msg^.u3 OF
47230 1794   12     ! !   !   (* message origin *)
47240 1795   13     ! !   ! 
47250 1796   14     ! !   ! dummy_route:
47260 1797   15     ! !   !   return( atc_msg );
47270 1798   16     ! !   ! 
47280 1799   17     ! !   ! netc_route,
47290 1800   18     ! !   ! netc_route1: (* message from ATH *)
47300 1801   19     ! !   !   IF atc_msg^.u4 IN (.ts_cntrl, group_cntrl, ts_testi1, ts_testi2, ts_teste.) THEN
47310 1802   20     ! !   !     signal( atc_msg, queue_sem.w^ )
47320 1803   21     ! !   !   ELSE (* execute the operations that doesn't involve DRIVER *)
47330 1804   22     ! !   !     exec_conn_operation( atc_msg );
47340 1805   23     ! !   !  
\f

outlst      81.06.24.   17.09.                                                    page    58

48010 1806   24     ! !   ! at_route: (* message from DRIVER *)
48020 1807   25     ! !   !   BEGIN
48030 1808   26     ! !   !   ! 
48040 1809   27     ! !   !   ! driver_msg :=: atc_msg; (* hold message *)
48050 1810   28     ! !   !   ! 
48060 1811   29     ! !   !   ! conversation:= idle;
48070 1812   30     ! !   !   ! 
48080 1813   31     ! !   !   ! WITH driver_msg^ DO
48090 1814   32     ! !   !   !   IF ( u1 = create_at_ch ) AND ( u2 <> create_done ) THEN (* OBS!!! *)
48100 1815   33     ! !   !   ! ;
48110 1816   34     ! !   !   ! 
48120 1817   35     ! !   !   !   <*p
48130 1818   36     ! !   !   !   supervise
48140 1819   37     ! !   !   !   p*>
48150 1820   38     ! !   !   ! 
48160 1821   39     ! !   !   END;
48170 1822   40     ! !   ! 
48180 1823   41     ! !   ! OTHERWISE (* unknown route *)
48190 1824   42     ! !   ! reject_message( atc_msg, ath_sem, at_route, ts_macro, own_addr, unknown_route )
48200 1825   43     ! !   ! 
48210 1826   44     ! !   END (* case message origin *)
48220 1827   45     ! !   
48230 1828   46     ! UNTIL ( top_aac_index > 0 ) AND ( activity <> stop_code )
48240 1829   47     ! 
48250 1830   48     END; (* procedure restrict_protocol *)
48260 1831           
\f

outlst      81.06.24.   17.09.                                                    page    59

49010 1832            <*p
49020 1833            PROCEDURE exception( excode: integer );
49030 1834            
49040 1835            BEGIN
49050 1836            trace( excode );
49060 1837            
49070 1838            IF NOT nil( alarm_msg ) THEN
49080 1839            WITH ac_tbl( actual_ac_index ) DO
49090 1840            finish_message( alarm_msg, data_incomplete,
49100 1841            (**)          ( ac_tbl( pac_index ).sac_rac_ix <> sac_rac_ix ) );
49110 1842            
49120 1843            reject_code:= breaked;
49130 1844            
49140 1845            REPEAT
49150 1846            
49160 1847            handle_queue( ath_msg, reject_code );
49170 1848            
49180 1849            wait( atc_msg, main_sem.w^ );
49190 1850            
49200 1851            IF ownertest( delay_pool, atc_msg ) THEN
49210 1852            delay_msg :=: atc_msg
49220 1853            ELSE
49230 1854            WITH atc_msg^ DO
49240 1855            CASE u3 OF (* route *)
49250 1856            
49260 1857            dummy_route:
49270 1858            return( atc_msg )
49280 1859            ;
49290 1860            
49300 1861            netc_route,
49310 1862            netc_route1:
49320 1863            BEGIN
49330 1864            
49340 1865            IF u4 IN (.ts_cntrl, group_cntrl, ts_testi1, ts_testi2, ts_teste.) THEN
49350 1866            signal( atc_msg, queue_sem.s^ )
49360 1867            ELSE
49370 1868            IF ( u4 <> break_proc_end ) THEN
49380 1869            exec_conn_operation( atc_msg )
49390 1870            
49400 1871            END
49410 1872            ;
49420 1873            
49430 1874            at_route:
49440 1875            driver_msg :=: atc_msg
49450 1876            ;
49460 1877            
\f

outlst      81.06.24.   17.09.                                                    page    60

49470 1878            OTHERWISE
49480 1879            reject_message( atc_msg, ath_sem, at_route, ts_macro, own_addr, unknown_route )
49490 1880            
49500 1881            END
49510 1882            
49520 1883            UNTIL NOT nil( atc_msg ); (* break_proc_end received *)
49530 1884            
49540 1885            receipt_message( atc_msg, ath_sem, route_vect( atc_msg^.u3 ), 0, accepted )
49550 1886            
49560 1887            END; (* procedure exception *)
49570 1888            p*>
49580 1889           
\f

outlst      81.06.24.   17.09.                                                    page    61

50010 1890            (*********************************************************************************
50020 1891            *
50030 1892            *                             AT CONNECTOR : MAIN
50040 1893            *
50050 1894            *********************************************************************************)
50060 1895          
50070 1896        BEGIN
50080 1897    1   ! 
50090 1898    2   ! testopen( z, own.incname, op_sem );
50100 1899    3   ! 
50110 1900    4   ! testout( z, version , ts_env_vers );
50120 1901    5   ! testout( z, "chann/addr  ", ( ( channel_no * 1000 ) + own_addr ) );
50130 1902    6   ! 
50140 1903    7   !   (*********************************************************************************
50150 1904    8   !   * Set up and send a buffer create channel to DRIVER
50160 1905    9   !   *********************************************************************************)
50170 1906   10   ! 
50180 1907   11   ! alloc( driver_msg, driver_pool, main_sem.s^ );
50190 1908   12   ! 
50200 1909   13   ! create_channel;
50210 1910   14   ! 
50220 1911   15   !   (********************************************************************************
50230 1912   16   !   * Allocate TIMER message with main_sem as answer- and delay_pool semaphore
50240 1913   17   !   * as owner-semaphore
50250 1914   18   !   ********************************************************************************)
50260 1915   19   ! 
50270 1916   20   ! alloc( delay_msg, delay_pool, main_sem.s^ );
50280 1917   21   ! 
50290 1918   22   !   (********************************************************************************
50300 1919   23   !   * Start initialisation sequence
50310 1920   24   !   ********************************************************************************)
50320 1921   25   ! 
50330 1922   26   ! restrict_protocol;
50340 1923   27   ! 
50350 1924   28   !   (********************************************************************************
50360 1925   29   !   * End of initialization sequence
50370 1926   30   !   ********************************************************************************)
50380 1927   31   ! 
50390 1928   32   !   <*t testout( z, "end init    ", ord( conversation ) ); t*>
50400 1929   33   !  
\f

outlst      81.06.24.   17.09.                                                    page    62

51010 1930   34   ! REPEAT
51020 1931   35   ! !   (* forever........................................................................ *)
51030 1932   36   ! ! 
51040 1933   37   ! ! IF ( conversation = idle ) THEN
51050 1934   38   ! !   BEGIN
51060 1935   39   ! !   ! 
51070 1936   40   ! !   ! handle_queue( ath_msg, reject_code );
51080 1937   41   ! !   ! 
51090 1938   42   ! !   ! IF NOT nil( ath_msg ) THEN
51100 1939   43   ! !   !     (* repeat a interrupted conversation or start a queued one *)
51110 1940   44   ! !   !   initiate_conversation( ath_msg )
51120 1941   45   ! !   ! ELSE
51130 1942   46   ! !   !   IF NOT nil( delay_msg ) THEN
51140 1943   47   ! !   !     BEGIN
51150 1944   48   ! !   !     ! 
51160 1945   49   ! !   !     ! conversation:= busy;
51170 1946   50   ! !   !     ! send_telegram( poll_opc, poll_byte,
51180 1947   51   ! !   !     !   (**)         ( t_e_kind = ill_opc ), ( t_e_kind <> no_error ) )
51190 1948   52   ! !   !     ! 
51200 1949   53   ! !   !     END
51210 1950   54   ! !   !     
51220 1951   55   ! !   END;
51230 1952   56   ! !  
\f

outlst      81.06.24.   17.09.                                                    page    63

52010 1953   57   ! ! wait( atc_msg, main_sem.w^ );
52020 1954   58   ! ! 
52030 1955   59   ! ! IF ownertest( delay_pool, atc_msg ) THEN
52040 1956   60   ! !   delay_msg :=: atc_msg (* hold the message *)
52050 1957   61   ! ! ELSE
52060 1958   62   ! !   CASE atc_msg^.u3 OF (* message origin *)
52070 1959   63   ! !   ! 
52080 1960   64   ! !   ! dummy_route:
52090 1961   65   ! !   !   return( atc_msg );
52100 1962   66   ! !   ! 
52110 1963   67   ! !   ! netc_route,
52120 1964   68   ! !   ! netc_route1: (* message from ATH *)
52130 1965   69   ! !   !   IF atc_msg^.u4 IN (.ts_cntrl, group_cntrl, ts_testi1, ts_testi2, ts_teste.) THEN
52140 1966   70   ! !   !     signal( atc_msg, queue_sem.s^ )
52150 1967   71   ! !   !   ELSE
52160 1968   72   ! !   !       (* always execute the operations that does not involve DRIVER *)
52170 1969   73   ! !   !     BEGIN
52180 1970   74   ! !   !     ! 
52190 1971   75   ! !   !     ! exec_conn_operation( atc_msg );
52200 1972   76   ! !   !     ! 
52210 1973   77   ! !   !     ! IF ( activity = stop_code ) THEN
52220 1974   78   ! !   !     !   restrict_protocol
52230 1975   79   ! !   !     !   
52240 1976   80   ! !   !     END
52250 1977   81   ! !   ! ;
52260 1978   82   ! !   !  
\f

outlst      81.06.24.   17.09.                                                    page    64

53010 1979   83   ! !   ! at_route: (* response message from DRIVER *)
53020 1980   84   ! !   !   BEGIN
53030 1981   85   ! !   !   ! 
53040 1982   86   ! !   !   ! driver_msg :=: atc_msg; (* hold message *)
53050 1983   87   ! !   !   ! 
53060 1984   88   ! !   !   ! transm_cntrl( at_op_code, at_data, valid_response( conversation ) );
53070 1985   89   ! !   !   ! finish_conversation;
53080 1986   90   ! !   !   ! 
53090 1987   91   ! !   !   !   <*p
53100 1988   92   ! !   !   !   supervise;
53110 1989   93   ! !   !   !   
53120 1990   94   ! !   !   !   IF ( activity = stop_code ) THEN
53130 1991   95   ! !   !   !   restrict_protocol
53140 1992   96   ! !   !   !   p*>
53150 1993   97   ! !   !   ! 
53160 1994   98   ! !   !   END
53170 1995   99   ! !   ! ;
53180 1996  100   ! !   ! 
53190 1997  101   ! !   ! OTHERWISE (* unknown route *)
53200 1998  102   ! !   ! reject_message( atc_msg, ath_sem, at_route, ts_macro, own_addr, unknown_route )
53210 1999  103   ! !   ! 
53220 2000  104   ! !   END (* case message origin *)
53230 2001  105   ! !   
53240 2002  106   ! UNTIL forever;
53250 2003  107   ! 
53260 2004  108   END. (* process atconnector*)
53270 2005      
53280 2006      
\f

outlst      81.06.24.   17.09.                                                    page    65

           0  239*  245*  246*  256*  260*  260*  260*  270*  285*  295*  371*  418*  443*  446*  449*
              454*  455*  538   668   678   685   738   748   852   876   912   939  1063  1074  1152 
             1212  1214  1269  1386  1545  1753  1828 
           1  220*  221*  240*  247*  271*  296*  446*  539   659   803   853   859   877   910   937 
              989  1052  1161  1179  1180  1201  1275  1285  1316  1323  1466  1481  1484  1491  1607 
             1717  1762 
           2  241*  272*  297* 1274  1284  1317 
           3  242*  273*  298*
           4  274*  299*  880 
           5  275*  300*
           6  276*  301*
           7  277*  302*
          31  256*  285*
        1000 1901 
aac_address   871 
accepted      663:  991  1072  1140* 1211  1231* 1389  1648  1719  1737  1753 
activity       14*  987  1054  1070  1370= 1388= 1415= 1828  1973 
actual_ac_index                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              370*  874  1361  1409  1483  1484= 1484  1486  1487= 1613  1638  1647  1683  1688  1689=
             1691  1711 
ac_address_table                                                 <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              368*
ac_addr_tbl_e                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1446  1454= 1461  1467 
ac_index      706*  748 
ac_table_lth 1463 
ac_table_range                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              370*  890*  918* 1141* 1232*
ac_tbl        368*  866   874   909   912   936   939   988  1155  1361  1363  1409  1411  1454  1461=
             1467= 1491= 1491  1613  1615  1638  1647  1649  1683  1685  1691  1711  1713  1716 
addr          273* 1391  1395  1396  1679:
addr_code     909   912  1453  1460  1475 
alarmlabel    733 
alarmnetaddr 1237*
alarm_bytes   835*  854=  878 
alarm_msg     228* 1360  1362  1408  1410  1612  1614  1639  1640  1644  1648  1682  1684  1692  1710 
             1712  1717  1718  1719 
alloc        1907  1916 
al_form_0001  870 
al_form_0900 1350 
al_form_0902 1241 
al_form_1000 1445 
al_form_11__ 1305 
al_form_byte  796   840  1145  1760 
\f

outlst      81.06.24.   17.09.                                                    page    66

al_label      797   841   871  1146  1242  1306  1351  1446  1761 
al_net_addr  1248  1249=
as            530:  575:  593:  598:  733:  796:  840:  870: 1003: 1145: 1241: 1305: 1350: 1445: 1722:
             1760:
atconnector     1*
atc_cntrl     240* 1161 
atc_format    252*  260*  260*  575   593   598 
atc_msg       229* 1788  1790  1791  1793  1797  1801  1802  1804  1809  1824  1953  1955  1956  1958 
             1961  1965  1966  1971  1982  1998 
atc_opc       254*  584= 1762 
atc_op_codes  250*  254*  550*
atc_teste     242*  250* 1201 
atc_testi     241* 1185  1189 
ath_mic_addr 1352 
ath_msg       226*  757  1617  1618  1619  1748  1749  1753  1760: 1786  1936  1938  1940 
ath_sem         9*  668   678   685   863  1212  1540  1545  1619  1753  1824  1998 
at_control    538 
at_data       455*  945* 1015= 1644  1688  1718  1749  1984 
at_format     282* 1003 
at_opc        284* 1007  1010  1014 
at_op_code    454*  944* 1014= 1632  1984 
at_op_codes   280*  284*  399*  454*  944*
at_route      441*  536   739  1806: 1824  1979: 1998 
at_route1     441*
at_time_out   296*
au_alarm      272* 1391  1395  1396  1637:
au_alarm_opc  324*  858  1640  1692 
au_error      298* 1731 
a_delay       753:
a_semaphore   732:
batt_limit    301* 1725 
batt_supply   302*  305* 1725 
bit_error     405* 1001 
block_lth     703*  737   836*  850=  852   853   867   876   877   880  1640  1692 
boolean       255*  553*  707*  780*  818*  890*  918*
breaked       675:
break_proc_end                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              360*
busy          381*  420*  543  1366  1391  1399  1418  1422  1601: 1945 
byte           27*  253*  283*  438*  446*  452*  455*  551*  703*  779*  836*  890*  945*  971* 1234*
call         1052  1086  1103 
channel_error                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              407* 1030 
channel_no     27*  535   620  1901 
\f

outlst      81.06.24.   17.09.                                                    page    67

check        1000 
check5        596  1000 
checkbits     256*  285*
coll_alarm1   385* 1395  1604: 1667  1697 
coll_alarm2   386*  420* 1396  1604: 1651  1656  1666 
compute_delay                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1255* 1383  1413 
com_pool       11*  730 
connector_state                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
               14*
connect_message                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1234* 1434  1441 
connect_test  342* 1433: 1441 
control       382* 1160  1392  1604:
conversation  391*  543= 1160= 1182= 1200= 1366= 1368= 1399= 1401= 1422= 1424= 1599  1602= 1621= 1635=
             1651  1652= 1656= 1666  1667= 1676= 1697= 1703= 1741= 1755= 1811= 1933  1945= 1984 
con_lam_time  539 
create_at_ch  534  1814 
create_channel                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              519* 1909 
create_ch_format                                                 <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              446*  530 
create_done  1814 
data          804=  854   878=  971*  990  1161  1201  1762 
data_byte     551*  586   779*  804 
data_bytes    835*
data_incomplete                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1362  1410  1614  1619  1684  1712 
dc_erh_mic_addr                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              989 
dc_macro       24*  989  1174  1307  1352  1447 
definetimer   726   770 
delay          16* 1267=
delay3        452*  609  1289=
delay4        452*  610  1269= 1275= 1275  1285= 1285 
delay_msg     225*  605   606   612  1791= 1916  1942  1956=
delay_pool    221* 1790  1916  1955 
driver_msg    227*  530:  531   545   575:  593:  596   598:  616   624   997  1000  1003: 1027  1365 
             1398  1421  1722: 1809= 1813  1907  1982=
driver_pool   220* 1907 
driver_sem     10*  545   624 
dummy         443*  867  1607  1607  1641  1693  1717 
dummy_alarm   358* 1434  1437: 1440 
dummy_macro   867  1641  1693  1717 
\f

outlst      81.06.24.   17.09.                                                    page    68

dummy_route   653  1796: 1960:
d_ack         274* 1392  1745:
exec_conn_operation                                              <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1218* 1804  1971 
e_ack         276* 1394  1747:
false         260*  442*  770  1000 
finish_conversation                                              <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1581* 1985 
finish_message                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              814*  884   991  1362  1410  1614  1648  1684  1712  1719 
forbidden    1175  1308  1325  1353  1448 
forever      2002 
frequence    1383  1413 
generate      596 
get_message   699*  772=  867   989  1640  1692  1717 
group_cntrl   332*  658   684  1151: 1801  1965 
h01           318*
h12           321*
h30           324*
h31           325*
h32           326*
h34           327*
h35           328*
h40           331*
h44           332*
h80           335*
h82           336*
h84           337*
h90           340*
h92           342*
ha0           345*
handle_queue  628*  757  1786  1936 
hb2           351*
hb4           348*
hb6           352*
hba           353*
hbc           354*
hc0           356*
hc8           358*
hce           360*
hs_error      297* 1734 
idle          380*  391* 1368  1401  1424  1602  1621  1635  1652  1676  1703  1741  1755  1811  1933 
illegal_operation                                                <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              681: 1416  1477 
\f

outlst      81.06.24.   17.09.                                                    page    69

ill_opc       406* 1019  1162  1186  1190  1202  1607  1658  1670  1699  1763  1947 
incname      1898 
initiate_conversation                                            <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1125* 1940 
insert_code  1321: 1459:
integer        16*   26*  220*  410*  412*  413*  414*  418*  449*  706*  918* 1255* 1293*
in_data       283* 1015 
label_size    844  1158  1198 
last_telegram                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              260*  576   578   594   599= 1761 
line_alarm    325*  858  1051  1068 
line_state    424* 1080  1087= 1096= 1104= 1113= 1385=
lock          530:  575:  593:  598:  733:  796:  840:  870: 1003: 1145: 1241: 1305: 1350: 1445: 1722:
             1760:
locvar        530:  538=  539=  575:  576=  593:  594=  598:  599   733:  734   796:  797   840:  841 
              841   870:  871  1003: 1004  1145: 1146  1241: 1242  1305: 1306  1306  1350: 1351  1445:
             1446  1722: 1725  1728  1731  1734  1760: 1761 
log_to_pac    818*  847   865   884 
low           425*  427* 1082: 1096  1385 
macro         742=  745= 1174  1307  1352  1447 
macroaddr      25*  704*
main_sem        4* 1788  1907  1916  1953 
max_byte     1281 
max_int       659   859  1046  1271 
max_succ_lin_err                                                 <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              414*
max_succ_t_e  414* 1048  1065  1520  1605 
micro         743=  746=  874= 1352 
msg           630*  646   649   650   652   654   668   678   685   695   701*  730   733:  734   768 
              772   778*  796:  797   816*  840:  841   863   867   870:  871   884   983*  989   990 
              991  1218* 1234* 1241: 1242  1305: 1322  1339  1344  1345  1350: 1434  1441  1445: 1540 
             1540  1544  1545  1545 
netc_route    438* 1799: 1963:
netc_route1   438* 1800: 1964:
new_opc       550*  584 
new_serial_no                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              552*  574   590 
node_test     356*
not_ack       404* 1008 
not_found    1456  1495 
not_ready     389*  676: 1377 
not_steering 1167 
no_connection                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              674:
\f

outlst      81.06.24.   17.09.                                                    page    70

no_error      402*  422* 1013  1039  1597  1608  1658  1670  1699  1763  1947 
no_of_by      844= 1158  1180= 1180  1198  1317= 1317 
no_resources  673:  757 
no_room      1471 
no_succ_t_e   418* 1045= 1045  1046  1048  1065  1074= 1386= 1605  1607 
n_ack         277*  280* 1007  1391  1392  1393  1394  1395  1396  1418  1419 
ok_result     997 
open          646 
operation_code                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              702*  740 
op_code       971*  989 
op_sem          2* 1898 
ord          1043  1046  1052  1063 
out_data      253*  586=
override      442*  991  1162  1186  1190  1202  1719 
own          1898 
ownertest    1790  1955 
own_addr       26*  746  1540  1824  1901  1998 
package_count                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              449*  659=  659   859=  859  1508 
pac_alarm_log                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              318*  858   867 
pac_index     370*  866   906   933   988  1363  1376  1411  1476  1487  1615  1649  1685  1689  1713 
             1716 
param        1255* 1267  1271  1274= 1274  1279= 1279  1281  1284= 1284  1289 
parameter    1293* 1316  1323=
params       1316= 1323 
passivated    677: 1371 
passive       695   768 
poll_byte     245* 1657  1669  1698  1946 
poll_opc      239*  250* 1657  1669  1698  1946 
pool          220*  221*
process         1*
p_ack         270*  280* 1391  1396  1418  1634:
queue_sem       6*  646   650   695   768  1802  1966 
ready_byte_msg                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              776*  808=  990  1644  1718  1749 
read_code    1313: 1452:
read_package_count                                               <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              348* 1322  1507:
rec           742   743 
recall       1068  1095  1112 
receipt      1434  1440 
receipt_message                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              668   678   685  1212  1545  1619  1753 
\f

outlst      81.06.24.   17.09.                                                    page    71

receipt_route                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              438*  441*
rec_macro     704*  742 
rec_micro     705*  743 
reference     229*  630*  701*  778*  816*  983* 1125* 1218* 1234*
reject_cause  631*  661   668   678   685   689 
reject_code   389* 1036  1055= 1071  1072= 1371= 1389= 1416= 1726= 1729= 1732= 1735= 1737= 1786  1936 
reject_message                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1540  1824  1998 
reject_opc    321* 1341:
remove_code  1474:
request_msg  1125* 1145: 1146  1212  1212  1214 
res           817*  845   884  1231* 1308= 1325= 1329= 1353= 1377= 1429= 1448= 1456= 1471= 1477= 1495=
             1499= 1545 
restart       300*
restrict_protocol                                                <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              464* 1772* 1922  1974 
result        845=
result_code  1140* 1167= 1171= 1175= 1211  1212 
result_range  389*  631*  817* 1140* 1231*
return        654  1344  1797  1961 
route_vect    441*  668   678   685  1212  1540  1545  1619  1753 
rw_param     1293* 1504  1508  1512  1516  1520 
r_w_max_succ_t_e                                                 <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              354* 1519:
r_w_service_limit                                                <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              352* 1511:
r_w_s_a_limit                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              353* 1515:
r_w_tec       351* 1503:
s            1907  1916  1966 
sac_rac_ix    867   874   936   939   989  1363  1363  1411  1411  1615  1615  1641  1649  1649  1685 
             1685  1693  1713  1713  1717 
search_ac_index                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              918*  939= 1152 
search_addr_code                                                 <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              890*  912= 1453  1460  1475  1688 
sempointer      2*   11*
send          745   746  1174  1247  1248= 1307  1352  1352  1447 
sendtimer     612 
send_line_state                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              971* 1051  1068  1086  1095  1103  1112 
send_telegram                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              549* 1161  1185  1189  1201  1607  1657  1669  1698  1762  1946 
\f

outlst      81.06.24.   17.09.                                                    page    72

serial_number                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              255*  585=  585   591=  591 
serif_error   299* 1728 
service_alarm                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              327* 1086  1095 
service_code 1405: 1415 
service_lim   412*
service_limit                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              412* 1083  1092  1512 
serv_lim_excess                                                  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              426* 1087  1091: 1113 
signal        545   624   863  1802  1966 
start_code    987  1054  1070  1375: 1388 
state         271* 1391  1392  1393  1394  1395  1396  1707:
state_alarm   326*  858  1717 
state_au_error                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              682: 1732 
state_bit     309*
state_bits    305*  306*  309*
state_byte    306* 1722 
state_hs_error                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              666: 1735 
state_power_error                                                <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              671: 1036  1726 
state_serif_error                                                <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              683: 1729 
steering     1155 
steering_ac_index                                                <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1141* 1152  1155 
stop_code    1357: 1370  1828  1973 
stop_poll_lim                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              413*
s_a_alarm     328* 1103  1112 
s_a_limit     413* 1043  1100  1109  1516 
s_a_lim_excess                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              427* 1104  1108:
table_index   890*  906=  908   909   910=  910   912   918*  933=  935   936   937=  937   939  1232*
             1453  1454  1460  1461  1475  1476  1483  1486  1490= 1490  1491  1491 
table_key     890*  909   912   918*  936   939 
teste         384* 1200  1394  1604:
testi         383* 1182  1393  1419  1604:
testi1_byte   246* 1185 
testi2_byte   247* 1189 
testopen     1898 
\f

outlst      81.06.24.   17.09.                                                    page    73

testout       689  1345  1900  1901 
timeout_err  1027  1052 
time_excess   403* 1028  1052 
time_out_unit                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1271  1279 
top_aac_index                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              371*  908   912   935   939  1376  1463  1466= 1466  1467  1481= 1481  1490  1828 
transmission_error                                               <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              553*  574   581 
transmit_error                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              672: 1055  1071 
transm_cntrl  943* 1984 
trans_err_rate                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              410*
true          726 
ts_add        748= 1152 
ts_cntrl      331*  658   684  1150: 1801  1965 
ts_env_vers  1900 
ts_macro       25*  745  1540  1824  1998 
ts_newactivity                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              340* 1349:
ts_pointer      6*
ts_teste      337*  658   667   684  1195: 1801  1965 
ts_testi1     335* 1173: 1184  1801  1965 
ts_testi2     336* 1173: 1801  1965 
type_of_conversation                                             <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              379*  391*
t_ack         275* 1393  1419  1746:
t_e_counter   417* 1042= 1042  1043  1063= 1063  1063  1083  1092  1100  1109  1381= 1504 
t_e_c_init   1381 
t_e_kind      422* 1001= 1008= 1013= 1019= 1028= 1030= 1039  1052  1162  1186  1190  1202  1597  1607 
             1608  1658  1658  1670  1670  1699  1699  1763  1763  1947  1947 
t_e_kind_type                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              401*  422*
t_e_step      410* 1043 
u1            534=  619=  737=  800   808  1158= 1179= 1198= 1619  1814 
u2            535=  620=  738=  800   803=  803   804   808   844   850   853=  854   854   877=  878 
              878   880=  997  1027  1214= 1619  1762  1814 
u3            536=  609=  653   668   678   685   739= 1212  1345  1540  1545  1619  1753  1793  1958 
u4            610=  658   667   684   740=  858  1148  1184  1245= 1322  1339  1801  1965 
unknown_opcode                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1540 
unknown_route                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1824  1998 
\f

outlst      81.06.24.   17.09.                                                    page    74

unknown_sender                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1171 
unknown_update                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
             1329  1429  1499 
unused        295*  305*  309*
update       1311  1355  1450 
upd_ac_table  345* 1444:
upper_ac_tbl_index                                               <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              371*
user4        1234* 1245 
valid_response                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              420*  946* 1010  1391= 1392= 1393= 1394= 1395= 1396= 1418= 1419= 1984 
valid_set     399*  420*  946*
version        31* 1900 
w             646   650   695   768  1788  1802  1953 
wait          650  1788  1953 
waitsd        730 
wait_sem_delay                                                   <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              730 
work_addr    1237* 1247= 1249 
write_read_at                                                    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
              619 
z             457*  689  1345  1898  1900  1901 
zone          457*
\f

outlst      81.06.24.   17.09.                                                    page    75

AND                9
ARRAY              3
BEGIN             74
CASE              12
CONST              6
DIV                3
DO                53
ELSE              45
END               88
FOR                3
FORWARD            1
FUNCTION           4
IF                89
IN                 9
MOD                2
NIL               19
NOT               20
OF                18
OR                 3
OTHERWISE         12
PACKED             2
PROCEDURE         14
RECORD             2
REPEAT             4
SET                2
THEN              89
TO                 3
TYPE               7
UNTIL              4
VAR               29
WHILE              4
WITH              30
*pascal80 codesize.12000 alarmenv tsenvir atcsource
81.06.24.      17.11.                         pascal80     version 1981.04.01


   name        headline beginline endline  appetite(words) 

   create_chann   528       530     545  :      11            
   send_telegra   572       575     624  :      15            
   handle_queue   644       647     695  :      19            
   get_message    724       726     772  :      15            
   ready_byte_m   794       796     812  :      13            
   finish_messa   835       840     888  :      40            
   search_addr_   904       906     912  :       9            
   search_ac_in   931       933     939  :       9            
   send_line_st   983       988     991  :      25            
   transm_cntrl   971       998    1123  :      15            
   initiate_con  1140      1145    1216  :      25            
   connect_mess  1237      1241    1253  :      15            
   compute_dela  1265      1267    1291  :       3            
   rw_param      1303      1305    1333  :      13            
   exec_conn_op  1231      1341    1545  :      28            
   finish_conve  1595      1599    1770  :      24            
   restrict_pro  1782      1786    1828  :      18            
   atconnector     31      1898    2004  :     164            

 code: 0 . 9858  = 9858 bytes


end of PASCAL80 compilation 

end
blocksread = 52
*o c
«eof»