.ENABLE SUBSTITUTION
.ENABLE QUIET
.SETF FIRST
.SETS TEXT ""
.SETN ZERO 0
SET /NOREMOTE=TT4:
.SETS DSTR "JANFEBMARAPRMAYJUNJULAUGSEPOCTNOVDEC"
.DISABLE QUIET
ASN LB:=LB1:/GBL
ASN LB:=XX:/GBL
.7:
.ASKS TIM Enter date and time ( dd-mmm-yy hh:mm )
.IF <STRLEN> > ZERO .GOTO 77
SET /NOLOGON
;	ERROR- Date and time must be entered!
.GOTO 7
.77:
TIM 'TIM'
;
;	Be sure to log date and time in IPL logbook!
;
.SETS TIM "'<DATE>' '<TIME>'"
.;
.;	OPEN UP THE FILE CONTAINING THE DATE/TIME LAST BOOTED
.;
.OPENR #1 [1,2]BOOT.TIM;1
.READ  #1 BOOT
.CLOSE #1
.PARSE BOOT "-- ::" DAY MON YEAR HOUR MIN SEC
.PARSE TIM  "-- ::" DAY1 MON1 YEAR1 HOUR1 MIN1 SEC1
.IF YEAR = YEAR1 .GOTO 1
.;	NOTE!!! This code must be changed on January 1st !!!!!!!
;	ERROR- Year entered is incorrect!
.GOTO 7
.1:
.33:
.IF MON1 <> MON .GOTO 55
.IF DAY1 = DAY .GOTO 2
.IF DAY1 > DAY .GOTO 5
;	ERROR- Day entered is incorrect!
.GOTO 7
.55:
.SETN NMON 1.
.3:
.SETS TEMP DSTR[NMON:NMON+2.]
.IF TEMP = MON .GOTO 433
.SETN NMON NMON+3.
.GOTO 3
.433:
.SETN MMON 1.
.43:
.SETS TEMP DSTR[MMON:MMON+2.]
.IF TEMP = MON1 .GOTO 533
.SETN MMON MMON+3.
.GOTO 43
.533:
.SETN NMON NMON+3.
.IF MMON = NMON .GOTO 5
;	ERROR- Month entered is incorrect!
.GOTO 7
.2:
.SETT FIRST
;	The system has been booted earlier today at 'HOUR':'MIN'.
;	Enter the reason for re-booting the system at this time.
;	Terminate your response with <return>.
.ASKS TEXT ????
.IF <STRLEN> > 0 .GOTO 5
;	ERROR- You must enter the reason why the system was re-booted!
.GOTO 2
.5:
.;
.;	RECORD THE DATE/TIME BOOTED
.;
.OPEN [1,2]BOOT.TIM;1
.DATA 'TIM'
.CLOSE 
.ENABLE QUIET
SET /LIBUIC=[2,54]
ACS SY:/BLKS=1000.
RED TT0:=LP0:
SET /PUB=DP1:
MOU DP1:/OVR
.;
.;	SEE IF THE AUXILLARY SYSTEM DISK IS MOUNTED
.;	IF SO THEN ASSIGN THE GLOBAL SY1: TO IT
.;
.TESTFILE DP1:[204,204]SEGMENT.TST;1
ASN DP1:=SY1:/GBL
.IF <FILERR> = 1 .GOTO 123
.DISABLE QUIET
;
;	The auxillary system disk is not available!
;		SY1: will reside on DP0:
;
.ENABLE QUIET
DMO DP1:/DEV
SET /NOPUB=DP1:
ASN DP0:=SY1:/GBL
PIP [1,2]LOGIN.TXT;*/RM/NM
PIP [1,2]LOGIN.TXT/EN=[1,2]LOGIN.NSY
.GOTO 124
.123:
PIP [1,2]LOGIN.TXT;*/RM/NM
PIP [1,2]LOGIN.TXT/EN=[1,2]LOGIN.MSG
.124:
.;
.;	LOG WHEN SYSTEM WAS BOOTED
.;
.OPENA #1 LB:[1,2]BOOT.DAT
.DATA  #1 UP   '<DATE>' '<TIME>' 'TEXT'
.CLOSE #1
.;
@[1,2]ACCOUNT
SET /COLOG
RUN ERRLOG
.;DELAY 5S
@[1,2]BRO THE UNCLASSIFIED SYSTEM IS NOW IN OPERATION
SET /NOCOTERM
SET /LOGON
.IFT FIRST .GOTO END
.DISABLE QUIET
;
;	We will now run the accounting report program.
;	Respond with the date the last report was run.
;	Be sure to give the report to Karen so she can 
;	fill out the time card for the 11/70.
;
.ENABLE QUIET
.XQT RUN $TIMLOG
.END:
.ENABLE QUIET
ASN SY1:=ZZ:/GBL
SET /UIC=[3,24]
.;XQT @APL
BYE
