       .TITLE OTSER
/COPYRIGHT 1970, DIGITAL EQUIPMENT CORP., MAYNARD, MASS.
/EDIT 3   10-14-70
/OBJECT TIME ERROR ROUTINE.
/CALLING SEQUENCE--JMS* .ER
/                  .DSA ERROR NUMBER (BIT 0 = 1 IF RECOVERABLE).
	.GLOBL OTSER
OTSER=.
       .GLOBL .ER
.ER    CAL    0
       DAC    ACSAVE         /SAVE AC IN CASE ERROR RECOVERABLE.
       LAC*   .ER            /SAVE ERROR NUMBER AND CONVERT TO A TWO
       DAC    RECFLG         /   DIGIT ASCII-7 NUMBER.
       RAL
       AND    (16)
	DAC TEXT+3		/STORE DIGIT 2 IN BUFFER.
       LAC    RECFLG
       RCL; RTL; RTL
       AND    (3400)         /DIGIT 1 TO AC.
       XOR     TEXT+3        /MERGE DIGIT 2
       XOR    (30140)        /MERGE IN TWO 60'S.
       DAC    TEXT+3         /STORE ASCII-7 CHARACTERS IN BUFFER.
       LAC    SHORT
       DAC    TEXT2
       LAW    -12            /TEST FOR ERROR 12 (BAD FORMAT).
       TAD*   .ER            /   IF NOT, PRINT ERROR MESSAGE.
       SZA                   /   IF SO, LENGTHEN ERROR MESSAGE TO
       JMP    ER0            /   INCLUDE CURRENT FORMAT STATEMENT
       ISZ    .ER            /   WORD PAIR.
       XCT*   .ER
       DAC    FMT            /STORE FIRST FORMAT WORD IN BUFFER.
       ISZ    .ER
       XCT*   .ER
       DAC    FMT+1          /STORE SECOND FORMAT WORD IN BUFFER.
       LAC    LONG
       DAC    TEXT2
ER0	CAL 02775	/WRITE ERROR MESSAGE.--
       .DSA   11
       .DSA   TEXT-2
ACSAVE .DSA   0
	CAL 775
	6
ER2    LAC    RECFLG         /CHECK ERROR FOR RECOVERABLE.
       SPA
       JMP    ER1            /   YES--RETURN TO CALLER.
       CAL    00000          /   NO-- CALL .EXIT.
       .DSA   15
ER1	LAC .ER		/RESTORE LINK AND AC BEFORE EXIT.
       RAL
       LAC    ACSAVE
       ISZ    .ER
       JMP*   .ER            /EXIT TO CALLING ROUTINE.
TEXT   .ASCII  ' .OTS '<0><0>'00'
TEXT2  .DSA   0
       .DSA   0
FMT    .BLOCK 2
       .DSA    360320
SHORT  .DSA   064000
LONG   .DSA   360000
RECFLG	.DSA 0
       .END
