DataMuseum.dk

Presents historical artifacts from the history of:

CR80 Hard and Floppy Disks

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

See our Wiki for more about CR80 Hard and Floppy Disks

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦51b98e5e6⟧ TextFile

    Length: 23176 (0x5a88)
    Types: TextFile
    Names: »PREFIX«

Derivation

└─⟦8c095a7f3⟧ Bits:30005798 CR80 Disc Pack ( Vol ILS systemdisk XAMOS TOS 10:01 hard boot #43c 19-7-87/JFJ )
    └─ ⟦this⟧ »SYSTEMS.D!XAMOS.D!GEN850501.D!FILE.D!TOS.D!PREFIX« 
└─⟦b8af24a88⟧ Bits:30005796 CR80 Disc Pack ( MINICAMPS )
    └─ ⟦this⟧ »GENS.D!SYSGEN.D!MINI_CAMPS.D!PREFIX« 
└─⟦c2e810e96⟧ Bits:30005799 CR80 Disc Pack ( XAMOS 841129 ILS TOS 10-01 System Disk Tilhører ILS/MSG hard boot boot entry #43c )
    └─ ⟦this⟧ »SYSTEMS.D!XAMOS.D!GEN850501.D!FILE.D!TOS.D!PREFIX« 

TextFile

"CR80 PASCAL STANDARD PREFIX. PHO«bs»/-800522"
"#######################################"
"**********    A  M  O  S     **********"
"#######################################"

CONST NL = '(:10:)';  FF = '(:12:)';  CR = '(:13:)';  EM = '(:25:)';
CONST NULL = '(:0:)';  SP = ' ';

CONST LINELENGTH = 132;
TYPE LINE = ARRAY [1..LINELENGTH] OF CHAR;
TYPE TEXT = LINE;

TYPE PROGRESULT = (TERMINATED, OVERFLOW, POINTERERROR,
                   RANGEERROR, VARIANTERROR, HEAPLIMIT,
                   STACKLIMIT, CODELIMIT, TIMELIMIT, CALLERROR,
                   DATALIMIT);

TYPE BITPOSITION = 0..15;
TYPE BITFIELDLENGTH = 0..16;
TYPE BITVALUE = (LOW, HIGH);

TYPE MESSAGE_BUFFER = ARRAY [1..5] OF INTEGER;

TYPE WORD_ADDRESS = RECORD
                      MEMORY_SECTION: INTEGER;
                      WORD_DISPLACEMENT:INTEGER
                    END;

TYPE BYTE_ADDRESS = RECORD
                      BYTE_DISPLACEMENT: INTEGER;
                      WORD_ADDR: WORD_ADDRESS
                    END;

TYPE FILE = INTEGER;
TYPE COMPLETION_CODE = INTEGER;
TYPE ELEMENT = ARRAY [1..1] OF INTEGER;
TYPE PACKED_NAME = ARRAY [0..7] OF INTEGER;
TYPE PACKED_NAME3 = ARRAY [0..2] OF INTEGER;
TYPE PACKED_NAME2 = ARRAY [0..1] OF INTEGER;

TYPE PROCESS_NAME = RECORD
                       NAME: PACKED_NAME3;
                       NAME_IDENT: INTEGER
                    END;

TYPE FILE_SYSTEM_NAME = RECORD
                           PNAME: PROCESS_NAME;
                           GNAME: PACKED_NAME2
                        END;
TYPE VOLUME_NAME = PACKED_NAME;
CONST DIRECTORY = 10;  CONTIGUOUS = 12;  RANDOM = 14;
TYPE FILE_ORGANIZATION = DIRECTORY..RANDOM;
TYPE FILE_ATTRIBUTES = RECORD
                          VOLUME: VOLUME_NAME;
                          ORGANIZATION: FILE_ORGANIZATION;
                          ALLOC_SIZE: LONG_INTEGER;
                          AREA_SIZE: INTEGER
                       END;
TYPE USERID = ARRAY [0..1] OF INTEGER;
TYPE ACCESS_DESCRIPTION = RECORD
                             USER: USERID;
                             RIGHTS: ARRAY [0..1] OF INTEGER
                          END;
TYPE FILE_INFORMATION_TYPE = (F_ORGANIZATION, F_SIZE, F_ALLOCSIZE,
                              F_BODYADDR, F_AREASIZE, F_THRESHOLD,
                              F_LINKS, F_INBFD, F_BFDNBR);
TYPE DEVICE_NAME = PACKED_NAME2;
TYPE DEVICE_DESCRIPTION = RECORD
                             DEVICE_KIND: INTEGER;
                             DEVICE_ADDR: INTEGER;
                             UNIT: INTEGER;
                             SUBUNIT: INTEGER;
                             DEVICE: DEVICE_NAME
                          END;
TYPE FILE_NAME = PACKED_NAME;
TYPE FILE_ADDRESS = RECORD
                       FIRST_BYTE: LONG_INTEGER;
                       BYTE_COUNT: LONG_INTEGER;
                       TRANSFERRED_BYTES: LONG_INTEGER
                    END;
TYPE SECTOR_ADDRESS = RECORD
                         FIRST_SECTOR: LONG_INTEGER;
                         SECTOR_COUNT: LONG_INTEGER;
                         TRANSFERRED_SECTORS: LONG_INTEGER
                      END;
TYPE MODE = (INPUT_MODE, OUTPUT_MODE);
TYPE STREAM = INTEGER;
TYPE STREAM_POSITION = LONG_INTEGER;
TYPE BYTE = 0..255;
TYPE OPERATION_REFERENCE = INTEGER;
TYPE MEMORY_PARM = INTEGER;

TYPE BUFFER_LOCATION = (LOCAL, EXTERNAL);
TYPE BLEPTR = @BLE;
TYPE BLE = RECORD
              LINK: BLEPTR;
              CASE XL: BUFFER_LOCATION OF
                 LOCAL: (BUFADDR, BUFSIZE_IN_BYTES: INTEGER);
                 EXTERNAL: (MEMORY: MEMORY_PARM)
           END;

TYPE EVENT_TYPE = (SIGNAL, MESSAGE, ANSWER, SYSTEM_MESSAGE,
                   SYSTEM_ANSWER, PATH_MESSAGE, PATH_ANSWER,
                   INTERRUPT, TIME_OUT, PARENT_SIGNAL);

TYPE EVENT_MASK = INTEGER;

TYPE DATE_TIME_GROUP = RECORD
                          YEAR, MONTH, DAY: INTEGER;
                          HOUR, MIN, SEC: INTEGER
                       END;

TYPE PROC_TIME = ARRAY [0..2] OF INTEGER;

TYPE PROCESS_ATTRIBUTES = RECORD
                            ACCESS_RIGHTS, STATE: INTEGER;
                            ERROR_CODE, ERROR_LOC: INTEGER;
                            CONSUMED_TIME, CREATION_TIME: PROC_TIME
                         END;

TYPE CREATION_BLOCK = RECORD
                         VNAME: PROCESS_NAME;
                         VPROG, VINIT, VMICRO, VCAPAB: INTEGER;
                         VCPU, VPRIO, VLEVEL, VBASE: INTEGER;
                         VSIZE, VBOUND, VMEMORY, VMSGS: INTEGER;
                         VUSER: USERID
                      END;

TYPE CPUPARAMETER = (VCPUNMB, VINTERRUPTMASK, VSCHEDULERESETCOUNT,
                     VSLICESIZE, VELAPSEDTIME, VHWPRIORITY);

TYPE CHAR_TYPE = (TSPACE, TDIGIT, TLETTER, TOTHER);

CONST PAGELENGTH = 256;
TYPE PAGE = ARRAY [1..PAGELENGTH] OF INTEGER;

TYPE ELEMENT_TYPE = (TERROR, TINTEGER, TIDENTIFIER,
                     TSPECIAL, TLONG_INTEGER);

TYPE ELEM_REC = RECORD
                   DELIM: CHAR;
                   BYTE_COUNT: INTEGER;
                   CASE ELEM_TYPE: ELEMENT_TYPE OF
                      TINTEGER:      (INT: INTEGER);
                      TLONG_INTEGER: (LINT: LONG_INTEGER);
                      TIDENTIFIER:   (NAME: PACKED_NAME);
                      TSPECIAL:      (SPEC_CHAR: CHAR)
                END;

TYPE POINTER = @INTEGER;
TYPE PARAMTYPE = RECORD
                    FSN:      FILE_SYSTEM_NAME;  "CURRENT FILE SYSTEM NAME"
                    VOL:      VOLUME_NAME;       "CURRENT VOLUME NAME"
                    PFILE:    FILE;              "CURRENT PARAMETER FILE"
                    DFILE:    FILE;              "CURRENT DIRECTORY FILE"
                    IFILE:    FILE;              "CURRENT INPUT FILE"
                    OFILE:    FILE;              "CURRENT OUTPUT FILE"
                    PARENT:   PROCESS_NAME;      "PARENT OF PROCESS"
                    PTR:      POINTER
                 END;

CONST
   IO_OK                   =    0;     EOF                      = #201;
   NO_FDS_AVAILABLE        = #202;     ILLEGAL_FD               = #203;
   NO_IOCBS_AVAILABLE      = #204;     ILLEGAL_IOCB             = #205;
   NO_STREAMS_AVAILABLE    = #206;     ILLEGAL_STREAM           = #207;
   NO_XFELEMS_AVAILABLE    = #208;     ILLEGAL_ADDRESS          = #209;
   ILLEGAL_BLE             = #20A;     FILE_NOT_OPEN            = #20B;
   DIFFERENT_FILE_SYSTEMS  = #20C;     UNKNOWN_FILE_SYSTEM      = #20D;
   ILLEGAL_COMMAND         = #20E;     IO_SYSTEM_ERROR          = #20F;
   NOT_ENOUGH_SPACE        = #210;     ILLEGAL_MODE             = #211;
   ILLEGAL_MEMORY_PARM     = #212;     NO_BUFFER_SPACE          = #213;
   NOT_CONNECTED           = #214;     NOT_OUTPUT_MODE          = #215;
   NOT_INPUT_MODE          = #216;     ELEMENT_OVERFLOW         = #217;
   SYNTAX_ERROR            = #218;

   NONEXISTING_DEVICE      = #400;     ILLEGAL_DEVICE_KIND      = #401;
   ILLEGAL_CR80_ADDR       = #402;     DEVICE_NAME_IN_USE       = #403;
   ILLEGAL_UNIT            = #404;     ILLEGAL_SUBUNIT          = #405;
   WRONG_VOLUME_NAME       = #406;     NONEXISTING_VOLUME       = #407;
   VOLUME_MOUNTED          = #408;     DIFFERENT_VOLUMES        = #409;
   ILLEGAL_FILE            = #40A;     ILLEGAL_ORGANIZATION     = #40B;
   ILLEGAL_ALLOC_SIZE      = #40C;     ILLEGAL_AREA_SIZE        = #40D;
   ILLEGAL_RESET           = #40E;     ALLOC_TO_CONTIGUOUS_FILE = #40F;
   FILES_OPEN              = #410;     NO_FILE_TO_ACCEPT        = #411;
   NONEXISTING_USER        = #412;     USER_ALREADY_ACTIVE      = #413;
   NO_CONNECTION           = #414;     ILLEGAL_USER             = #415;
   ILLEGAL_CALLER          = #416;     OTHER_USERS              = #417;
   DISK_COMMAND            = #418;     OUT_OF_RANGE             = #419;
   DISK_DRIVER_FAILURE     = #41A;     FILE_FULL                = #41B;
   ACL_FULL                = #41C;     PROTECTION_FAILURE       = #41D;
   NO_ACCESS_RIGHTS        = #41E;     BFD_ERROR                = #41F;
   ILLEGAL_DIRECTORY       = #420;     NAME_EXISTS              = #421;
   NONEXISTING_NAME        = #422;     NOT_ALLOCATABLE          = #423;

CONST NAMELISTMAXINDEX = 10;
TYPE NAMELISTTYPE = ARRAY [1..NAMELISTMAXINDEX] OF PACKED_NAME;
«ff»
FUNCTION IAND(MASK1, MASK2: UNIV INTEGER): INTEGER;
FUNCTION IOR(MASK1, MASK2: UNIV INTEGER): INTEGER;
FUNCTION XOR(MASK1, MASK2: UNIV INTEGER): INTEGER;
FUNCTION INV(MASK: UNIV INTEGER): INTEGER;

FUNCTION LEFTSHIFT(BITS: UNIV INTEGER; SHIFTS: INTEGER): INTEGER;
FUNCTION RIGHTSHIFT(BITS: UNIV INTEGER; SHIFTS: INTEGER): INTEGER;

FUNCTION ADD(A, B: INTEGER): INTEGER;
FUNCTION SUBTRACT(A, B: INTEGER): INTEGER;

FUNCTION GETBITS(BITS: UNIV INTEGER; LEFTMOST: BITPOSITION;
                 FIELDLENGTH: BITFIELDLENGTH): INTEGER;
PROCEDURE PUTBITS(FROM: UNIV INTEGER; VAR TO_: UNIV INTEGER;
                  LEFTTO: BITPOSITION; FIELDLENGTH: BITFIELDLENGTH);
FUNCTION TESTBIT(BITS: UNIV INTEGER; BITNUMBER: BITPOSITION): BOOLEAN;
PROCEDURE SETBIT(VAR BITS: UNIV INTEGER; BITNUMBER: BITPOSITION);
PROCEDURE CLEARBIT(VAR BITS: UNIV INTEGER; BITNUMBER: BITPOSITION);

PROCEDURE SENSE_IO(DEVICE: INTEGER; VAR STATUS: UNIV INTEGER);
PROCEDURE READ_IO(DEVICE: INTEGER; VAR DATA: UNIV INTEGER);
PROCEDURE CONTROL_IO(DEVICE: INTEGER; STATUS: UNIV INTEGER);
PROCEDURE WRITE_IO(DEVICE: INTEGER; DATA: UNIV INTEGER);

PROCEDURE RESERVE_INTERRUPT(DEVPR: INTEGER; VAR INTRPT: INTEGER);
PROCEDURE RELEASE_INTERRUPT(INTRPT: INTEGER);
PROCEDURE CLEAR_INTERRUPT(INTRPT: INTEGER);
PROCEDURE WAIT_INTERRUPT(DELAY, INTRPT: INTEGER; VAR TIMED_OUT: BOOLEAN);
PROCEDURE SET_INTERRUPT(INTRPT: INTEGER);
PROCEDURE SET_CYCLE(CYCLE: INTEGER);

PROCEDURE SEND_MESSAGE(VAR RECEIVER: PROCESS_NAME;
                       MSG: UNIV MESSAGE_BUFFER;
                       VAR EVENT: INTEGER);
PROCEDURE SEND_SYSTEM_MESSAGE(VAR RECEIVER: PROCESS_NAME;
                              MSG: UNIV MESSAGE_BUFFER;
                              VAR EVENT: INTEGER);
PROCEDURE SEND_ANSWER(ANS: UNIV MESSAGE_BUFFER; EVENT: INTEGER);
PROCEDURE SEND_SYSTEM_ANSWER(ANS: UNIV MESSAGE_BUFFER; EVENT: INTEGER);
PROCEDURE SEND_SIGNAL(VAR RECEIVER: PROCESS_NAME);
PROCEDURE IDENTIFY_SENDER(EVENT: INTEGER; VAR PROC: INTEGER; VAR OK: BOOLEAN);

PROCEDURE GET_PROC_NAME(VAR PROC_NAME: PROCESS_NAME);
PROCEDURE GET_PROC_IDENT(VAR PROC_NAME: PROCESS_NAME; VAR FOUND: BOOLEAN);

PROCEDURE WAIT_MESSAGE(DELAY: INTEGER; VAR MSG: UNIV MESSAGE_BUFFER;
                       VAR EVENT: INTEGER; VAR EVTTYPE: EVENT_TYPE);
PROCEDURE WAIT_SYSTEM_MESSAGE(DELAY: INTEGER;
                              VAR MSG: UNIV MESSAGE_BUFFER;
                              VAR EVENT: INTEGER;
                              VAR EVTTYPE: EVENT_TYPE);
PROCEDURE WAIT_ANSWER(DELAY: INTEGER; EVENT: INTEGER;
                      VAR ANS: UNIV MESSAGE_BUFFER;
                      VAR EVTTYPE: EVENT_TYPE);
PROCEDURE WAIT_SYSTEM_ANSWER(DELAY: INTEGER; EVENT: INTEGER;
                             VAR ANS: UNIV MESSAGE_BUFFER;
                             VAR EVTTYPE: EVENT_TYPE);
PROCEDURE WAIT_EVENT(DELAY: INTEGER; EVTMSK: EVENT_MASK;
                     VAR MSG: UNIV MESSAGE_BUFFER;
                     VAR EVENT: INTEGER;
                     VAR EVTTYPE: EVENT_TYPE);
PROCEDURE SAVE_EVENT(EVENT: INTEGER);
PROCEDURE RESTORE_EVENTS(EVTTYPE: EVENT_TYPE);

PROCEDURE TERMINATE(CC: COMPLETION_CODE);

PROCEDURE READ_TIME(VAR TIME: DATE_TIME_GROUP);

PROCEDURE START_PROCESS(PROC: INTEGER; VAR ILLEGAL: BOOLEAN);
PROCEDURE STOP_PROCESS(PROC: INTEGER; VAR ILLEGAL: BOOLEAN);
PROCEDURE PROCESS_STATUS(PROC: INTEGER; VAR ILLEGAL: BOOLEAN;
                         VAR PROC_ATTR: PROCESS_ATTRIBUTES);
PROCEDURE REMOVE_PROCESS(PROC: INTEGER; VAR ILLEGAL: BOOLEAN);
PROCEDURE GET_NEXT_PROCESS(VAR PROC: INTEGER; VAR NONE: BOOLEAN);
PROCEDURE ADOPT_PROCESS(PROC: INTEGER; VAR ILLEGAL: BOOLEAN);
PROCEDURE CREATE_PROCESS(VAR CB: CREATION_BLOCK; VAR RESULT: INTEGER);
PROCEDURE GET_CPU_PARAMETER(CPU: INTEGER; PAR: CPUPARAMETER;
                     PRIORITY: INTEGER; VAR VAL: INTEGER;
                     VAR OK: BOOLEAN);
PROCEDURE SET_CPU_PARAMETER(CPU: INTEGER; PAR: CPUPARAMETER;
                     PRIORITY: INTEGER; VAL: INTEGER;
                     VAR OK: BOOLEAN);
PROCEDURE LOOKUP_CPU(VAR CPU_NAME: PROCESS_NAME; VAR FOUND: BOOLEAN);

PROCEDURE GET_BUFFER(WORD_CLAIM: INTEGER;
                     VAR MEMORY: MEMORY_PARM;
                     VAR ADDR: WORD_ADDRESS;
                     VAR WORDS_ALLOCATED: INTEGER;
                     VAR OK: BOOLEAN);
PROCEDURE GET_BUFFER_ADDR(MEMORY: MEMORY_PARM;
                          VAR ADDR: WORD_ADDRESS;
                          VAR SIZE_IN_WORDS: INTEGER;
                          VAR OK: BOOLEAN);
PROCEDURE RELEASE_BUFFER(MEMORY: MEMORY_PARM; VAR OK: BOOLEAN);

PROCEDURE CREATE(FSN: FILE_SYSTEM_NAME;
                 ATTRIBUTES: FILE_ATTRIBUTES;
                 VAR F: FILE;
                 VAR CC: COMPLETION_CODE);
PROCEDURE DISMANTLE(F: FILE; VAR CC: COMPLETION_CODE);
PROCEDURE PROTECT(F: FILE;
                  ACCESS: ACCESS_DESCRIPTION;
                  VAR CC: COMPLETION_CODE);
PROCEDURE RESET(F: FILE; VAR CC: COMPLETION_CODE);
PROCEDURE OFFER(F: FILE; USER: USERID; VAR CC: COMPLETION_CODE);
PROCEDURE ACCEPT(FSN: FILE_SYSTEM_NAME;
                 VAR F: FILE;
                 VAR CC: COMPLETION_CODE);
PROCEDURE GET_FILE_INFORMATION(F: FILE; INF_TYPE: FILE_INFORMATION_TYPE;
                               VAR INF: UNIV LONG_INTEGER;
                               VAR CC: COMPLETION_CODE);
PROCEDURE ASSIGN(FSN: FILE_SYSTEM_NAME;
                 DESCRIPTION: DEVICE_DESCRIPTION;
                 VAR CC: COMPLETION_CODE);
PROCEDURE DEASSIGN(FSN: FILE_SYSTEM_NAME;
                   DEVICE: DEVICE_NAME;
                   VAR CC: COMPLETION_CODE);
PROCEDURE MOUNT(FSN: FILE_SYSTEM_NAME;
                DEVICE: DEVICE_NAME;
                VOLUME: VOLUME_NAME;
                VAR CC: COMPLETION_CODE);
PROCEDURE DISMOUNT(FSN: FILE_SYSTEM_NAME;
                   VOLUME: VOLUME_NAME;
                   VAR CC: COMPLETION_CODE);
PROCEDURE FORMAT(FSN: FILE_SYSTEM_NAME;
                 DEVICE: DEVICE_NAME;
                 VAR SECTORADDR: SECTOR_ADDRESS;
                 BLE_POINTER: BLEPTR;
                 VAR CC: COMPLETION_CODE);
PROCEDURE GET_ROOT(FSN: FILE_SYSTEM_NAME;
                   VOLUME: VOLUME_NAME;
                   VAR ROOT_DIRECTORY: FILE;
                   VAR CC: COMPLETION_CODE);
PROCEDURE USER_ON(FSN: FILE_SYSTEM_NAME;
                  USER: USERID;
                  VAR CC: COMPLETION_CODE);
PROCEDURE USER_OFF(FSN: FILE_SYSTEM_NAME;
                   USER: USERID;
                   VAR CC: COMPLETION_CODE);
PROCEDURE ENTER(DIRECTORY: FILE;
                SUBJECT: FILE;
                NAME: FILE_NAME;
                VAR CC: COMPLETION_CODE);
PROCEDURE LOOKUP(DIRECTORY: FILE;
                 NAME: FILE_NAME;
                 VAR F: FILE;
                 VAR CC: COMPLETION_CODE);
PROCEDURE DESCENT(VAR F: FILE;
                  NAME: FILE_NAME;
                  VAR CC: COMPLETION_CODE);
PROCEDURE FIND_FILE(FROM_ADAM: BOOLEAN;
                    FSN: FILE_SYSTEM_NAME;
                    VOLUME: VOLUME_NAME;
                    NAMELIST: NAMELISTTYPE;
                    NAME_NO: INTEGER;
                    DIRECTORY: FILE;
                    VAR F: FILE;
                    VAR CC: COMPLETION_CODE);
PROCEDURE RENAME(DIRECTORY: FILE;
                 OLDNAME: FILE_NAME;
                 NEWNAME: FILE_NAME;
                 VAR CC: COMPLETION_CODE);
PROCEDURE REMOVE(DIRECTORY: FILE;
                 NAME: FILE_NAME;
                 VAR CC: COMPLETION_CODE);
PROCEDURE READ_SECTORS(FSN: FILE_SYSTEM_NAME;
                       DEVICE: DEVICE_NAME;
                       VAR SECTORADDR: SECTOR_ADDRESS;
                       BLE_POINTER: BLEPTR;
                       VAR CC: COMPLETION_CODE);
PROCEDURE WRITE_SECTORS(FSN: FILE_SYSTEM_NAME;
                        DEVICE: DEVICE_NAME;
                        VAR SECTORADDR: SECTOR_ADDRESS;
                        BLE_POINTER: BLEPTR;
                        VAR CC: COMPLETION_CODE);
PROCEDURE WRITE_AND_PROTECT(FSN: FILE_SYSTEM_NAME;
                            DEVICE: DEVICE_NAME;
                            VAR SECTORADDR: SECTOR_ADDRESS;
                            BLE_POINTER: BLEPTR;
                            VAR CC: COMPLETION_CODE);
PROCEDURE WRITE_AND_MARK(FSN: FILE_SYSTEM_NAME;
                         DEVICE: DEVICE_NAME;
                         VAR SECTORADDR: SECTOR_ADDRESS;
                         BLE_POINTER: BLEPTR;
                         VAR CC: COMPLETION_CODE);
PROCEDURE READ_BYTES(F: FILE;
                     VAR FILE_ADDR: FILE_ADDRESS;
                     BLE_POINTER: BLEPTR;
                     VAR CC: COMPLETION_CODE);
PROCEDURE MODIFY_BYTES(F: FILE;
                       VAR FILE_ADDR: FILE_ADDRESS;
                       BLE_POINTER: BLEPTR;
                       VAR CC: COMPLETION_CODE);
PROCEDURE APPEND_BYTES(F: FILE;
                       VAR FILE_ADDR: FILE_ADDRESS;
                       BLE_POINTER: BLEPTR;
                       VAR CC: COMPLETION_CODE);
PROCEDURE INIT_READ_BYTES(F: FILE;
                          VAR FILE_ADDR: FILE_ADDRESS;
                          BLE_POINTER: BLEPTR;
                          VAR OPREF: OPERATION_REFERENCE;
                          VAR CC: COMPLETION_CODE);
PROCEDURE INIT_MODIFY_BYTES(F: FILE;
                            VAR FILE_ADDR: FILE_ADDRESS;
                            BLE_POINTER: BLEPTR;
                            VAR OPREF: OPERATION_REFERENCE;
                            VAR CC: COMPLETION_CODE);
PROCEDURE INIT_APPEND_BYTES(F: FILE;
                            VAR FILE_ADDR: FILE_ADDRESS;
                            BLE_POINTER: BLEPTR;
                            VAR OPREF: OPERATION_REFERENCE;
                            VAR CC: COMPLETION_CODE);
PROCEDURE WAIT_OPERATION(OPREF: OPERATION_REFERENCE;
                         VAR CC: COMPLETION_CODE);
PROCEDURE TEST_OPERATION(OPREF: OPERATION_REFERENCE;
                         VAR FINISHED: BOOLEAN;
                         VAR CC: COMPLETION_CODE);
PROCEDURE CANCEL_OPERATION(OPREF: OPERATION_REFERENCE;
                           VAR CC: COMPLETION_CODE);

PROCEDURE CONNECT(F: FILE;
                  M: MODE;
                  VAR S: STREAM;
                  VAR CC: COMPLETION_CODE);
PROCEDURE DISCONNECT(S: STREAM;
                     VAR F: FILE;
                     VAR CC: COMPLETION_CODE);
PROCEDURE GET_POSITION(S: STREAM;
                       VAR POSITION: STREAM_POSITION;
                       VAR CC: COMPLETION_CODE);
PROCEDURE SET_POSITION(S: STREAM;
                       POSITION: STREAM_POSITION;
                       VAR CC: COMPLETION_CODE);
PROCEDURE INBYTE(S: STREAM; VAR B: UNIV BYTE; VAR CC: COMPLETION_CODE);
PROCEDURE INWORD(S: STREAM;
                 VAR WORD: UNIV INTEGER;
                 VAR CC: COMPLETION_CODE);
PROCEDURE BACKSPACE(S: STREAM; VAR CC: COMPLETION_CODE);
PROCEDURE INREC(S: STREAM;
                VAR FIRST_ELEMENT: UNIV ELEMENT;
                VAR RECORD_LENGTH_IN_BYTES: INTEGER;
                VAR CC: COMPLETION_CODE);
PROCEDURE OUTBYTE(S: STREAM; B: UNIV BYTE; VAR CC: COMPLETION_CODE);
PROCEDURE OUTWORD(S: STREAM;
                  WORD: UNIV INTEGER;
                  VAR CC: COMPLETION_CODE);
PROCEDURE OUTREC(S: STREAM;
                 FIRST_ELEMENT: UNIV ELEMENT;
                 VAR RECORD_LENGTH_IN_BYTES: INTEGER;
                 VAR CC: COMPLETION_CODE);
PROCEDURE FLUSH(S: STREAM; VAR CC: COMPLETION_CODE);
PROCEDURE INTYPE(S: STREAM;
                 VAR CH: CHAR;
                 VAR CH_TYPE: CHAR_TYPE;
                 VAR CC: COMPLETION_CODE);
PROCEDURE INELEMENT(S: STREAM;
                    VAR ELEM: ELEM_REC;
                    VAR CC: COMPLETION_CODE);
PROCEDURE ININTEGER(S: STREAM;
                    VAR INT: INTEGER;
                    VAR CC: COMPLETION_CODE);
PROCEDURE INLONG_INTEGER(S: STREAM;
                         VAR LINT: LONG_INTEGER;
                         VAR CC: COMPLETION_CODE);
PROCEDURE INNAME(S: STREAM;
                 VAR N: PACKED_NAME;
                 VAR CC: COMPLETION_CODE);
PROCEDURE INFILEID(S: STREAM;
                   VAR FROM_ADAM: BOOLEAN;
                   VAR FSN: FILE_SYSTEM_NAME;
                   VAR VOLUME: VOLUME_NAME;
                   VAR NAMELIST: NAMELISTTYPE;
                   VAR NAME_NO: INTEGER;
                   VAR CC: COMPLETION_CODE);
PROCEDURE OUTTEXT(S: STREAM;
                  UNPACKED_TEXT: TEXT;
                  VAR CC: COMPLETION_CODE);
PROCEDURE OUTSTRING(S: STREAM;
                    UNPACKED_TEXT: TEXT;
                    NO_OF_CHARS: INTEGER;
                    VAR CC: COMPLETION_CODE);
PROCEDURE OUTHEXA(S: STREAM;
                  INT: UNIV INTEGER;
                  PAD_CHAR: CHAR;
                  VAR CC: COMPLETION_CODE);
PROCEDURE OUTINTEGER(S: STREAM;
                     INT: UNIV INTEGER;
                     FORMAT: UNIV INTEGER;
                     VAR CC: COMPLETION_CODE);
PROCEDURE OUTLONG_INTEGER(S: STREAM;
                          LINT: UNIV LONG_INTEGER;
                          FORMAT: UNIV INTEGER;
                          VAR CC: COMPLETION_CODE);
PROCEDURE OUTNL(S: STREAM; VAR CC: COMPLETION_CODE);

PROCEDURE MARK(VAR TOP: INTEGER);
PROCEDURE RELEASE(TOP: INTEGER);
FUNCTION FREE_SPACE: INTEGER;
FUNCTION CONTENTS(BASE_REL_ADDR: LONG_INTEGER): INTEGER;
PROCEDURE EXIT;
PROCEDURE CURRENT_LEVEL(VAR LEVEL: INTEGER);
PROCEDURE LONG_EXIT(LEVEL: INTEGER);
FUNCTION CURRENT_LINE: INTEGER;
FUNCTION REL_ADDR(FIRST_ELEMENT: UNIV ELEMENT): INTEGER;
PROCEDURE GET_ABS_ADDR(FIRST_ELEMENT: UNIV ELEMENT;
                       VAR WORD_ADDR: WORD_ADDRESS);
PROCEDURE COPY(SOURCE, DEST: BYTE_ADDRESS; NO_OF_BYTES: INTEGER);
PROCEDURE PACK(FIRST_ELEMENT_OF_UNPACKED: UNIV ELEMENT;
               VAR FIRST_ELEMENT_OF_PACKED: UNIV ELEMENT;
               NO_OF_BYTES: INTEGER);
PROCEDURE UNPACK(FIRST_ELEMENT_OF_PACKED: UNIV ELEMENT;
                 VAR FIRST_ELEMENT_OF_UNPACKED: UNIV ELEMENT;
                 NO_OF_BYTES: INTEGER);
PROCEDURE PACK_SWAPPED(FIRST_ELEMENT_OF_UNPACKED: UNIV ELEMENT;
                       VAR FIRST_ELEMENT_OF_PACKED: UNIV ELEMENT;
                       NO_OF_BYTES: INTEGER);
PROCEDURE UNPACK_SWAPPED(FIRST_ELEMENT_OF_PACKED: UNIV ELEMENT;
                         VAR FIRST_ELEMENT_OF_UNPACKED: UNIV ELEMENT;
                         NO_OF_BYTES: INTEGER);
PROCEDURE RUN(F: FILE; VAR PARAM: PARAMTYPE;
              VAR LINE: INTEGER; VAR RESULT: PROGRESULT);
FUNCTION CREATE_LONG(LEAST, MOST: UNIV INTEGER): LONG_INTEGER;
PROCEDURE SPLIT_LONG(L: LONG_INTEGER; VAR LEAST, MOST: UNIV INTEGER);
PROCEDURE ASSIGNBITS(VALUE: UNIV BITVALUE; VAR P: UNIV PAGE;
                     FIRSTBIT, NO_OF_BITS: INTEGER);
PROCEDURE SKIPBITS(VALUE: UNIV BITVALUE; P: UNIV PAGE;
                   VAR FIRSTBIT: INTEGER; NO_OF_BITS: INTEGER;
                   VAR BITSSKIPPED: INTEGER);
PROCEDURE SET_TRACE(S: STREAM; MASK: INTEGER);
PROCEDURE PRINT_TRACE(ON: BOOLEAN);

PROGRAM MAIN(VAR PARAM: PARAMTYPE); «a5»