DataMuseum.dk

Presents historical artifacts from the history of:

RC4000/8000/9000

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

See our Wiki for more about RC4000/8000/9000

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download

⟦1eed1b733⟧ TextFile

    Length: 16128 (0x3f00)
    Types: TextFile
    Names: »paxenv«

Derivation

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

TextFile

pax_env;

(*----------------------------------------------------------------------
-                                                                      -
-  paxnet-environment is used by the modules                           -
-  AL_DTE_SIM                                                          -
-  LINK_PROTOCOL_HANDLER                                               -
-  LAM116                                                              -
-                                                                      -
------------------------------------------------------------------------*)

(*--- abbreviations ---*)

(*
variables used at DTE-INTERFACE (ie between PAXCON and X25DTE) are prefixed with DTE_

variables used at ROUTER-INTERFACE (ie between X25DTE and ROUTER) are prefixed with RUT_

variables used at LINK-INTERFACE (ie between ROUTER and LPH) are prefixed with LIN_

variables used at LAM-INTERFACE (ie between LPH and LAM) are prefixed with LAM_

*)
\f


(*-------------------------------------------------------------------------
-   Generel constants                                                     -
--------------------------------------------------------------------------*)
const

l_rut_prefix = 14;         (* the length of a router prefix  *)
(*                          measured in bytes *)
l_phead1 = 20;             (* the length of a packet header format 1 *)
(*                          measured in bytes *)
l_dte_adr = 7;             (* the length of an external dte-address *)

l_facilities = 2;          (* the length of the facility-field *)

l_control = 6;

l_listen = 50; (* 50 because of logbuffers in fets *)

(*--------------------------------------------------*)
ric_first_val = 9;         (* the minimal value for first *)

aic_first_val = 6 ;

sdata_first_val = 8 ;

rejic_first_val = 6 ;

(*--------------------------------------------------*)
min_stream_no = 1;

max_stream_no = 14;

max_queue = no_listen;

stream_timeout = 10;     (* measured in sec *)

windowsize = 2;

max_locals = 6;

max_globals = 10;

glob_timeout = 3*stream_timeout;
\f


(*--------  max_l_data shall be bigger than (l_control + l_listen) ---*)
(*--------  because the router locks these buffers                 ---*)
max_l_data = 200;

min_ric_data = 86;

no_pax_bufs = 40;

nil_macro = macroaddr( 15, 0, 0);

init_netc_macro = macroaddr( 0, 0, 0);
\f


(*------------------------------------------------------------------------
-   General types used in other types                                    -
---------------------------------------------------------------------------*)
type

netc_loc_sems
= array (1..max_locals) of sempointer;

ext_pax_addr
= packed array (1..14) of 0..15;


int_pax_addr
= record
net_addr,
reg_addr,
node_addr : byte;
ext_addr  : integer
end;

paxnet_addrs = array (0..15) of ext_pax_addr;

const
alarm_ext = 3;

dc_alarm_macro = macroaddr(1,0,0);

paxnet_config
= paxnet_addrs (
ext_pax_addr( 0,0,0, 0,0,0, 0,0,0, 0,0,0,0,3),
ext_pax_addr( 0,0,1, 0,0,0, 0,0,0, 0,0,0,0,3),
ext_pax_addr( 0,0,1, 0,0,1, 0,0,0, 0,0,0,0,3),
ext_pax_addr( 0,0,1, 0,0,2, 0,0,0, 0,0,0,0,3),
ext_pax_addr( 0,0,1, 0,0,1, 0,0,1, 0,0,0,0,3),
ext_pax_addr( 0,0,1, 0,0,1, 0,0,2, 0,0,0,0,3),
ext_pax_addr( 0,0,1, 0,0,2, 0,0,1, 0,0,0,0,3),
9 *** ext_pax_addr( 0,0,1, 0,0,0, 0,0,0, 0,0,0,0,3));

type

(*--- maximal messages without control field ---*)

max_alarm_mess
= record
al : alarmlabel;
da : array (label_size+3..l_listen) of byte;
end;

max_dte_mess
= array (1..l_listen+(l_dte_adr+1)+(l_facilities+1)+l_control+10) of byte;

max_rut_mess
= array (1..l_listen+(l_rut_prefix+l_phead1+l_control)) of byte;

(*-----  the minimal size of a buffer the router can lock ---*)
min_rut_mess
= array (1..max_l_data+l_phead1+l_rut_prefix) of byte;

paxpooltype = pool no_pax_bufs of min_rut_mess;
\f


rut_prefix_type
= record
first, last, next : integer;
ext_no,
rut_param2,
rut_param3,
rut_param4
: integer
end;

state_type = (
free,
calling,
sending,
receiving,
waiting,
clearing,
resetting );


upd_kinds = (
inc_all,
inc_q,
dec_f_q,
dec_s_q,
new_stat
);
\f


stream_s_e
= record
act_out : reference;
first_queue,
second_queue : semaphore;
state : state_type;
l_f_q,
l_s_q : integer;
pax_addr : ext_pax_addr;
retrans_timer :  byte;
retrans_timo : byte;
retrans_count :  byte;
max_retrans   :  byte;
v_s_inc,
v_s,
v_r_inc,
v_r : byte;
timers :
array (1..max_queue) of integer;
end;

paxnet_e
= record
al_mac_addr : macroaddr;
pax_addr : ext_pax_addr;
stream_no : byte;
max_retrans : byte;
end;

\f


facility_mask
= packed record
reject,         (* ie the packet is returned in case of errors *)
reject_lifetime,(* ie the packet is returned when lifetime is exceeded *)
time_lifetime,  (* ie the packet contains a trailer with lifetime *)
(*                 measured in timeunits *)
link_lifetime,  (* ie the packet contains a trailer with lifetime *)
(*                 measured in number of nodes *)
reject_header,  (* ie only the messageheader is returned in case of reject *)
broadcast,      (* ie the message is broadcasted *)
(*                 can only be used together with lifetime *)
ffu9,
ffu8,
mirror,         (* ie the packet is returned by the router in the *)
(*                 destination node *)
drop,           (* ie the packet is dropped by the router in the  *)
(*                 destination node *)
selected_path,  (* ie the packet contains a trailer specifying nodeaddresses *)
(*                 for a selected path to the destination *)
fixed_path,     (* ie the packet contains trailers specifying a fixed path *)
(*                 each trailer is timemarked by its corresponding node    *)
ffu3,
ffu2,
ffu1,
trace           (* ie the packet contains a trailer in which each node *)
(*                 inserts a trailer record with nodeaddress *)
: bit
end;

\f


format_1_packet_header
= packed record
format,       (* describes the formatnumber of the header *)
priority,     (* packet priority in the datagramnet *)
packet_type   (* external user packet or internal supervisor packet *)
(*               the value is inserted by the router *)
: byte;
dst           (* destination address *)
: int_pax_addr;
state         (* rejection cause *)
: byte;
org           (* origin address *)
: int_pax_addr;
facility :    (* bitmask defining different netfunctions  *)
integer;
user_field,   (* user defined field; transparent in the net *)
top_of_data : (* points to first free byte or start of trailer *)
integer
end;
\f


control_field_type
= record
op_code,
data,
n_s_inc,
n_s,
n_r_inc,
n_r
: byte
end;

call_field_type            (* used in dte packets *)
= record
dte_adr_l : byte ;         (* length of dte-adr   *)
dte_adr
: ext_pax_addr ;
facility_l : byte ;
facility
: integer ;
control : control_field_type;
alarm_mess : max_alarm_mess;
end;

tst_call_f_type
= record
d_l : byte;
d_a : ext_pax_addr;
f_l : byte;
fac : integer;
control : control_field_type;
a_l : alarmlabel;
indx : integer;
p_e : paxnet_e;
end;

\f


(*------------------------------------------------------
-   op-codes in end-to-end protocol                    -
--------------------------------------------------------*)
const
new_stream = 1;
no_stream = 0;

data_received = 128;
data_not_received = 64;

opc_command = 48;
opc_receipt = 96;

connec_exists = 32;

(*------------------------------------------------------
-   router constants                                   -
--------------------------------------------------------*)
const
rut_format_1 = 2;    (* packet format 1 *)
rut_prio_0   = 0;
rut_pack_type= 1;

\f


(*-----------------------------------------------------------------------
-   LIC - establishment                                                 -
-------------------------------------------------------------------------*)

(*---  functions  ---*)

const

dte_car =  1*4 +0;    (* call request  *)
rut_con =  1*4 +0;    (* connect extension  *)
lin_con =  1*4 +0;    (* connect line  *)
lam_con =  3*4 +0;    (* create channel     *)
(*                       should be changed to 1*4 +0 in lam116-driver *)

dte_ric  =  3*4 +0;   (* receive incomming call *)
rut_srdy =  2*4 +1;   (* sense ready *)
rut_get  =  1*4 +1;   (* get packet  *)
<*
lin_rec               (* receive message *)
lam_rec               (* read *)
*>

dte_aic =  4*4 +0;    (* accept incomming call *)
<*
rut_trp               (* transmit package *)
lin_trm               (* transmit message *)
lam_trm               (* write *)
*>

dte_rejic =  5*4 +0;
(*
rut_trp                 transmit package
lin_trm                 transmit message
lam_trm                 write
*)
\f


type

car_buf_type
=  record
first, last, next : integer ;
q_bit : boolean ;
dummy : integer;
call_buf : call_field_type
end;

ric_buf_type
=  record
first, last, next : integer ;
delay1, delay2 : byte ;
call_id : byte ;
call_buf : call_field_type 
end;

tst_ric_type
= record
f, l, n : integer;
d1, d2 : byte;
c_i : byte;
c_b : tst_call_f_type;
end;

aic_buf_type
= record
first, last, next : integer;
aic_id : byte;
aic_q : boolean
end;

rejic_buf_type
= record
first, last, next : integer;
rejic_id : byte;
rejic_diag : byte
end;
\f


(*------------------------------------------------------------------
-  LIC - removal                                                   -
---------------------------------------------------------------------*)

(*---  functions  ---*)

const
dte_clr =  2*4 +0;   (* clear request  *)
rut_dis =  2*4 +0;   (* disconnect extention *)
lin_dis =  2*4 +0;   (* disconnect line *)
lam_dis =  0;        (* not implemented *)

type
clear_buf_type
= record
first, last, next : integer;
diag_code : byte;
end;
\f


(*------------------------------------------------------------------
-  LIC - reset                                                     -
--------------------------------------------------------------------*)

(*---  functions  ---*)

const
dte_res = 7*4 +0;    (* reset request *)
rut_res = 3*4 +0;    (* reset *)
lin_res = 3*4 +0;    (* return all buffers *)
lam_res = 0;         (* not implemented *)

\f


(*-----------------------------------------------------------------
-  LIC - send message                                             -
-------------------------------------------------------------------*)

(*---  functions  ---*)

const
dte_sdata =  0*4 +2;   (* send data *)
rut_trp   =  0*4 +2;   (* transmit package *)
lin_trm   =  0*4 +2;   (* transmit message *)
lam_trm   =  3*4 +2;   (* write *)
(*                        should be changed to 0*4 +2 in lam116-driver *)
\f


type
dte_sdata_data
=  record
first, last, next
: integer ;
q_bit,                   (* q-bit usage *)
m_bit                    (* tells if there is more data in the following packet *)
: boolean ;
control
: control_field_type;
alarm_mess
: max_alarm_mess;
end;

rut_trp_pdata
=  record
rut_prefix
: rut_prefix_type;
phead
: format_1_packet_header;
control
: control_field_type;
alarm_mess
: max_alarm_mess;
end;

tst_sdata_data
= record
f,l,n : integer;
q,m : boolean;
control : control_field_type;
a_l : alarmlabel;
indx : integer;
p_e : paxnet_e;
end;
\f


(*-----------------------------------------------------------------
-  LIC - receive message                                          -
-------------------------------------------------------------------*)

(*---  functions  ---*)

const
dte_rdata =  0*4 +1;   (* receive data *)
rut_rec   =  0*4 +1;   (* receive packet *)
lin_rec   =  0*4 +1;   (* receive message *)
lam_rec   =  3*4 +1;   (* read *)
(*                        should be changed to 0*4 +1 in lam116-driver *)

\f


(*----------------------------------------------------------------
-  LIC - status
------------------------------------------------------------------*)

(*---  functions  ---*)

const
dte_stat = 0*4 +0;   (* stream status *)
rut_stat = 0;        (* not implemented *)
lin_stat = 0*4 +0;   (* sense status  *)
lam_stat = 0;

\f


(*---------------------------------------------------------------
-  LIC - test                                                   -
-----------------------------------------------------------------*)

(*---  functions  ---*)

const
rut_dir =  1*4 +2;   (* directed transmit *)

(*-------------------------------------------------------------
-  LIC - routes                                               -
---------------------------------------------------------------*)

const
(*  the following values must not be used by the alarmnet *)
(*  as operationcodes i e u4-values         *)

to_link    = 255;   (* used in messages with direction towards
the physical link in the LIC *)
from_link  = 254;   (* used in messages with direction from
the physical link in the LIC *)
dyn_test = 253; (* used to dynamic control of test *)
\f


(*-----------------------------------------------------------
-  ROUTER results                                           -
-------------------------------------------------------------*)
const
rut_default    =   7;      (* default result to router       *)
rut_ok         =   0;      (* processed succesfully          *)
rut_not_proc   =   1;      (* not processed                  *)
rut_ill        =   4;      (* illegal function               *)
rut_format_err =  12;      (* illegal format                 *)
rut_buffer_err =  28;      (* buffer too small               *)
rut_no_res     =   5;      (* no resources in router         *)
rut_ext_err    =   6;      (* extension exists allready      *)

\f


(*-----------------------------------------------------------
-  DTE results                                              -
-------------------------------------------------------------*)

const
dte_default    =   7;     (* default result to dte          *)
dte_ok_result  =   0;     (* processed succesfully           *)
dte_reject     =   1;     (* dte and user not synchronized   *)
dte_lost_int   =  89;     (* int buffer send too late        *)
dte_no_trans   =  97;     (* local line error                *)
dte_err_trans  = 105;     (* local line error, but transmit  *)
dte_busy       =   2;     (* no internal resources ie streams*)
dte_timeout    =  10;     (* given timerperiode has elapsed  *)
dte_no_net     =  18;     (* net unaccessible or dte restart *)
dte_enough_ric =  90;     (* too many ric-buffers at dte     *)
dte_restart    =  98;     (* dte has been restarted          *)
dte_user_clear =   3;     (* user has given a stream clear   *)
dte_remo_clear =  19;     (* stream cleared by net, dte,user *)
dte_reset      = 106;     (* stream reset   by net, dte,user *)
dte_ill_func   =  12;     (* function code in u1 is illegal  *)
dte_not_allow  =  12;     (* func not allowed in dte state   *)
dte_format_err =  20;     (* message format is illegal       *)
dte_buffer_err =  28;     (* buffer too small                *)
dte_receiv_err =  36;     (* receiver is unknown to dte/net  *)
dte_mess_err   =  44;     (* u2-value is not equal to 7      *)
dte_ill_callid =  92;     (* call-id is illegal              *)
dte_car_err    = 100;     (* format or length error in car   *)
dte_stream_err = 108;     (* too big streamnumber            *)

.
▶EOF◀