.MAIN. MACRO V05.01b Sunday 15-Dec-85 17:13 Table of contents 1- 2 TITLE 3- 1 USER DEFINED MACROS 4- 1 DEFINITIONS 6- 12 OFFSETS IN LBUF AND TTYBUF 7- 1 START: READ TIME1, READ DATE1 7- 27 OPEN DAYLOG.LOG, READ DAYLOG.LOG 8- 1 OPEN LOG FILE AND CHECK LINE TIME CLOCK 8- 7 IS THE LINE TIME CLOCK TURNED ON? 9- 1 SHOW LAST DAYLOG, ASK FOR PERSON'S NAME 11- 1 ENTER SYSTEM TIME 12- 1 ASK FOR DATE CHANGE 13- 1 ASK FOR THE DAY, or parse first substring. 14- 1 ASSEMBLE THE DATE CODE INTO RT-11 FORMAT 15- 63 -------------- SUBROUTINES ----------------- 16- 1 TTYBIN: TTY LINE BUFFER INPUT - SUBROUTINE 17- 1 TTYIN: TTY INPUT A CHARACTER - SUBROUTINE 18- 1 SEPCHR: SEPARATE CHARACTER STRINGS BY CLASS - SUBROUTINE 19- 1 TNSTR: PARSE TIME STRING NUMBERS - SUBROUTINE 20- 1 PARTIM: PARSE THE TIME STRING - SUBROUTINE 21- 1 ... PARSE TIME, ASK, "IS THIS PM?" - INTERNAL 22- 1 ... CONVERT TIME TO SECONDS PAST MIDNIGHT - INTERNAL 23- 2 ... CALCULATE TICKS FROM SECONDS PAST MIDNIGHT - INTERNAL 24- 1 MULTIM: MULTIPLY SINGLE X DOUBLE PRECISION - SUBROUTINE 25- 1 PARNOS: PARSE DATE NUMBER STRING - SUBROUTINE 26- 1 PARALP: PARSE DATE ALPHABETIC STRING - SUBROUTINE 27- 1 YESNO: SEPARATE A "YES", "NO", "" STRING - SUBROUTINE 29- 1 MOVEBY: MOVE BYTE STRING - SUBROUTINE 29- 12 OPENCHAN: OPEN DATA FILE CHANNEL - SUBROUTINE 30- 1 DATELD: LOAD ASCII DATE TO LOCATION - SUBROUTINE 32- 1 CLKLD: LOAD ASCII CLOCK INTO LOCATION - SUBROUTINE 33- 1 COMPLETION ROUTINES 34- 1 ERROR MESSAGES AND ERROR EXIT 35- 1 MESSAGES FOR QUESTION AND FOR ERRORS 37- 1 SYSTEM COMMUNICATION BLOCKS 37- 17 LOG BUFFER LOCATIONS DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 1 1 ;*TITLE* 14-DEC-85 - DAYLOG.MAC - Time and date processor 2 .SBTTL TITLE 3 ; 4 ; DAYLOG.MAC FOR RT-11 V05.00 5 ; 6 ; Edit History: 7 ; 8 ; 001 26-Oct-82 10:42 Sallee,Gary (19912) 9 ; Creation; (01.00) 10 ; 002 28-Dec-84 10:42 Sallee,Gary (19912) 11 ; Decrease size (02.00) 12 ; 003 15-Dec-85 10:42 Sallee,Gary (19912) 13 ; Change prompts (03.00) 14 ; DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 2 TITLE 1 .TITLE DAYLOG GARY F. SALLEE VERSION 3 2 .IDENT /X03.00/ 3 .MCALL .LOOKUP,.EXIT,.PRINT,.SETTOP 4 .MCALL .CLOSE,.WRITW,.READW,.DSTAT 5 .MCALL .GTIM,.DATE,.SDTTM,.TTINR,.TTYIN DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 3 USER DEFINED MACROS 1 .SBTTL USER DEFINED MACROS 2 .ENABLE LC ;Enable lower case 3 .ENABLE LSB 4 ;.LIST MEB ;List macro expansions which create binary code 5 6 .MACRO PERROR ADDR,GOTO ;Print error message 7 .PRINT #MERROR 8 MLR0BR ADDR,GOTO 9 .ENDM 10 11 .MACRO MLR0BR ADDR,GOTO ;Load R0 then branch ... for PRINT. 12 .IF NB 13 .IF DIF ,R0 14 MOV ADDR,%0 15 .ENDC 16 .ENDC 17 .IF NB 18 BR 19 .ENDC 20 .ENDM 21 22 .MACRO PERROJ ADDR,GOTO ;PRINT error, jump to exit print 23 .PRINT #MERROR 24 MLR0JM ADDR,GOTO 25 .ENDM 26 27 .MACRO MLR0JM ADDR,GOTO ;Load R0 then jump ... for PRINT. 28 .IF NB 29 .IF DIF ,R0 30 MOV ADDR,%0 31 .ENDC 32 .ENDC 33 .IF NB 34 JMP 35 .ENDC 36 .ENDM DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 4 DEFINITIONS 1 .SBTTL DEFINITIONS 2 000000 AC0=%0 3 000001 AC1=%1 4 000002 AC2=%2 5 000003 AC3=%3 6 000004 AC4=%4 7 000005 AC5=%5 8 000006 AC6=%6 9 000007 AC7=%7 10 000000 R0=%0 11 000001 R1=%1 12 000002 R2=%2 13 000003 R3=%3 14 000004 R4=%4 15 000005 R5=%5 16 000006 R6=%6 17 000006 SP=%6 18 000007 R7=%7 19 000007 PC=%7 DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 5 DEFINITIONS 1 000000 .ASECT 2 000044 .=44 3 000044 040000 .WORD 40000 ;Allow lower case keyboard input 4 001000 .=1000 5 000000 .PSECT 6 .GLOBL STACK 7 001000 STACK=1000 8 ; ASCII characters 9 000010 CTRLH=10 10 000011 HT=11 ;Horizontal Tab 11 000012 LF=12 ;Line Feed 12 000014 FF=14 ;Form Feed 13 000015 CR=15 ;Carraige Return 14 000040 SPACE=40 15 000072 COLON=72 16 000056 PERIOD=56 17 000100 ATSIGN=100 18 ; Octal number constants 19 177777 MINUS1=-1 20 000000 NULL=0 21 000037 N037=37 22 000060 N060=60 23 000072 N072=72 24 000074 N074=74 25 ; Decimal number constants 26 27 000003 NMBR03=3. ;Constant for character conversion and other things 28 000005 NMBR05=5. 29 000006 NMBR06=6. 30 000062 CLCK50=50. ;Constant for 50 hz line time clock 31 000074 CLCK60=60. ;Constant for 60 hz line time clock 32 000110 YEAR72=72. ;Offset for year carried in the RMON is 1972 DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 6 DEFINITIONS 1 000052 EMTERB=52 ;Location of EMT error byte in program root 2 000054 RMONAP=54 ;Location of pointer to start of RMON 3 000400 LBYTE=400 ;Multiplication factor for shift to left byte of word 4 000300 CONFIG=300 ;Configuration word offset inside RMON 5 000372 SYSGEN=372 ;Sysgen option word offset inside RMON 6 ; Channel names 7 000001 CHAN01=1 ;B write channel number 8 000002 CHAN02=2 ;B read channel number 9 ; Bit positions 10 000002 BIT01=2 11 000040 CLK50$=40 12 .SBTTL OFFSETS IN LBUF AND TTYBUF 13 000100 LRECL= 64. ;Log record record length 14 000000 LRECN= 0 ;Log record record number position 15 000006 LDATE= 6 ;Log record date position 16 000020 LTIME= 20 ;Log record time of log on position 17 000031 LFNAM= 31 ;Log record first name position 18 000053 LMI= 53 ;Log record middle initial position 19 000055 LLNAM= 55 ;Log record last name position 20 000076 LCR= 76 ;Log record carraige return position 21 22 000000 MONTHC= 0 ;Month code position 23 000002 DAYC= 2 ;Day code position 24 000004 YEARC= 4 ;Year code position 25 000006 STROFF= 6 ;String offset 26 DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 7 START: READ TIME1, READ DATE1 1 .SBTTL START: READ TIME1, READ DATE1 2 .ENABLE LSB 3 000000 START: 4 000000 .SETTOP # 5 000006 020027 012450' CMP R0,# 6 000012 103002 BHIS 10$ 7 000014 000167 005700 JMP NEMERR 8 9 000020 012701 010750' 10$: MOV #MAREA,R1 10 000024 012702 011420' MOV #LBUF,R2 11 000030 062702 001002 ADD #1002,R2 12 000034 160102 SUB R1,R2 13 000036 005021 20$: CLR (R1)+ 14 000040 005302 DEC R2 15 000042 001375 BNE 20$ 16 17 000044 013700 000054 MOV @#RMONAP,R0 ;Find start address of RMON 18 000050 062700 000300 ADD #CONFIG,R0 ;Find address of CONFIG word 19 000054 005710 TST (R0) ;Do we have a system clock? 20 000056 100021 BPL 40$ ;No, so branch around the clock set up 21 000060 112767 000074 005302 MOVB #CLCK60,CLCKHZ ;Set clock flag to 60. for 60.hz 22 000066 032710 000040 BIT #CLK50$,(R0) ;Is this a 50 hz line clock? 23 000072 001403 BEQ 30$ ;No, so branch 24 000074 162767 000012 005266 SUB #,CLCKHZ ;Yes, set clock to 50. hz 25 000102 30$: .GTIM #MAREA,#CTICK2 ;Get clock ticks since midnight 26 000122 40$: 27 .SBTTL OPEN DAYLOG.LOG, READ DAYLOG.LOG 28 29 000122 012704 010710' MOV #LDBLK,R4 ;Set up DAYLOG.LOG file name 30 000126 012767 010732' 010630 MOV #MBUF2,DEVPTR ;Set up location for ASCII input device name 31 000134 004567 004672 JSR R5,OPENCHAN ;Jump to lookup file named in (R4) for input 32 000140 000002 .WORD CHAN02 ;Channel argument for OPENCHAN above 33 000142 103002 BCC FILTRN ;If no error on open, branch to file transfer 34 ;Entry ;File close 35 000144 000167 005562 JMP SCCEXIT ;Close the output file 36 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 8 OPEN LOG FILE AND CHECK LINE TIME CLOCK 1 .SBTTL OPEN LOG FILE AND CHECK LINE TIME CLOCK 2 .ENABLE LSB 3 000150 FILTRN: ;Entry ;File transfer 4 000150 005067 010606 CLR LRBLK ;Reset the .LOG read block number 5 000154 004767 005320 JSR PC,TRANSFER ;Subroutine to transfer the file 6 7 .SBTTL IS THE LINE TIME CLOCK TURNED ON? 8 000160 005767 005204 TST CLCKHZ ;Is there an LTC in the system? 9 000164 001451 BEQ 40$ ;No, so don't check it 10 000166 005000 CLR R0 ;Delay before reading clock again 11 000170 005300 10$: DEC R0 12 000172 001376 BNE 10$ 13 14 000174 .GTIM #MAREA,#CTICK1 ;Compare LTC before/after disk access 15 16 000214 026767 010550 010552 CMP CTICK1,CTICK2 ;Is the LTC turned on? 17 000222 001032 BNE 40$ ;Yes 18 000224 026767 010542 010544 CMP , ;Maybe 19 000232 001026 BNE 40$ ;Yes 20 000234 .PRINT #MWCNR ;"LTC not running" 21 ;"Please turn on the LTC switch:" 22 ; Loop to wait for either 1) increment in LTC or 2) any keyboard input. 23 000242 20$: .GTIM #MAREA,#CTICK1 ;Get another clock reading 24 000262 026767 010502 010504 CMP CTICK1,CTICK2 ;Is the LTC turned on? 25 000270 001004 BNE 30$ ;Yes 26 000272 026767 010474 010476 CMP , ;Maybe 27 000300 001760 BEQ 20$ ;No, go back to try it again 28 29 000302 30$: .PRINT #MITY ;"Thank you" 30 000310 40$: 31 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 9 SHOW LAST DAYLOG, ASK FOR PERSON'S NAME 1 .SBTTL SHOW LAST DAYLOG, ASK FOR PERSON'S NAME 2 .ENABLE LSB 3 ; If computer was just turned, on then put log file time into system 4 000310 005767 010454 TST CTICK1 ;Is time less than 5min past midnight 5 000314 001025 BNE 10$ ;No 6 000316 026727 010450 043120 CMP ,#18000. 7 000324 101021 BHI 10$ ;No 8 9 000326 012703 000010 MOV #8.,R3 ;Set up number of bytes to move 10 000332 012702 011220' MOV #TTYBUF,R2 ;Set up destination 11 000336 012701 011440' MOV #,R1 ;Set up source 12 000342 004767 004454 JSR PC,MOVEBY ;Move log date into TTYBUF 13 14 000346 112722 000101 MOVB #'A,(R2)+ ;Tell it "AM" so it won't ask for "PM" 15 000352 105012 CLRB (R2) ;Put a null at the end of the string 16 000354 012702 011220' MOV #TTYBUF,R2 ;Set up input string location 17 000360 004067 002304 JSR R0,PARTIM ;Parse time and load system 18 000364 000240 NOP ;Error exit 19 000366 000240 NOP ;Normal exit 20 21 000370 012701 011440' 10$: MOV #,R1 ;Move log file time into message 22 000374 012702 006665' MOV #,R2 23 000400 012703 000005 MOV #5.,R3 24 000404 004767 004412 JSR PC,MOVEBY 25 000410 012701 011426' MOV #,R1 ;Move log file date into message 26 000414 012702 006676' MOV #MIDAT,R2 27 000420 012703 000011 MOV #9.,R3 28 000424 004767 004372 JSR PC,MOVEBY 29 000430 012701 011451' MOV #,R1 ;Move log file name into message 30 000434 012702 006713' MOV #MINAM,R2 31 000440 012703 000045 MOV #37.,R3 32 000444 004767 004352 JSR PC,MOVEBY 33 34 000450 .PRINT #MILLW ;"The last DAYLOG was ..." DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 10 SHOW LAST DAYLOG, ASK FOR PERSON'S NAME 1 .ENABLE LSB 2 3 ; Start and Restart of question processing 4 000456 AGAIN: .PRINT #MIAYA ;"Are you a different person?" 5 000464 012701 000045 10$: MOV #37.,R1 6 7 000470 004067 004170 JSR R0,YESNO 8 000474 000423 BR 40$ ;"NO" exit 9 000476 000411 BR 30$ ;"YES" exit 10 ;"" exit 11 000500 012703 000045 20$: MOV #37.,R3 ;Set up 37 char for move 12 000504 012702 011451' MOV #,R2 ;Set up destination for move 13 000510 012701 011220' MOV #TTYBUF,R1 ;Set up source for move 14 000514 004767 004302 JSR PC,MOVEBY ;Move byte string into log record 15 000520 000411 BR 40$ 16 17 000522 30$: .PRINT #MIWIY ;"What is your name?:" 18 000530 012701 000045 MOV #37.,R1 ;Input 37. characters 19 000534 012702 011451' MOV #,R2 ;Put characters into log name 20 000540 004767 001432 JSR PC,TTYBIN 21 22 000544 012701 011451' 40$: MOV #,R1 ;Move log file name into message 23 000550 012702 007365' MOV #MIFMN,R2 24 000554 012703 000045 MOV #37.,R3 25 000560 004767 004236 JSR PC,MOVEBY 26 000564 .PRINT #MITFN 27 ;Let's see if name is shorter than 3 characters. 28 000572 012701 177777 MOV #-1,R1 29 000576 005201 50$: INC R1 30 000600 020127 000003 CMP R1,#3 ;Checked 3 characters? 31 000604 103024 BHIS 60$ ;Yes, continue with time 32 000606 122761 000000 011451' CMPB #NULL,(R1) ;Is this the null at the end string? 33 000614 001370 BNE 50$ ;No, this is a valid character. 34 35 000616 .PRINT #MITAS ;"That's a short name, want change?" 36 000624 .PRINT #MIYUL 37 000632 .PRINT #MIIT 38 000640 012701 000045 MOV #37.,R1 39 000644 004067 004014 JSR R0,YESNO ;Input and check for yes-no-other 40 000650 000402 BR 60$ ;No 41 000652 000723 BR 30$ ;Yes 42 000654 000711 BR 20$ ;Other 43 44 000656 60$: DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 11 ENTER SYSTEM TIME 1 .SBTTL ENTER SYSTEM TIME 2 .ENABLE LSB 3 000656 PTT: .GTIM #MAREA,#CTICK1 ;Get a new version of the system time 4 000676 012701 007072' MOV #MISTC,R1 ;Output location for ASCII 5 000702 012702 010770' MOV #CTICK1,R2 ;Clock ticks since midnight 6 000706 004767 004446 JSR PC,CLCKLD ;Convert time to 00:00:00 ASCII format 7 000712 012701 007072' MOV #MISTC,R1 ;The from location 8 000716 012702 011440' MOV #,R2 ;The to location 9 000722 012703 000010 MOV #8.,R3 ;Number of characters 10 000726 004767 004070 JSR PC,MOVEBY ;Move time into message 11 12 000732 005027 007106' CLR # 13 000736 .PRINT #MITST ;"The system time is ... change it?" 14 000744 .PRINT #MIYUL 15 000752 .PRINT #MIIT 16 17 000760 012701 000015 MOV #13.,R1 ;Set up 13 character field length 18 000764 004067 003674 JSR R0,YESNO ;Get response into TTYBUF 19 000770 000411 BR 10$ ;No 20 000772 000414 BR 20$ ;Yes 21 ;Other ... 22 000774 122767 000060 010216 CMPB #'0,TTYBUF ;Is the first character a numeric? 23 001002 101004 BHI 10$ ;No 24 001004 122767 000071 010206 CMPB #'9,TTYBUF ;Is the first character a numeric? 25 001012 103020 BHIS 30$ ;Yes, assume that this is the time 26 001014 004767 002550 10$: JSR PC,LOGTIM ;Leave the time as is and log it 27 001020 000167 000042 JMP ASKDA ;Go to ask for date 28 29 001024 20$: .PRINT #MTELL 30 001032 .PRINT #MIPTT ;"Please tell me the time:" 31 001040 012701 000015 MOV #13.,R1 ;Set up 13. character field length 32 001044 012702 011220' MOV #TTYBUF,R2 ;Set up buffer location 33 001050 004767 001122 JSR PC,TTYBIN ;Input 13 character time string 34 001054 30$: 35 001054 012702 011220' MOV #TTYBUF,R2 ;Set up input string location 36 001060 004067 001604 JSR R0,PARTIM ;Parse the time string 37 001064 000674 BR PTT ;Error exit 38 ;NOP DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 12 ASK FOR DATE CHANGE 1 .SBTTL ASK FOR DATE CHANGE 2 .ENABLE LSB 3 4 001066 ASKDA: 5 001066 012700 000100 MOV #100,R0 ;Index for clear loop 6 001072 012701 011020' MOV #DATBUF,R1 ;Location of date array buffer 7 001076 005021 10$: CLR (R1)+ ;Clear the buffer 8 001100 005300 DEC R0 9 001102 001375 BNE 10$ ;Loop to clear the buffer 10 11 001104 .DATE 12 001112 010067 007650 MOV R0,CDATE1 13 001116 003404 BLE 20$ 14 001120 012701 011426' MOV #,R1 15 001124 004767 004044 JSR PC,DATELD 16 17 001130 012701 011426' 20$: MOV #,R1 ;Move log date into message 18 001134 012702 007217' MOV #,R2 19 001140 012703 000011 MOV #9.,R3 ;Set up number of characters 20 001144 004767 003652 JSR PC,MOVEBY 21 22 001150 012701 011426' MOV #,R1 ;Move log day into prompt 23 001154 012702 007300' MOV #,R2 24 001160 012703 000002 MOV #2.,R3 ;Set up number of characters 25 001164 004767 003632 JSR PC,MOVEBY 26 27 001170 012701 011430' MOV #,R1 ;Move log month into prompt 28 001174 012702 007317' MOV #,R2 29 001200 012703 000005 MOV #5.,R3 ;Set up number of characters 30 001204 004767 003612 JSR PC,MOVEBY 31 32 001210 012701 011435' MOV #,R1 ;Move log year into prompt 33 001214 012702 007340' MOV #,R2 34 001220 012703 000002 MOV #2.,R3 ;Set up number of characters 35 001224 004767 003572 JSR PC,MOVEBY 36 37 001230 30$: .PRINT #MWCPD ;"Change the date?" 38 001236 .PRINT #MIYUL 39 001244 .PRINT #MIIT 40 001252 012701 000024 MOV #20.,R1 41 42 001256 005005 CLR R5 ;Clear index into BTABLE 43 001260 004067 003400 JSR R0,YESNO ;Ask for (Y/N) 44 001264 000404 BR 40$ ;"NO" exit 45 001266 000412 BR DA1ASK ;"YES" exit 46 001270 012702 011220' MOV #TTYBUF,R2 ;"" exit. Set up buffer loc 47 001274 000443 BR DA1SEP ;Go parse the string 48 49 001276 005767 007464 40$: TST CDATE1 ;Is there a valid date? 50 001302 003402 BLE 50$ ;No, use the log date 51 001304 000167 000442 JMP LOGDAT ;Yes, leave date as is and log it 52 001310 000167 000214 50$: JMP DATE4Y 53 54 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 13 ASK FOR THE DAY, or parse first substring. 1 .SBTTL ASK FOR THE DAY, or parse first substring. 2 .ENABLE LSB 3 001314 DA1ASK: 4 001314 005775 010562' 10$: TST @BTABL0+00(R5) ;Is must-be day OK? 5 001320 001413 BEQ 40$ ;No, go ask for day 6 001322 20$: 7 001322 005705 TST R5 ;Is this the DAY cycle? 8 001324 001027 BNE DA1SEP ;No 9 001326 062705 000012 ADD #,R5 ;Yes, so now do month or year 10 001332 000424 BR DA1SEP ;Go check for more input string 11 001334 30$: .PRINT #MFNR 12 001342 .PRINT BTABL0+06(R5) ;"I cannot recognize that funny day." 13 14 001350 40$: .PRINT #MTELL 15 001356 .PRINT BTABL0+10(R5) ;"Please tell me the day " 16 001364 012701 000031 MOV #25.,R1 ;Maximum character count 17 001370 012702 011220' MOV #TTYBUF,R2 ;Buffer location 18 001374 004767 000576 JSR PC,TTYBIN 19 001400 012702 011220' MOV #TTYBUF,R2 20 001404 005003 DA1SEP: CLR R3 21 001406 004067 000732 JSR R0,SEPCHR 22 001412 000433 BR 80$ ;Found null string, go to month 23 24 001414 020327 000002 CMP R3,#2 ;Is the string numeric? 25 001420 001412 BEQ 60$ ;Yes 26 001422 020327 000004 CMP R3,#4 ;Is the string alpha? 27 001426 103001 BHIS 50$ ;Yes 28 001430 000765 BR DA1SEP ;Ignore separation characters 29 30 ; First alphabetical string 31 001432 016503 010564' 50$: MOV BTABL0+2(R5),R3 ;Point to the first output string. 32 001436 004067 003042 JSR R0,PARALP ;Parse first alphabetic string 33 001442 000734 BR 30$ 34 001444 000405 BR 70$ 35 36 ; First numeric string 37 001446 016503 010564' 60$: MOV BTABL0+2(R5),R3 ;Point to the first output string. 38 001452 004067 002314 JSR R0,PARNOS ;Parse first number string 39 001456 000726 BR 30$ 40 41 001460 017500 010562' 70$: MOV @BTABL0+00(R5),R0 ;Is the must-be day ok? 42 001464 001316 BNE 20$ ;Yes, go print "Thank you ..." 43 001466 017500 010566' MOV @BTABL0+4(R5),R0 ;is the maybe day ok? 44 001472 001744 BEQ DA1SEP ;No, go ask again 45 001474 010075 010562' MOV R0,@BTABL0+0(R5) ;Load the must-be day 46 001500 000710 BR 20$ 47 48 001502 020227 011220' 80$: CMP R2,#TTYBUF ;Was this response a null? 49 001506 001403 BEQ 90$ ;Yes 50 001510 005775 010562' TST @BTABL0+0(R5) ;Is the must-be day ok? 51 001514 001715 BEQ 40$ ;No 52 001516 062705 000012 90$: ADD #,R5 ;Increment position in BTABLE 53 001522 020527 000024 CMP R5,#<2*> ;Is the year finished 54 001526 101672 BLOS DA1ASK ;No, go ask again 55 56 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 14 ASSEMBLE THE DATE CODE INTO RT-11 FORMAT 1 .SBTTL ASSEMBLE THE DATE CODE INTO RT-11 FORMAT 2 ; ASSEMBLE THE YEAR IN RT-11 FORMAT 3 .ENABLE LSB 4 001530 DATE4Y: 5 001530 .DATE ;Get the system date 6 001536 010067 007224 MOV R0,CDATE1 7 001542 012705 000036 MOV #,R5 8 001546 005775 010564' DATE4: TST @BTABL0+2(R5) ;Is the year (month, day) set? 9 001552 001045 BNE 30$ ;Yes, go check the month ..day 10 001554 016700 007206 MOV CDATE1,R0 ;Is the system date set? 11 001560 046500 010566' BIC BTABL0+4(R5),R0 ;Is year (month, day) code zero? 12 001564 001406 BEQ 10$ ;No 13 001566 020065 010570' CMP R0,BTABL0+6(R5) ;Is year (month, day) code too big? 14 001572 101003 BHI 10$ ;No 15 16 001574 010075 010564' MOV R0,@BTABL0+2(R5) ;Set the year ..month ..day 17 18 001600 000432 BR 30$ ;Go get the month .. day 19 001602 10$: ;Let's get the log year ..month ..day 20 001602 016501 010572' MOV BTABL0+10(R5),R1 ;Field length 21 22 001606 020527 000102 CMP R5,# ;Is this the DAY cycle? 23 001612 001006 BNE 20$ ;No, don't check the digits 24 001614 126727 007606 000040 CMPB ,# ;Is the DAY only one digit? 25 001622 001002 BNE 20$ ;No 26 001624 012701 000001 MOV #1,R1 ;Yes, set field length to one 27 001630 016502 010574' 20$: MOV BTABL0+12(R5),R2 ;Field location 28 001634 016503 010576' MOV BTABL0+14(R5),R3 ;Output string location 29 001640 004075 010600' JSR R0,@BTABL0+16(R5) ;PARNOS or PARALP 30 001644 000414 BR 40$ 31 32 001646 020527 000102 CMP R5,# ;Is this the DAY cycle? 33 001652 001005 BNE 30$ ;No, don't check the 4th day level 34 001654 016700 007172 MOV +DAYC>>,R0 35 001660 001402 BEQ 30$ ;There is no valid day 36 001662 010067 007156 MOV R0,+DAYC>> 37 38 001666 062705 000022 30$: ADD #,R5 ;Increment position in BTABLE 39 001672 000175 010562' JMP @BTABL0+0(R5) ;Normal exit 40 001676 000175 010602' 40$: JMP @BTABL0+20(R5) ;Error exit 41 .EVEN DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 15 ASSEMBLE THE DATE CODE INTO RT-11 FORMAT 1 ; ASSEMBLE ENTIRE RT-11 DATE CODE 2 .ENABLE LSB 3 ; Assemble full code, set the system date 4 001702 012700 011042' DATE4A: MOV #>,R0 5 6 001706 012700 011042' MOV #>,R0 7 001712 012005 MOV (R0)+,R5 8 001714 062005 ADD (R0)+,R5 9 001716 062005 ADD (R0)+,R5 10 001720 010567 007042 MOV R5,CDATE1 11 12 001724 012767 177777 007036 MOV #<-1>,CTICK1 13 001732 .SDTTM #MAREA,#CDATE1 ;Set the system date 14 15 001752 LOGDAT: .DATE ;Move the date into the log 16 001760 005700 TST R0 17 001762 003404 BLE 10$ ;No valid date code 18 001764 012701 011426' MOV #,R1 19 001770 004767 003200 JSR PC,DATELD 20 001774 10$: 21 22 ;Entry ;File end 23 001774 004767 003576 JSR PC,SAVELOG ;Write the log file 24 25 002000 012701 011440' MOV #,R1 ;Move log file time into message 26 002004 012702 006665' MOV #,R2 27 002010 012703 000005 MOV #5.,R3 28 002014 004767 003002 JSR PC,MOVEBY 29 002020 012701 011426' MOV #,R1 ;Move log file date into message 30 002024 012702 006676' MOV #MIDAT,R2 31 002030 012703 000011 MOV #9.,R3 32 002034 004767 002762 JSR PC,MOVEBY 33 002040 012701 011451' MOV #,R1 ;Move log file name into message 34 002044 012702 006713' MOV #MINAM,R2 35 002050 012703 000045 MOV #37.,R3 36 002054 004767 002742 JSR PC,MOVEBY 37 002060 20$: .PRINT #MITLI ;"This DAYLOG is ..." 38 002066 .PRINT #MITIM 39 40 002074 .PRINT #MITIA ;"Change anything?" 41 002102 .PRINT #MIYUL ;"Change anything?" 42 002110 .PRINT #MIANY ;"Change anything?" 43 002116 012701 000045 MOV #37.,R1 44 45 002122 004067 002536 JSR R0,YESNO 46 002126 000415 BR 40$ ;"NO" exit 47 002130 000420 BR 50$ ;"YES" exit 48 ;"" exit 49 002132 126727 007062 000126 CMPB TTYBUF,#'V ;Asking for version number? 50 002140 001004 BNE 30$ ;No 51 002142 .PRINT #MILVN ;Print the version number 52 002150 000743 BR 20$ 53 002152 30$: 54 002152 .PRINT #MIDNU ;"Sorry, I don't understand that." 55 002160 000737 BR 20$ 56 57 002162 40$: .CLOSE #CHAN02 ;Close the read channel DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 15-1 ASSEMBLE THE DATE CODE INTO RT-11 FORMAT 58 002170 .EXIT ;Normal program exit 59 60 002172 000167 176260 50$: JMP AGAIN ;Go back to begining, almost 61 62 .DSABLE LSB 63 .SBTTL -------------- SUBROUTINES ----------------- DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 16 TTYBIN: TTY LINE BUFFER INPUT - SUBROUTINE 1 .SBTTL TTYBIN: TTY LINE BUFFER INPUT - SUBROUTINE 2 .ENABLE LSB 3 002176 TTYBIN: 4 ; PURPOSE Input line of characters from console, TTY, to memory 5 6 ; R1 is input byte count 7 ; R2 is input bottom buffer location 8 ; R2 is output last, top, character location 9 ; R3 is output bottom buffer location 10 ; Note that routine uses # bytes in buffer location. 11 12 002176 010046 MOV R0,-(SP) 13 002200 010127 MOV R1,(PC)+ ;Save byte count 14 002202 000000 TTYCNT: .WORD 0 15 002204 010203 MOV R2,R3 ;Save bottom of buffer 16 002206 005201 INC R1 17 002210 005022 10$: CLR (R2)+ ;Fill buffer with nulls 18 002212 005301 DEC R1 ;Fill one byte beyond buffer 19 002214 002375 BGE 10$ ;Loop 20 21 002216 016701 177760 MOV TTYCNT,R1 ;Get byte count 22 002222 010302 MOV R3,R2 ;Get bottom of buffer 23 002224 004067 000006 20$: JSR R0,TTYIN ;Get line into buffer 24 002230 000775 BR 20$ ;Loop 25 26 002232 012600 MOV (SP)+,R0 27 002234 000207 RTS PC 28 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 17 TTYIN: TTY INPUT A CHARACTER - SUBROUTINE 1 .SBTTL TTYIN: TTY INPUT A CHARACTER - SUBROUTINE 2 .ENABLE LSB 3 002236 TTYIN: 4 5 ; PURPOSE Input character from console to memory. 6 ; Truncate to field length. Clear ring buffer. 7 ; Remove leading spaces, multiple spaces, CR's, FF's, LF's, HT's 8 9 ; R0 is return location 10 ; R1 is input max no of characters, decremented 11 ; R2 is input next output character position, incremented 12 ; R2 is output next output character position 13 ; R3 is input bottom output of buffer 14 ; Exit+0 is normal return 15 ; Exit+2 is null character return 16 17 002236 010046 MOV R0,-(SP) ;Save return location 18 002240 10$: .TTYIN ;Wait for a line of input, get a character 19 002244 142700 000200 BICB #200,R0 ;Remove parity bit. Is this character a null? 20 002250 001421 BEQ 30$ ;Yes, go to special null exit 21 002252 122700 000012 CMPB #LF,R0 ;Is this a line feed? 22 002256 001416 BEQ 30$ ;Yes, this must be the end of the line 23 002260 122700 000040 CMPB #SPACE,R0 ;Is this a control character? 24 002264 103407 BLO 20$ ;No, it must be a normal character 25 26 002266 112700 000040 MOVB #SPACE,R0 ;Change and all to 27 ;This is a 28 002272 020203 CMP R2,R3 ;Is this the first character? 29 002274 001761 BEQ 10$ ;Yes, ignore leading spaces 30 002276 120062 177777 CMPB R0,-1(R2) ;Was the last character a space 31 002302 001756 BEQ 10$ ;Yes ignore multiple spaces 32 33 002304 005301 20$: DEC R1 ;Character count, any room left? 34 002306 002754 BLT 10$ ;No, ignore it 35 002310 110022 MOVB R0,(R2)+ ;Put character into buffer 36 002312 000412 BR 50$ 37 38 002314 120203 30$: CMPB R2,R3 ;Is this the first character? 39 002316 001405 BEQ 40$ ;Yes, go to exit 40 41 002320 122762 000040 177777 CMPB #,-1(R2) ;Was the last character a space 42 002326 001001 BNE 40$ ;Yes ignore multiple spaces 43 002330 005302 DEC R2 ;Delete trailing spaces 44 45 002332 105012 40$: CLRB (R2) ;Put a null above the string 46 002334 062716 000002 ADD #2,(SP) 47 002340 012600 50$: MOV (SP)+,R0 48 002342 000200 60$: RTS R0 49 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 18 SEPCHR: SEPARATE CHARACTER STRINGS BY CLASS - SUBROUTINE 1 .SBTTL SEPCHR: SEPARATE CHARACTER STRINGS BY CLASS - SUBROUTINE 2 .ENABLE LSB 3 002344 SEPCHR: 4 5 ; PURPOSE Deliniate string of like character types. 6 ; Allow type to be fixed with input argument. 7 8 ; R0 is return address 9 ; R1 is output number of characters in string 10 ; R2 is input bottom of field, incremented 11 ; R2 is output bottom of next field 12 ; R3 is input field type: 0 = whatever occurs first 13 ; n = Same as output below 14 ; 5 or 4 allow all alpha 15 ; R3 is output field type: 0 = null 16 ; 1 = special character 17 ; 2 = numeric 18 ; 3 = control 19 ; 4 = alphabetic except p or P 20 ; 5 = "P" or "p" 21 ; Exit+0 is null character return 22 ; Exit+2 is normal return 23 24 002344 010046 MOV R0,-(SP) ;Save the return address 25 002346 012701 000000 MOV #0,R1 ;Initialize character count 26 002352 142712 000200 10$: BICB #200,(R2) ;Remove any parity bits. Is this a null? 27 002356 001501 BEQ SNULL ;Yes, go to null exit 28 002360 121227 000172 CMPB (R2),#'z ;Is this a special character? 29 002364 101045 BHI SSP ;Yes 30 002366 121227 000141 CMPB (R2),#'a ;Is this an alpha character? 31 002372 103052 BHIS SALPHA ;Yes 32 002374 121227 000132 CMPB (R2),#'Z ;Is this a special character? 33 002400 101037 BHI SSP ;Yes 34 002402 121227 000101 CMPB (R2),#'A ;Is this an alpha character? 35 002406 103044 BHIS SALPHA ;Yes 36 002410 121227 000071 CMPB (R2),#'9 ;Is this a special character? 37 002414 101031 BHI SSP ;Yes 38 002416 121227 000060 CMPB (R2),#'0 ;Is this a number character? 39 002422 103016 BHIS SNO ;Yes 40 002424 121227 000040 CMPB (R2),#SPACE ;Is this a control character? 41 002430 103001 BHIS SCTRL ;Yes 42 002432 000453 BR SNULL ;For no detect, go to null routine 43 44 002434 020327 000003 SCTRL: CMP R3,#3 ;Was there a previous control character? 45 002440 001404 BEQ 20$ ;Yes 46 002442 005701 TST R1 ;Is this the first character? 47 002444 001050 BNE 30$ ;No 48 002446 012703 000003 MOV #3,R3 ;Yes, set type to #3 for control character 49 002452 005201 20$: INC R1 ;Increment character count 50 002454 005202 INC R2 ;Increment character pointer 51 002456 000735 BR 10$ ;Go get another character 52 53 002460 020327 000002 SNO: CMP R3,#2 ;Was there a previous number character? 54 002464 001772 BEQ 20$ ;Yes 55 002466 005701 TST R1 ;Is this the first character? 56 002470 001036 BNE 30$ ;No 57 002472 012703 000002 MOV #2,R3 ;Yes, set type to #2 for number character DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 18-1 SEPCHR: SEPARATE CHARACTER STRINGS BY CLASS - SUBROUTINE 58 002476 000765 BR 20$ 59 60 002500 020327 000001 SSP: CMP R3,#1 ;Was there a previous special character? 61 002504 001762 BEQ 20$ ;Yes 62 002506 005701 TST R1 ;Is this the first character? 63 002510 001026 BNE 30$ ;No 64 002512 012703 000001 MOV #1,R3 ;Yes, set type to #1 for special character 65 002516 000755 BR 20$ 66 67 002520 SALPHA: 68 002520 020327 000004 CMP R3,#4 ;Was there a previous alpha character? 69 002524 103352 BHIS 20$ ;Yes 70 002526 005701 TST R1 ;Is this the first character? 71 002530 001016 BNE 30$ ;No 72 002532 012703 000004 MOV #4,R3 ;Yes, set type to #4 for alpha character 73 002536 000745 BR 20$ 74 75 002540 SPP: 76 002540 121227 000120 CMPB (R2),#'P ;Is this a "P"? 77 002544 001775 BEQ SPP ;Yes 78 002546 121027 000160 CMPB (R0),#'p ;Is this a "p"? 79 002552 001772 BEQ SPP ;Yes 80 81 002554 012703 000005 MOV #5,R3 ;Yes, set type to #5 for "P" or "p" character 82 002560 000734 BR 20$ 83 84 002562 005701 SNULL: TST R1 85 002564 001402 BEQ 40$ 86 002566 062716 000002 30$: ADD #2,(SP) 87 002572 012600 40$: MOV (SP)+,R0 88 002574 000200 50$: RTS R0 89 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 19 TNSTR: PARSE TIME STRING NUMBERS - SUBROUTINE 1 .SBTTL TNSTR: PARSE TIME STRING NUMBERS - SUBROUTINE 2 .ENABLE LSB 3 002576 TNSTR: 4 5 ; R0 is return address 6 ; R1 is input length of the input string, destroyed 7 ; R2 is input location of input string, top, retained 8 ; (R3) is input location of output string, bottom, incremented 9 ; (R3) is output location of output string, above top 10 ; R4 is input location of the output string length, added 11 ; R4 is output location of the output string length 12 ; Exit+0 is error exit 13 ; Exit+2 is normal exit 14 15 002576 010046 MOV R0,-(SP) ;Save return location 16 002600 010246 MOV R2,-(SP) ;Save location of input string 17 002602 060114 ADD R1,(R4) ;Length plus NONO into NONO 18 002604 021427 000002 CMP (R4),#2 19 002610 103412 BLO 10$ 20 002612 001413 BEQ 20$ 21 002614 021427 000004 CMP (R4),#4 22 002620 103406 BLO 10$ 23 002622 001407 BEQ 20$ 24 002624 021427 000006 CMP (R4),#6 25 002630 103402 BLO 10$ 26 002632 001403 BEQ 20$ 27 002634 000413 BR 40$ ;Too many numbers in the string 28 002636 005214 10$: INC (R4) ;increment NONO 29 002640 005213 INC (R3) ;Increment output location 30 002642 060113 20$: ADD R1,(R3) ;Add string length to output location 31 002644 011303 MOV (R3),R3 32 002646 114243 30$: MOVB -(R2),-(R3) 33 002650 005301 DEC R1 34 002652 003375 BGT 30$ 35 36 002654 012602 MOV (SP)+,R2 37 002656 012600 MOV (SP)+,R0 38 002660 005720 TST (R0)+ 39 002662 000401 BR 50$ 40 002664 012600 40$: MOV (SP)+,R0 ;Error exit 41 002666 000200 50$: RTS R0 42 002670 60$: .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 20 PARTIM: PARSE THE TIME STRING - SUBROUTINE 1 .SBTTL PARTIM: PARSE THE TIME STRING - SUBROUTINE 2 .ENABLE LSB 3 002670 PARTIM: 4 5 ; PURPOSE Put the time into ASCII string without separators - hhmmss - 6 7 ; R0 is the return location 8 ; R1 is destroyed 9 ; R2 is input location of input string, destroyed 10 ; R3 is destroyed 11 ; R4 is output LSH clock ticks 12 ; R5 is output MSH clock ticks 13 14 002670 010046 MOV R0,-(SP) ;Save return location 15 16 002672 012703 011256' MOV #,R3 17 002676 010327 MOV R3,(PC)+ 18 002700 000000 NOBUF: .WORD 0 ;Number of characters in output buffer 19 002702 012701 000006 MOV #6,R1 ;Index for loop to put zero's in buff 20 002706 112723 000060 10$: MOVB #'0,(R3)+ 21 002712 005301 DEC R1 22 002714 003374 BGT 10$ 23 002716 005013 CLR (R3) ;Put a null at the end of the string 24 002720 005027 CLR (PC)+ ;Initialize Number of numbers count 25 002722 000000 NONO: .WORD 0 ;Number of numbers count 26 ;Loop to input hours, then minutes, then seconds, then PM. 27 002724 012703 000000 20$: MOV #0,R3 ;Set-up any character type 28 002730 004067 177410 JSR R0,SEPCHR ;Separate character strings 29 002734 000450 BR 60$ ;This is a null, so go ask if PM? 30 31 002736 005701 TST R1 ;One or more characters in string? 32 002740 001430 BEQ 40$ ;No, go to time input error 33 34 002742 020327 000004 CMP R3,#4 ;Is the string an alphabetic? 35 002746 001016 BNE 30$ ;No 36 002750 010205 MOV R2,R5 ;Form address of first char in string 37 002752 160105 SUB R1,R5 38 002754 121527 000101 CMPB (R5),#'A ;Is the first character an "A" ? 39 002760 001442 BEQ AM12 ;Yes, skip the PM routines 40 002762 121527 000141 CMPB (R5),#'a ;Is the first chatacter an "a" ? 41 002766 001437 BEQ AM12 ;Yes, skip the PM routines 42 43 002770 121527 000120 CMPB (R5),#'P ;Is the first chatacter a "P" ? 44 002774 001432 BEQ 70$ ;Yes, skip to the PM routine 45 002776 121527 000160 CMPB (R5),#'p ;Is the first chatacter a "p" ? 46 003002 001427 BEQ 70$ ;Yes, skip to the PM routine 47 48 003004 020327 000005 30$: CMP R3,#5 ;Alpha string with "P"? 49 003010 001424 BEQ 70$ ;yes 50 003012 020327 000002 CMP R3,#2 ;Numeric string? 51 003016 001403 BEQ 50$ 52 003020 000741 BR 20$ ;Special, control, alpha are ignored 53 003022 000167 000514 40$: JMP TERROR ;No, there must be something wrong. 54 ; String is numeric, so ... 55 003026 026727 177670 000006 50$: CMP NONO,#6 ;Output length previously 6 chrs? 56 003034 103022 BHIS ASKPM ;Yes, exit this routine 57 003036 012703 002700' MOV #NOBUF,R3 ;Set-up buffer location DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 20-1 PARTIM: PARSE THE TIME STRING - SUBROUTINE 58 003042 012704 002722' MOV #NONO,R4 ;Set-up previous no. of characters 59 003046 004067 177524 JSR R0,TNSTR ;Parse time numeric string 60 003052 000413 BR ASKPM ;More than 6 numeric characters 61 003054 000723 BR 20$ ;Normal return 62 003056 000167 000020 60$: JMP ASKPM 63 003062 000167 000146 70$: JMP PM 64 65 003066 026727 006164 031061 AM12: CMP ,#"12 ;Is time 12: AM ? 66 003074 001470 BEQ ADD12 ;Yes, make it 24: 67 003076 000167 000162 JMP AM ;No, leave hours as is 68 .DSABLE LSB 69 DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 21 ... PARSE TIME, ASK, "IS THIS PM?" - INTERNAL 1 .SBTTL ... PARSE TIME, ASK, "IS THIS PM?" - INTERNAL 2 .ENABLE LSB 3 003102 ASKPM: 4 5 003102 016705 177614 MOV NONO,R5 6 003106 142705 000260 BICB #260,R5 7 003112 152705 000060 BISB #060,R5 8 9 003116 126727 006134 000061 CMPB ,#'1 ;Is this hour greater than 19.? 10 003124 101057 BHI AM ;Yes 11 003126 103404 BLO 10$ ;No 12 003130 126727 006123 000062 CMPB ,#'2 ;Is this hour greater than 12.? 13 003136 101052 BHI AM ;Yes 14 15 003140 012704 011256' 10$: MOV #,R4 16 003144 012700 007125' MOV #,R0 17 003150 112420 20$: MOVB (R4)+,(R0)+ ;Move time into ask message 18 003152 112420 MOVB (R4)+,(R0)+ 19 003154 005200 INC R0 20 003156 020027 007135' CMP R0,# 21 003162 103772 BLO 20$ 22 23 003164 .PRINT #MASKPM ;"Is this time PM?" 24 003172 012701 000001 MOV #1,R1 ;Get the keyboard response 25 003176 012702 011244' MOV #,R2 26 003202 004767 176770 JSR PC,TTYBIN 27 003206 142767 000240 006030 BICB #240, ;Change to upper case 28 003214 122767 000131 006022 CMPB #'Y, ;Is the response a "Y"? 29 003222 001404 BEQ PM ;Yes 30 003224 122767 000120 006012 CMPB #'P, ;Is the response a "P"? 31 003232 001315 BNE AM12 ;No, check for 12: AM 32 003234 PM: 33 003234 126727 006016 000061 CMPB ,#'1 ;Is this hour greater than 19.? 34 003242 101010 BHI AM ;Yes 35 003244 103404 BLO ADD12 ;No 36 003246 126727 006005 000061 CMPB ,#'1 ;Is this hour greater than 11.? 37 003254 101003 BHI AM ;Yes 38 39 003256 062767 001001 005772 ADD12: ADD #001001, ;Add 12 hours to the time 40 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 22 ... CONVERT TIME TO SECONDS PAST MIDNIGHT - INTERNAL 1 .SBTTL ... CONVERT TIME TO SECONDS PAST MIDNIGHT - INTERNAL 2 003264 AM: 3 .ENABLE LSB 4 ; TTYBUF+30. is input start at bottom - hhmmss - 5 ; R0 is destroyed 6 ; R1 is destroyed 7 ; R2 is destroyed 8 ; R3 is destroyed 9 ; R4 is output most significant half of ticks 10 ; R5 is output least significant half of ticks 11 003264 126727 005766 000062 CMPB ,#'2 ;Is this hour greater than 29.? 12 003272 101050 BHI SUB24H ;Yes 13 003274 103404 BLO 10$ ;No 14 003276 126727 005755 000063 CMPB ,#'3 ;Is this hour greater than 23.? 15 003304 101043 BHI SUB24H ;Yes 16 003306 126727 005746 000065 10$: CMPB ,#'5 ;Is this minute greater than 59.? 17 003314 101052 BHI SUB60M ;Yes 18 003316 126727 005740 000065 CMPB ,#'5 ;Is this second greater than 59.? 19 003324 101052 BHI SUB60S ;Yes 20 003326 012700 000003 MOV #3,R0 ;Loop index 21 003332 012701 011256' MOV #,R1 22 003336 005005 CLR R5 ;LSH accumulator 23 003340 005004 CLR R4 ;MSH accumulator 24 003342 112102 20$: MOVB (R1)+,R2 ;Get the 10's digit 25 003344 042702 177760 BIC #177760,R2 ;Strip ASCII bits 26 003350 006302 ASL R2 ;Multiply the 10's digit times 10 27 003352 010203 MOV R2,R3 28 003354 006302 ASL R2 29 003356 006302 ASL R2 30 003360 060203 ADD R2,R3 31 003362 112102 MOVB (R1)+,R2 ;Get the units digit 32 003364 042702 177760 BIC #177760,R2 ;Strip ASCII bits 33 003370 060203 ADD R2,R3 ;Add in the units 34 35 003372 060305 ADD R3,R5 ;Accumulate the above number 36 003374 005504 ADC R4 37 38 003376 005300 DEC R0 ;Have we finished? 39 003400 003430 BLE 40$ ;Yes 40 41 003402 012702 000074 MOV #60.,R2 ;Set up for multiply times 60. 42 003406 004767 000250 JSR PC,MULTIM ;Multiply time 43 003412 000753 BR 20$ ;Go do minutes, the seconds 44 45 003414 162767 000002 005634 SUB24H: SUB #2, ;Subtract 20 hours 46 003422 122767 000063 005627 CMPB #'3, ;Is units greater than 3 hours? 47 003430 103003 BHIS 30$ ;No 48 003432 162767 002000 005616 SUB #002000, ;Yes, subtract 4 hours 49 003440 000711 30$: BR AM 50 003442 162767 000006 005610 SUB60M: SUB #6., ;Subtract 60 minutes 51 003450 000705 BR AM 52 003452 162767 000006 005602 SUB60S: SUB #6., ;Subtract 60 seconds 53 003460 000701 BR AM DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 23 ... CONVERT TIME TO SECONDS PAST MIDNIGHT - INTERNAL 1 003462 40$: 2 .SBTTL ... CALCULATE TICKS FROM SECONDS PAST MIDNIGHT - INTERNAL 3 ; R2 is destroyed 4 ; R3 is destroyed 5 ; R4 is input output MSH 6 ; R5 is input output LSH 7 8 003462 016702 001702 MOV CLCKHZ,R2 ;Multiply seconds times clock speed 9 003466 004767 000170 JSR PC,MULTIM 10 ; Set the system time 11 003472 010467 005272 MOV R4,CTICK1 12 003476 010567 005270 MOV R5, 13 003502 012767 177777 005256 MOV #<-1>,CDATE1 14 003510 .SDTTM #MAREA,#CDATE1 ;Set the system time 15 16 003530 004767 000034 JSR PC,LOGTIM ;Put time into log buffer 17 18 .DSABLE LSB 19 .ENABL LSB 20 003534 062716 000002 ADD #2,(SP) 21 003540 000411 BR 10$ 22 23 003542 TERROR: .PRINT #MERROR 24 003550 .PRINT #MTER 25 003556 .PRINT #TTYBUF 26 003564 012600 10$: MOV (SP)+,R0 27 003566 000200 RTS R0 28 29 003570 LOGTIM: .GTIM #MAREA,#CTICK1 ;Move system time into log 30 003610 012701 011440' MOV #,R1 ;Set up destination location 31 003614 012702 010770' MOV #CTICK1,R2 ;Set up source location 32 003620 004767 001534 JSR PC,CLCKLD ;Load clock time into log 33 34 003624 012703 000010 MOV #8.,R3 ;Set up length of string 35 003630 012702 007533' MOV #MIFMT,R2 ;Set up destination 36 003634 012701 011440' MOV #,R1 ;Set up source 37 003640 004767 001156 JSR PC,MOVEBY ;Move byte string 38 003644 .PRINT #MITHNK 39 003652 .PRINT #MITFT ;"Thanks for time." 40 003660 000207 RTS PC 41 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 24 MULTIM: MULTIPLY SINGLE X DOUBLE PRECISION - SUBROUTINE 1 .SBTTL MULTIM: MULTIPLY SINGLE X DOUBLE PRECISION - SUBROUTINE 2 .ENABLE LSB 3 003662 MULTIM: 4 ; PURPOSE Multiply single precision binary LSH in R2 times double precision 5 ; binary R4(MSH), R5(LSH). Output in R4(MSH), and R5(LSH). 6 ; R2 is input single precision binary 7 ; R3 is used and restored 8 ; R4 is input, and output MSH 9 ; R5 is input, and output LSH 10 003662 010346 MOV R3,-(SP) 11 003664 012703 000020 MOV #16.,R3 ;Bit counter 12 003670 010446 MOV R4,-(SP) ;MSH 13 003672 010546 MOV R5,-(SP) ;LSH 14 003674 005004 CLR R4 ;MSH 15 003676 005005 CLR R5 ;LSH 16 003700 006305 10$: ASL R5 ;LSH multiply times 2 17 003702 006104 ROL R4 ;MSH multiply times 2 18 003704 006302 ASL R2 ;MULT 19 003706 103005 BCC 20$ 20 003710 005502 ADC R2 ;Restore R2 21 003712 061605 ADD (SP),R5 ;LSH 22 003714 005504 ADC R4 ;MSH 23 003716 066604 000002 ADD 2(SP),R4 ;MSH 24 003722 005303 20$: DEC R3 25 003724 001365 BNE 10$ 26 003726 022626 CMP (SP)+,(SP)+ ;Restore stack pointer 27 003730 012603 MOV (SP)+,R3 28 003732 000207 RTS PC 29 .DSABLE LSB 30 003734 MUL45: 31 .ENABLE LSB 32 ; PURPOSE Multiply single precision binary R4(MSH), R5(LSH). 33 ; Output in R5. 34 ; R3 is used and restored 35 ; R4 is input 36 ; R5 is input, and output 37 003734 010346 MOV R3,-(SP) 38 003736 010546 MOV R5,-(SP) ;LSH 39 003740 012703 000020 MOV #16.,R3 ;Bit counter 40 003744 005005 CLR R5 ;LSH 41 003746 006305 10$: ASL R5 ;LSH 42 003750 006304 ASL R4 ;MULT 43 003752 103002 BCC 20$ 44 003754 005504 ADC R4 ;Restore R4 45 003756 061605 ADD (SP),R5 ;LSH 46 003760 005303 20$: DEC R3 47 003762 001371 BNE 10$ 48 003764 005726 TST (SP)+ ;Restore stack pointer 49 003766 012603 MOV (SP)+,R3 50 003770 000207 RTS PC 51 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 25 PARNOS: PARSE DATE NUMBER STRING - SUBROUTINE 1 .SBTTL PARNOS: PARSE DATE NUMBER STRING - SUBROUTINE 2 .ENABLE LSB 3 003772 PARNOS: 4 5 ; PURPOSE Store partial date codes into matrix for RT-11 date assembly. 6 7 ; R0 is return address 8 ; R1 is input field length, retained 9 ; R2 is input upper bound of field, retained 10 ; R3 is input start of output buffer, retained 11 ; R4 is retained 12 ; R5 is retained 13 ; Exit+0 is error return 14 ; Exit+2 is normal return 15 16 003772 010546 MOV R5,-(SP) 17 003774 010446 MOV R4,-(SP) 18 003776 010046 MOV R0,-(SP) ;Store return address 19 20 004000 005027 CLR (PC)+ ;Initialize the year 2000 flag 21 004002 000000 YR2000: .WORD 0 22 004004 020127 000004 CMP R1,#4 ;Is string longer than 4 digits? 23 004010 101402 BLOS 10$ ;No 24 004012 012701 000004 MOV #4,R1 ;Use only the right hand 4 digits 25 004016 10$: 26 004016 010200 MOV R2,R0 27 004020 160100 SUB R1,R0 ;R0 is begining, low end, of string 28 29 004022 020127 000001 CMP R1,#1 ;How long is the string? 30 004026 103573 BLO 170$ ;Length is zero 31 004030 001420 BEQ 40$ ;Length is 1 32 33 004032 020127 000003 CMP R1,#3 ;How long is the string? 34 004036 103407 BLO 30$ ;Length is 2 35 004040 001403 BEQ 20$ ;Length is 3 36 ;Length is 4 37 004042 122027 000060 CMPB (R0)+,#'0 ;Is 4th digit a zero? 38 004046 001011 BNE 40$ ;No, it must be a year 39 004050 122027 000060 20$: CMPB (R0)+,#'0 ;Is third digit a zero? 40 004054 001170 BNE 190$ ;No, it must be a Julian date 41 004056 122027 000060 30$: CMPB (R0)+,#'0 ;Is second digit a zero? 42 004062 001003 BNE 40$ ;No, it must be a day or month 43 004064 012767 003720 177710 MOV #2000.,YR2000 ;Yes, it must be a 200x year 44 45 004072 012705 011000' 40$: MOV #PDNBUF,R5 ;Get buffer location 46 004076 012704 000010 MOV #8.,R4 ;Buffer length 47 004102 005025 50$: CLR (R5)+ ;Clear the buffer 48 004104 005304 DEC R4 49 004106 001375 BNE 50$ ;Loop to clear the buffer 50 51 004110 010104 MOV R1,R4 ;Length of string transfer 52 004112 010200 MOV R2,R0 ;Location above source string 53 004114 012705 011020' MOV #,R5 ;Location above destination string 54 004120 114045 60$: MOVB -(R0),-(R5) ;Move a digit 55 004122 142715 000260 BICB #260,(R5) ;Remove ASCII bits 56 004126 005304 DEC R4 57 004130 001373 BNE 60$ ;Loop to move digits DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 25-1 PARNOS: PARSE DATE NUMBER STRING - SUBROUTINE 58 59 004132 012700 011014' MOV #,R0 ;Initialize source string location 60 004136 012701 000004 MOV #4,R1 ;Initialize character counter 61 004142 005004 CLR R4 ;Initialize accumulator 62 004144 005005 CLR R5 ;Initialize accumulator 63 ;Calculate the binary equivalent of the ASCII digits 64 004146 012705 000012 70$: MOV #10.,R5 ;Multiply times 10 and accumulate 65 004152 004767 177556 JSR PC,MUL45 ;MUL R4,R5 66 004156 112004 MOVB (R0)+,R4 67 004160 060504 ADD R5,R4 68 004162 005301 DEC R1 69 004164 001370 BNE 70$ ;Loop the calculation for four digits 70 71 004166 010405 MOV R4,R5 ;Put binary number into R5 72 004170 066705 177606 ADD YR2000,R5 ;Add 2000. if needed for the year 73 004174 005705 80$: TST R5 ;Is the number zero or negative? 74 004176 001507 BEQ 170$ ;"Zero date not recognized" 75 004200 020527 000037 CMP R5,#31. ;Is the number greater than 31? 76 004204 101047 BHI 140$ ;Yes, it must be a year 77 004206 020527 000014 CMP R5,#12. ;Is the number greater than 12.? 78 004212 101021 BHI 120$ ;Yes it must be a day 79 80 004214 90$: ;It must be day code or month code routine 81 004214 012700 000020 MOV #20,R0 82 004220 006305 100$: ASL R5 ;Form day code 83 004222 006000 ROR R0 84 004224 103375 BCC 100$ 85 004226 062703 000002 ADD #DAYC,R3 ;Form address for day code 86 004232 010513 MOV R5,(R3) ;Store day code 87 88 004234 012700 000020 MOV #20,R0 ;MUL R0,R5 89 004240 006305 110$: ASL R5 ;Form month code from day code 90 004242 006000 ROR R0 91 004244 103375 BCC 110$ 92 93 004246 062703 177776 ADD #,R3 ;Form address for month code 94 004252 010513 MOV R5,(R3) ;Store month code 95 004254 000455 BR 160$ 96 004256 120$: ;Day code routine 97 004256 012700 000020 MOV #20,R0 98 004262 006305 130$: ASL R5 ;Form day code 99 004264 006000 ROR R0 100 004266 103375 BCC 130$ 101 102 004270 010567 004550 MOV R5,+DAYC>> ;Store day code in must-be 103 104 004274 010500 MOV R5,R0 ;Set up thanks for year message. 105 004276 012701 007503' MOV #MIFMD,R1 ;Set up destination address 106 004302 004767 000704 JSR PC,CVDAY ;Put day into message 107 004306 .PRINT #MITHNK 108 004314 .PRINT #MITFD ;"Thanks for the day..." 109 004322 000432 BR 160$ 110 111 004324 140$: ;Year code routine 112 004324 020527 003664 CMP R5,#1972. ;Is year 1972. or after? 113 004330 103402 BLO 150$ ;No 114 004332 162705 003554 SUB #1900.,R5 ;Yes, so subtract 1900. DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 25-2 PARNOS: PARSE DATE NUMBER STRING - SUBROUTINE 115 004336 150$: 116 004336 020527 000147 CMP R5,#103. ;Is year after 2003.? 117 004342 101031 BHI 180$ ;Yes, go to error exit 118 004344 020527 000111 CMP R5,#73. ;Is year '73 or after? 119 004350 103426 BLO 180$ ;No, go to error exit 120 004352 162705 000110 SUB #72.,R5 ;Subtract the '72 offset for RT-11 121 004356 010567 004464 MOV R5,+YEARC>> 122 123 004362 010500 MOV R5,R0 ;Set up thanks for year message. 124 004364 012701 007517' MOV #MIFMY,R1 ;Set up destination address 125 004370 004767 000676 JSR PC,CVYEAR ;Put year into message 126 004374 .PRINT #MITHNK 127 004402 .PRINT #MITFY ;"Thanks for the year ..." 128 004410 062716 000002 160$: ADD #2,(SP) 129 004414 000427 BR 210$ 130 131 004416 170$: .PRINT #MFZNR ;"I do not understand a date of zero. 132 004424 000423 BR 210$ 133 004426 180$: .PRINT #MFAYF ;"...only accept years from 1973 to 2003." 134 004434 000417 BR 210$ 135 004436 005300 190$: DEC R0 136 004440 122027 000063 CMPB (R0)+,#'3 ;Is hundreds digit greater than 3 ? 137 004444 101370 BHI 180$ ;Yes, its not Julian 138 004446 103407 BLO 200$ ;No, it's Julian 139 004450 122027 000066 CMPB (R0)+,#'6 ;Is tens digit greater than 6 ? 140 004454 101364 BHI 180$ ;Yes, its not Julian 141 004456 103403 BLO 200$ ;No, it's Julian 142 004460 121027 000066 CMPB (R0),#'6 ;Is hundreds digit greater than 6 ? 143 004464 101360 BHI 180$ ;Yes, its not Julian 144 145 004466 200$: .PRINT #MFDJE ;"I do not understand Julian dates." 146 147 004474 012600 210$: MOV (SP)+,R0 148 004476 012604 MOV (SP)+,R4 149 004500 012605 MOV (SP)+,R5 150 004502 000200 RTS R0 151 .EVEN 152 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 26 PARALP: PARSE DATE ALPHABETIC STRING - SUBROUTINE 1 .SBTTL PARALP: PARSE DATE ALPHABETIC STRING - SUBROUTINE 2 004504 PARALP: .ENABLE LSB 3 ; PURPOSE: Store partial date codes into matrix for RT-11 date assembly. 4 ; R0 is return address 5 ; R1 is input field length, retained 6 ; R2 is input upper bound location of string, retained 7 ; R3 is input start location of output string, destroyed 8 ; R4 is retained 9 ; R5 is retained 10 ; Exit+0 is for error return 11 ; Exit+2 is for normal return 12 13 004504 010546 MOV R5,-(SP) 14 004506 010446 MOV R4,-(SP) 15 004510 010046 MOV R0,-(SP) ;Store return address 16 004512 010200 MOV R2,R0 ;Work with string location 17 004514 160100 SUB R1,R0 ;Find start of string 18 004516 005004 CLR R4 ;Initialize month pointer 19 004520 010003 10$: MOV R0,R3 ;Position of alpha string 20 004522 020427 000014 CMP R4,#12. ;Find month in 12 tries? 21 004526 001452 BEQ 60$ ;No, go to error exit 22 004530 005204 INC R4 23 004532 012705 000004 MOV #4,R5 24 004536 004767 177172 JSR PC,MUL45 ;MUL R4,R5 25 004542 062705 010475' ADD #,R5 ;Position in month table is R5 26 004546 020127 000002 CMP R1,#2 ;Is string length less than 3 27 004552 103411 BLO 30$ ;Length is 1 28 004554 001404 BEQ 20$ ;Length is 2 29 004556 142713 000240 BICB #240,(R3) ;Convert character to upper case 30 004562 122523 CMPB (R5)+,(R3)+ ;Compare input string with month table 31 004564 001355 BNE 10$ 32 004566 20$: 33 004566 142713 000240 BICB #240,(R3) ;Convert character to upper case 34 004572 122523 CMPB (R5)+,(R3)+ ;Compare input string with month table 35 004574 001351 BNE 10$ 36 004576 30$: 37 004576 142713 000240 BICB #240,(R3) ;Convert character to upper case 38 004602 121513 CMPB (R5),(R3) ;Compare input string with month table 39 004604 001345 BNE 10$ ;R4 is month 40 004606 40$: 41 004606 012705 002000 MOV #2000,R5 ;Form month code 42 004612 004767 177116 JSR PC,MUL45 ;MUL R4,R5 43 004616 010567 004220 MOV R5,+MONTHC>> ;Store month in must-be 44 45 004622 010500 MOV R5,R0 ;Set up thanks for month message. 46 004624 012701 007467' MOV #MIFMM,R1 ;Set up destination address 47 004630 004767 000404 JSR PC,CVMNTH ;Put month into message 48 004634 .PRINT #MITHNK 49 004642 .PRINT #MITFM ;"Thanks for the month ..." 50 004650 062716 000002 50$: ADD #2,(SP) ;Normal exit 51 004654 012600 60$: MOV (SP)+,R0 52 004656 012604 MOV (SP)+,R4 53 004660 012605 MOV (SP)+,R5 54 004662 000200 70$: RTS R0 55 .EVEN 56 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 27 YESNO: SEPARATE A "YES", "NO", "" STRING - SUBROUTINE 1 .SBTTL YESNO: SEPARATE A "YES", "NO", "" STRING - SUBROUTINE 2 .ENABLE LSB 3 004664 YESNO: 4 5 ; PURPOSE Print " [No] ?" , Then input a string, then 6 ; Determine if a string is a "yes" or a "no" or something else 7 8 ; R0 is the return location 9 ; TTYBUF is the string location, unchanged 10 ; String is left in TTYBUF 11 ; Exit is for the "NO" or for 12 ; Exit+2 is for the "YES" 13 ; Exit+4 is for the anything else 14 15 004664 010346 MOV R3,-(SP) 16 004666 010246 MOV R2,-(SP) 17 004670 010146 MOV R1,-(SP) 18 004672 010046 MOV R0,-(SP) ;Save return location 19 20 004674 .PRINT #MYESNO 21 004702 012702 011220' MOV #TTYBUF,R2 ;Ask for (Y/N) 22 004706 004767 175264 JSR PC,TTYBIN 23 004712 012700 004764' MOV #NO,R0 24 004716 010302 MOV R3,R2 25 26 004720 004767 000050 JSR PC,TSTSTR ;Is the string a "NO" ? 27 004724 000412 BR 40$ ;Confirmed 28 ;Not a "no" 29 30 004726 012700 004767' 10$: MOV #YES,R0 31 004732 010302 MOV R3,R2 32 33 004734 004767 000034 JSR PC,TSTSTR ;Is this string a "YES" ? 34 004740 000402 BR 30$ ;Yes 35 ;No, it must be "other" 36 37 004742 062716 000002 20$: ADD #2,(SP) ;Neither "yes" nor "no" 38 ;Increment exit by 2 instructions 39 40 004746 062716 000002 30$: ADD #2,(SP) ;"yes" exit 41 ;Increment exit by 1 instruction 42 43 004752 012600 40$: MOV (SP)+,R0 ;"no" or null exit 44 004754 012601 MOV (SP)+,R1 45 004756 012602 MOV (SP)+,R2 46 004760 012603 MOV (SP)+,R3 47 004762 000200 50$: RTS R0 48 49 004764 116 117 000 NO: .ASCIZ \NO\ 50 004767 131 105 123 YES: .ASCIZ \YES\<0> 004772 000 000 51 .EVEN 52 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 28 YESNO: SEPARATE A "YES", "NO", "" STRING - SUBROUTINE 1 .ENABLE LSB 2 004774 TSTSTR: ;Purpose: Test 2 ASCII strings for match or no match. 3 ; Reference string must be upper case. 4 ; Match if unknown is shorter, but matches to its end. 5 ; Lower case unknown will match upper case reference. 6 7 ; R1 is the working register, destroyed 8 ; R2 is unknown string location, destroyed 9 ; R3 is the reference string location, destroyed 10 ; Exit is for the match or the case 11 ; Exit+2 is for the no-match case 12 13 004774 112201 10$: MOVB (R2)+,R1 ;Is this character a null ? 14 004776 001410 BEQ 30$ ;Yes, strings match 15 005000 042701 177640 BIC #177640,R1 ;Force upper case 16 005004 120110 CMPB R1,(R0) ;Is this character a match? 17 005006 001002 BNE 20$ ;No, exit to no-match case 18 005010 105720 TSTB (R0)+ ;Yes, is this end of test? 19 005012 001370 BNE 10$ ;No, get another character 20 21 005014 062716 000002 20$: ADD #2,(SP) ;No-match exit 22 005020 000207 30$: RTS PC ;Match exit 23 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 29 MOVEBY: MOVE BYTE STRING - SUBROUTINE 1 .SBTTL MOVEBY: MOVE BYTE STRING - SUBROUTINE 2 .ENABLE LSB 3 005022 MOVEBY: 4 5 ; PURPOSE Move R3 bytes at (R1) to (R2) 6 7 005022 112122 10$: MOVB (R1)+,(R2)+ 8 005024 005303 DEC R3 9 005026 001375 BNE 10$ 10 005030 000207 RTS PC ;Return 11 12 .SBTTL OPENCHAN: OPEN DATA FILE CHANNEL - SUBROUTINE 13 005032 OPENCHAN: 14 15 ; PURPOSE lookup for channel 2 16 17 005032 012503 MOV (R5)+,R3 ;Put #1 or #2 argument into R3 18 005034 010546 MOV R5,-(SP) ;Save return address on the stack 19 005036 .DSTATUS #MAREA,R4 ;Device status for the (R4) device 20 005046 005767 003702 TST MAREA+4 ;Is the handler in memory for (R4) device? 21 005052 001007 BNE 20$ ;Yes, then branch 22 005054 .PRINT #MERROR 23 005062 .PRINT #MERHNL ;No, print "Handler not loaded" 24 005070 000433 BR 40$ ;Branch to print the device name 25 26 005072 20$: .LOOKUP #MAREA,R3,R4,#0 27 005116 103024 BCC 50$ ;Lookup error? 28 005120 105737 000052 TSTB @#EMTERB ;Yes, then is the error for "file not found"? 29 005124 001007 BNE 30$ ;Yes, go to print "File Not Found" 30 005126 .PRINT #MERROR 31 005134 .PRINT #MERCOI ;No, print "Cannot open input device" 32 005142 000406 BR 40$ ;Branch to print the device name 33 005144 30$: .PRINT #MERROR 34 005152 .PRINT #MERFNF ;Print "File not found" 35 005160 40$: .PRINT DEVPTR ;Print the device name 36 005166 000261 SEC ;Set the carry bit as an error flag for the return 37 005170 012605 50$: MOV (SP)+,R5 ;Restore the return address to R5 38 005172 000205 RTS R5 ;Return DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 30 DATELD: LOAD ASCII DATE TO LOCATION - SUBROUTINE 1 .SBTTL DATELD: LOAD ASCII DATE TO LOCATION - SUBROUTINE 2 005174 DATELD: 3 .ENABLE LSB 4 ; PURPOSE Input RT-11 date. Output ASCII date string dd-nnn-yy. 5 6 ; 0 0 month day year-1972 7 ; R0 is the machine date ;15 14 13..10 9...5 4...0 8 ; 6 5 4 3 2 1 9 ; R0 is input RT-11 date word, retained 10 ; R1 is input location of destination string 11 ; R1 is output location above destination string 12 ; R3 is destroyed 13 14 005174 004767 000012 JSR PC,CVDAY 15 005200 004767 000034 JSR PC,CVMNTH 16 005204 004767 000062 JSR PC,CVYEAR 17 005210 000207 RTS PC 18 19 005212 CVDAY: 20 005212 010046 MOV R0,-(SP) ;Save the date word 21 005214 006100 ROL R0 ;Rotate the day into the 4 LSB's 22 005216 006100 ROL R0 23 005220 006100 ROL R0 24 005222 000300 SWAB R0 25 005224 042700 177740 BIC #<^C N037>,R0 ;Isolate the day of month into the 4 LSB's 26 005230 004767 000052 JSR PC,BTO1ASCII ;Put ASCII day into the text 27 005234 012600 MOV (SP)+,R0 ;Get a fresh copy of the date word 28 005236 000207 RTS PC 29 30 005240 CVMNTH: 31 005240 010046 MOV R0,-(SP) ;Save the date word 32 005242 000300 SWAB R0 ;Put the month bits into bits 5 thru 2 33 005244 042700 177703 BIC #<^C N074>,R0 ;Isolate the binary month into bits 5 thru 2 34 005250 062700 010474' ADD #MONTHT-4,R0 ;Add the address of the month table 35 005254 012703 000005 MOV #NMBR05,R3 ;Use R3=5 as the index for month move to text 36 005260 112021 10$: MOVB (R0)+,(R1)+ ;Put "-mmm-" into text 37 005262 005303 DEC R3 38 005264 001375 BNE 10$ ;Is this the last character to move? 39 40 005266 012600 MOV (SP)+,R0 ;Get a fresh copy of the date word 41 005270 000207 RTS PC DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 31 DATELD: LOAD ASCII DATE TO LOCATION - SUBROUTINE 1 .ENABLE LSB 2 005272 CVYEAR: 3 005272 010046 MOV R0,-(SP) ;Save the date word 4 005274 042700 177740 BIC #<^C N037>,R0 ;Isolate the binary year-1972 into 5 LSB's 5 005300 062700 000110 ADD #YEAR72,R0 ;Add the '72 year offset which is in the RMON 6 005304 000401 BR 10$ 7 005306 BTO1ASCII: ;Subrtn ;For one digit numbers 8 ;Convert binary to ASCII decimal 9 005306 010046 MOV R0,-(SP) ;Save the date word 10 005310 020027 000012 10$: CMP R0,#10. ;Is the date 2 digits long 11 005314 103004 BHIS 20$ ;Yes 12 005316 112721 000040 MOVB #,(R1)+ ;No, fill string with a leading space 13 005322 000411 BR 40$ ;Then bypass most of routine 14 15 005324 BTO2ASCII: ;Subrtn ;convert binary to ASCII decimal 16 ;For two digit numbers 17 005324 010046 MOV R0,-(SP) ;Save the date word 18 005326 000300 20$: SWAB R0 ;Source is R0, destination is (R1) 19 005330 062700 173001 30$: ADD #<-10.*LBYTE+1>,R0 ;Form ten's digit with multiple add of -10. 20 005334 100375 BPL 30$ ;Add back last 10. and 60 for ascii conversion 21 005336 062700 005057 ADD #<10.*LBYTE-1+60>,R0 22 005342 110021 MOVB R0,(R1)+ ;Put ASCII ten's digit into (R1)+ 23 005344 000300 SWAB R0 ;Move unit;s back to the right byte 24 005346 062700 000060 40$: ADD #N060,R0 ;Add 60 for ASCII formation 25 005352 110021 MOVB R0,(R1)+ ;Put units digit into(R1)+ 26 005354 012600 MOV (SP)+,R0 ;Get a fresh copy of the date word 27 005356 000207 RTS PC ;Return DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 32 CLKLD: LOAD ASCII CLOCK INTO LOCATION - SUBROUTINE 1 .SBTTL CLKLD: LOAD ASCII CLOCK INTO LOCATION - SUBROUTINE 2 005360 CLCKLD: 3 .ENABLE LSB 4 ; PURPOSE Load clock time into the log text line 5 6 ; R1 is output location for ASCII 7 ; R2 is the location of clock ticks past midnight 8 9 005360 012203 MOV (R2)+,R3 ;R3 is MS word of clock ticks 10 005362 011202 MOV (R2),R2 ;R2 is LS word of clock ticks 11 005364 004467 000046 JSR R4,40$ 12 005370 000000 CLCKHZ: .WORD 0 ;60.hz or 50.hz, or 0 for no Line Time Clock 13 005372 012700 177777 MOV #MINUS1,R0 14 005376 012705 000003 MOV #NMBR03,R5 15 005402 010046 10$: MOV R0,-(SP) 16 005404 004467 000026 JSR R4,40$ 17 005410 000074 .WORD CLCK60 ;60. seconds in a minute 18 005412 005305 DEC R5 19 005414 001372 BNE 10$ 20 005416 004767 177702 20$: JSR PC,BTO2ASCII ;Convert binary to 2 ASCII digits 21 005422 012600 MOV (SP)+,R0 22 005424 100403 BMI 30$ 23 005426 112721 000072 MOVB #N072,(R1)+ ;60. 24 005432 000771 BR 20$ 25 005434 000207 30$: RTS PC ;Return 26 27 005436 010546 40$: MOV R5,-(SP) ;Subrtn ;Save R5 28 005440 005000 CLR R0 29 005442 012705 000037 MOV #N037,R5 ;31. 30 005446 006302 50$: ASL R2 ;R2 is LS ticks 31 005450 006103 ROL R3 ;R3 is MS ticks 32 005452 006100 ROL R0 33 005454 020014 CMP R0,(R4) ;(R4) is flagword of the current record 34 005456 103402 BCS 60$ 35 005460 161400 SUB (R4),R0 36 005462 005202 INC R2 37 005464 005305 60$: DEC R5 38 005466 100367 BPL 50$ 39 005470 012605 MOV (SP)+,R5 40 005472 062704 000002 ADD #2,R4 ;Increment R4 past the subroutine argument 41 005476 000204 RTS R4 ;Return DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 33 COMPLETION ROUTINES 1 .SBTTL COMPLETION ROUTINES 2 .ENABLE LSB 3 005500 TRANSFER: ;Subrtn ;Transfer a file 4 005500 005067 003256 CLR LRBLK ;Set block number to zero 5 005504 .READW #LAREA,#CHAN02,,,LRBLK 6 005530 103401 BCS 10$ ;EMT error byte is zero if EOF 7 005532 000207 RTS PC ;Return 8 9 10 005534 10$: .PRINT #MERROR 11 005542 .PRINT #MERIE ; 12 005550 012700 010732' 20$: MOV #MBUF2,R0 13 005554 000167 000150 JMP PRTEXIT 14 15 005560 30$: .PRINT #MERROR 16 005566 .PRINT #MEROE 17 005574 000765 BR 20$ 18 19 005576 SAVELOG: 20 005576 005067 003160 CLR LRBLK ;Set block number to zero 21 005602 .WRITW #LAREA,#CHAN02,,,LRBLK 22 005626 103754 BCS 30$ 23 005630 000207 RTS PC 24 25 .DSABLE LSB DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 34 ERROR MESSAGES AND ERROR EXIT 1 .SBTTL ERROR MESSAGES AND ERROR EXIT 2 .ENABLE LSB 3 005632 D4YERR: .PRINT #MFD4 4 005640 PERROR #MFD4Y,PRTEXIT ;"Error during accumulation of year code" 5 005654 D4MERR: .PRINT #MFD4 6 005662 PERROR #MFD4M,PRTEXIT ;"Error during accumulation of month code" 7 005676 D4DERR: .PRINT #MFD4 8 005704 PERROR #MFD4D,PRTEXIT ;"Error during accumulation of day code" 9 005720 NEMERR: .PRINT #MENEM ;"Not enough memory" 10 005726 000407 BR 10$ 11 005730 PRTEXIT: .PRINT R0 ;Entry ;Print error message 12 005732 SCCEXIT: .PRINT #MFSCC ;Entry ;"Abnormal exit from open channel 2." 13 005740 .CLOSE #CHAN02 14 005746 10$: .EXIT ;Exit ;Program exit 15 DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 35 MESSAGES FOR QUESTION AND FOR ERRORS 1 .SBTTL MESSAGES FOR QUESTION AND FOR ERRORS 2 .NLIST BEX 3 005750 077 104 101 MERROR: .ASCII \?DAYLOG-F-\<200> 4 5 005763 116 157 164 MENEM: .ASCIZ \Not Enough Memory\ 6 006005 111 156 160 MERIE: .ASCII \Input Error on file \<200> 7 006032 117 165 164 MEROE: .ASCII \Output Error on file \<200> 8 006060 103 141 156 MERCOI: .ASCII \Cannot open input device \<200> 9 006112 106 151 154 MERFNF: .ASCII \File Not Found \<200> 10 006132 110 141 156 MERHNL: .ASCII \Handler Not Loaded \<200> 11 006156 101 142 156 MFSCC: .ASCIZ \Abnormal exit from open chan 2.\ 12 006216 105 162 162 MFD4: .ASCII \Error during accumulation of \<200> 13 006254 171 145 141 MFD4Y: .ASCIZ \year code.\ 14 006267 155 157 156 MFD4M: .ASCIZ \month code.\ 15 006303 144 141 171 MFD4D: .ASCIZ \day code.\ 16 006315 015 012 077 MWCNR: .ASCII \?DAYLOG-W-The line time clock is not runing.\ 17 006373 015 012 120 .ASCII \Please turn on the LTC switch\ 18 006432 040 141 164 .ASCIZ \ at the front on the computer:\ 19 006471 015 012 077 MITY: .ASCIZ \?DAYLOG-I-Thank you.\ 20 006520 011 101 162 MIAYA: .ASCII \Are you a different person\<200> 21 006554 015 012 011 MIWIY: .ASCII \What is your name? \<200> 22 006603 015 012 124 MITLI: .ASCII \This DAYLOG time is \<200> 23 006632 015 012 124 MILLW: .ASCII \The last DAYLOG time was \ 24 006665 060 060 072 MITIM: .ASCII \00:00 on \ 25 006676 056 056 055 MIDAT: .ASCII \..-...-.. by \ 26 006713 120 145 162 MINAM: .ASCIZ \Person's name \ 27 006763 015 012 123 MTER: .ASCIZ \Sorry, I don't recognize this as a time format.\ 28 007045 015 012 124 MITST: .ASCII \The system time is \ 29 007072 060 060 072 MISTC: .ASCIZ \00:00:00.\ 30 007104 015 012 011 MASKPM: .ASCII \Is this time, \ 31 007125 060 060 072 MPMHR: .ASCII \00:00:00, in the PM\ 32 007150 040 074 131 MYESNO: .ASCII \ [No] ? \<200> 33 007172 015 012 124 MWCPD: .ASCII \The system date is \ 34 007217 056 056 055 MWCPDD: .ASCIZ \..-...-... \ 35 007233 015 012 011 MTELL: .ASCII \Please tell me the \<200> 36 007262 040 164 151 MIPTT: .ASCII \ time: \<200> 37 007272 144 141 171 MAFD: .ASCII \day [ \ 38 007300 056 056 040 MAFDD: .ASCII \.. ] : \<200> 39 007310 155 157 156 MAFM: .ASCII \month [\ 40 007317 056 056 056 MAFMM: .ASCII \.....] : \<200> 41 007331 171 145 141 MAFY: .ASCII \year [ \ 42 007340 056 056 040 MAFYY: .ASCII \.. ] : \<200> 43 007350 015 012 124 MITFN: .ASCII \Thank you, \ 44 007365 131 157 165 MIFMN: .ASCIZ \Your name here ....2.... ....3.... .. \ 45 007436 015 012 124 MITHNK: .ASCII \Thanks for the \<200> 46 007460 155 157 156 MITFM: .ASCII \month. \ 47 007467 055 056 056 MIFMM: .ASCIZ \-...-.\ 48 007476 144 141 171 MITFD: .ASCII \day. \ 49 007503 056 056 056 MIFMD: .ASCIZ \...\ 50 007507 171 145 141 MITFY: .ASCII \year. 19\ 51 007517 056 056 056 MIFMY: .ASCIZ \.....\ 52 007525 164 151 155 MITFT: .ASCII \time. \ 53 007533 056 056 056 MIFMT: .ASCIZ \.........\ 54 007545 124 150 141 MITAS: .ASCIZ \That's a short name.\ 55 007572 015 012 102 MITIA: .ASCIZ \Before we go on to other things,\ 56 007635 011 127 157 MIYUL: .ASCII \Would you like to change \<200> 57 007670 141 156 171 MIANY: .ASCII \anything\<200> DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 35-1 MESSAGES FOR QUESTION AND FOR ERRORS 58 007701 151 164 200 MIIT: .ASCII \it\<200> 59 007704 015 012 123 MIDNU: .ASCII \Sorry, I didn't understand that.\ 60 007746 015 012 040 .ASCII \ Please, just a "Y" for yes,\ 61 010004 040 157 162 .ASCIZ \ or an "N" for no, is good enough.\ 62 010047 015 012 123 MFAYF: .ASCIZ \Sorry, I can only accept years from 1973 to 2003.\ 63 010133 123 157 162 MFDJE: .ASCIZ \Sorry, I don't understand Julian dates.\ 64 010203 127 150 157 MFZNR: .ASCIZ \Who ever heard of zero as a date?\ 65 010245 111 040 143 MFNR: .ASCII \I cannot recognize that peculiar \<200> 66 010307 144 141 171 MFNRD: .ASCIZ \day.\ 67 010314 155 157 156 MFNRM: .ASCIZ \month.\ 68 010323 171 145 141 MFNRY: .ASCIZ \year.\ 69 010331 015 012 104 MILVN: .ASCII \DAYLOG Version 3.00 is public domain software for RT-11.\ 70 010423 015 012 104 .ASCIZ \DAYLOG was created by Gary F. Sallee.\ 71 .EVEN 72 ;Month table 73 010474 055 145 162 .ASCII \-err\ 74 010500 055 112 101 MONTHT: .ASCII \-JAN-FEB-MAR-APR-MAY-JUN-JUL-AUG-SEP-OCT-NOV-DEC-\ 75 .LIST BEX 76 .EVEN DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 36 MESSAGES FOR QUESTION AND FOR ERRORS 1 010562 BTABL0: 2 010562 011044' .WORD +DAYC>> 3 010564 011020' .WORD >> 4 010566 011022' .WORD +DAYC>> 5 010570 010307' .WORD MFNRD 6 010572 007272' .WORD MAFD 7 8 010574 BTABL1: 9 010574 011042' .WORD +MONTHC>> 10 010576 011026' .WORD >> 11 010600 011026' .WORD +MONTHC>> 12 010602 010314' .WORD MFNRM 13 010604 007310' .WORD MAFM 14 15 010606 BTABL2: 16 010606 011046' .WORD +YEARC>> 17 010610 011034' .WORD >> 18 010612 011040' .WORD +YEARC>> 19 010614 010323' .WORD MFNRY 20 010616 007331' .WORD MAFY 21 22 010620 BTABL3: 23 010620 001546' .WORD DATE4 24 010622 011046' .WORD +YEARC>> 25 010624 177740 .WORD 177740 26 010626 000037 .WORD 000037 27 010630 000002 .WORD 2 28 010632 011437' .WORD 29 010634 011042' .WORD > 30 010636 003772' .WORD PARNOS 31 010640 005632' .WORD D4YERR 32 010642 BTABL4: 33 010642 001546' .WORD DATE4 34 010644 011042' .WORD +MONTHC>> 35 010646 141777 .WORD 141777 36 010650 030000 .WORD 030000 37 010652 000003 .WORD 3 38 010654 011434' .WORD 39 010656 011042' .WORD > 40 010660 004504' .WORD PARALP 41 010662 005654' .WORD D4MERR 42 010664 BTABL5: 43 010664 001546' .WORD DATE4 44 010666 011044' .WORD +DAYC>> 45 010670 176037 .WORD 176037 46 010672 001710 .WORD 001710 47 010674 000002 .WORD 2 48 010676 011430' .WORD 49 010700 011050' .WORD > 50 010702 003772' .WORD PARNOS 51 010704 005676' .WORD D4DERR 52 010706 BTABL6: 53 010706 001702' .WORD DATE4A DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 37 SYSTEM COMMUNICATION BLOCKS 1 .SBTTL SYSTEM COMMUNICATION BLOCKS 2 010710 075250 LDBLK: .RAD50 \SY \ ;Dblock for DAYLOG log file 3 010712 014501 046537 .RAD50 \DAYLOG\ 4 010716 046537 .RAD50 \LOG\ 5 6 010720 000000 000000 011420' LAREA: .WORD 0,0,LBUF ;Function code: channel, block number, buffer location 7 010726 000400 000000 .WORD 400,0 ;Word count, code for READW or WRITEW is 0 8 010732 123 131 072 MBUF2: .ASCIZ \SY:DAYLOG.LOG\ ;Message file name 010735 104 101 131 010740 114 117 107 010743 056 114 117 010746 107 000 9 .EVEN 10 11 010750 000000 MAREA: .WORD 0 ; .BLKW 5 ;EMT arg block for message file 12 ;Device status word 3 13 14 010762' LRBLK = MAREA+12 ; .WORD 0 15 010764' DEVPTR = MAREA+14 ; .WORD 0 16 17 .SBTTL LOG BUFFER LOCATIONS 18 19 010766' CDATE1 = MAREA+16 ; .WORD 0 20 010770' CTICK1 = MAREA+20 ; .WORD 0,0 ;Clock ticks before disk access 21 010774' CTICK2 = MAREA+24 ; .WORD 0,0 ;Clock ticks after disk access 22 23 011000' PDNBUF = MAREA+30 ; .BLKW 10 ;Parse date number buffer 24 011020' PDNBUE = MAREA+50 25 26 011020' DATBUF = MAREA+50 ; .BLKW 100 ;Date assembly area buffer 27 011220' TTYBUF = MAREA+250 ; .BLKW 100 ;Console input buffer 28 29 011420' LBUF = MAREA+450 ; .BLKW 400 ;Data buffer for log files 30 31 000000' .END START DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page 37-1 Symbol table AC0 =%000000 CVYEAR 005272R MASKPM 007104R MITFN 007350R PDNBUF= 011000R AC1 =%000001 DATBUF= 011020R MBUF2 010732R MITFT 007525R PERIOD= 000056 AC2 =%000002 DATELD 005174R MENEM 005763R MITFY 007507R PM 003234R AC3 =%000003 DATE4 001546R MERCOI 006060R MITHNK 007436R PRTEXI 005730R AC4 =%000004 DATE4A 001702R MERFNF 006112R MITIA 007572R PTT 000656R AC5 =%000005 DATE4Y 001530R MERHNL 006132R MITIM 006665R RMONAP= 000054 AC6 =%000006 DAYC = 000002 MERIE 006005R MITLI 006603R R6 =%000006 AC7 =%000007 DA1ASK 001314R MEROE 006032R MITST 007045R R7 =%000007 ADD12 003256R DA1SEP 001404R MERROR 005750R MITY 006471R SALPHA 002520R AGAIN 000456R DEVPTR= 010764R MFAYF 010047R MIWIY 006554R SAVELO 005576R AM 003264R D4DERR 005676R MFDJE 010133R MIYUL 007635R SCCEXI 005732R AM12 003066R D4MERR 005654R MFD4 006216R MONTHC= 000000 SCTRL 002434R ASKDA 001066R D4YERR 005632R MFD4D 006303R MONTHT 010500R SEPCHR 002344R ASKPM 003102R EMTERB= 000052 MFD4M 006267R MOVEBY 005022R SNO 002460R ATSIGN= 000100 FF = 000014 MFD4Y 006254R MPMHR 007125R SNULL 002562R BIT01 = 000002 FILTRN 000150R MFNR 010245R MTELL 007233R SPACE = 000040 BTABL0 010562R HT = 000011 MFNRD 010307R MTER 006763R SPP 002540R BTABL1 010574R LAREA 010720R MFNRM 010314R MULTIM 003662R SSP 002500R BTABL2 010606R LBUF = 011420R MFNRY 010323R MUL45 003734R STACK = 001000 G BTABL3 010620R LBYTE = 000400 MFSCC 006156R MWCNR 006315R START 000000R BTABL4 010642R LCR = 000076 MFZNR 010203R MWCPD 007172R STROFF= 000006 BTABL5 010664R LDATE = 000006 MIANY 007670R MWCPDD 007217R SUB24H 003414R BTABL6 010706R LDBLK 010710R MIAYA 006520R MYESNO 007150R SUB60M 003442R BTO1AS 005306R LF = 000012 MIDAT 006676R NEMERR 005720R SUB60S 003452R BTO2AS 005324R LFNAM = 000031 MIDNU 007704R NMBR03= 000003 SYSGEN= 000372 CDATE1= 010766R LLNAM = 000055 MIFMD 007503R NMBR05= 000005 TERROR 003542R CHAN01= 000001 LMI = 000053 MIFMM 007467R NMBR06= 000006 TNSTR 002576R CHAN02= 000002 LOGDAT 001752R MIFMN 007365R NO 004764R TRANSF 005500R CLCKHZ 005370R LOGTIM 003570R MIFMT 007533R NOBUF 002700R TSTSTR 004774R CLCKLD 005360R LRBLK = 010762R MIFMY 007517R NONO 002722R TTYBIN 002176R CLCK50= 000062 LRECL = 000100 MIIT 007701R NULL = 000000 TTYBUF= 011220R CLCK60= 000074 LRECN = 000000 MILLW 006632R N037 = 000037 TTYCNT 002202R CLK50$= 000040 LTIME = 000020 MILVN 010331R N060 = 000060 TTYIN 002236R COLON = 000072 MAFD 007272R MINAM 006713R N072 = 000072 YEARC = 000004 CONFIG= 000300 MAFDD 007300R MINUS1= 177777 N074 = 000074 YEAR72= 000110 CR = 000015 MAFM 007310R MIPTT 007262R OPENCH 005032R YES 004767R CTICK1= 010770R MAFMM 007317R MISTC 007072R PARALP 004504R YESNO 004664R CTICK2= 010774R MAFY 007331R MITAS 007545R PARNOS 003772R YR2000 004002R CTRLH = 000010 MAFYY 007340R MITFD 007476R PARTIM 002670R ...V1 = 000003 CVDAY 005212R MAREA 010750R MITFM 007460R PDNBUE= 011020R ...V2 = 000027 CVMNTH 005240R . ABS. 001000 000 (RW,I,GBL,ABS,OVR) 010752 001 (RW,I,LCL,REL,CON) Errors detected: 0 *** Assembler statistics Work file reads: 0 Work file writes: 0 Size of work file: 10531 Words ( 42 Pages) Size of core pool: 18176 Words ( 71 Pages) Operating system: RT-11 Elapsed time: 00:01:14.09 DK:DAY,DK:DAY,DK:DAY.CRF=DK:DAY/C DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page S-1 Cross reference table (CREF V05.01) ...V1 7-4 7-25 8-14 8-20 8-23 8-29 9-34 10-4 10-17 10-26 10-35 10-36 10-37 11-3 11-13 11-14 11-15 11-29 11-30 12-37 12-38 12-39 13-11 13-12 13-14 13-15 15-13 15-37 15-38 15-40 15-41 15-42 15-51 15-54 15-57 15-57 21-23 23-14 23-23 23-24 23-25 23-29 23-38 23-39 25-107 25-108 25-126 25-127 25-131 25-133 25-145 26-48 26-49 27-20 29-19 29-22 29-23 29-26 29-26 29-30 29-31 29-33 29-34 29-35 33-5 33-5 33-10 33-11 33-15 33-16 33-21 33-21 34-3 34-4 34-5 34-6 34-7 34-8 34-9 34-11 34-12 34-13 34-13 ...V2 15-57 15-57# 29-26 29-26 29-26# 29-26# 33-5 33-5 33-5# 33-5# 33-21 33-21 33-21# 33-21# 34-13 34-13# AC0 4-2# AC1 4-3# AC2 4-4# AC3 4-5# AC4 4-6# AC5 4-7# AC6 4-8# AC7 4-9# ADD12 20-66 21-35 21-39# AGAIN 10-4# 15-60 AM 20-67 21-10 21-13 21-34 21-37 22-2# 22-49 22-51 22-53 AM12 20-39 20-41 20-65# 21-31 ASKDA 11-27 12-4# ASKPM 20-56 20-60 20-62 21-3# ATSIGN 5-17# BIT01 6-10# BTABL0 13-4 13-9 13-12 13-15 13-31 13-37 13-41 13-43 13-45* 13-50 13-52 13-53 14-7 14-8 14-11 14-13 14-16* 14-20 14-22 14-27 14-28 14-29 14-32 14-39 14-40 36-1# BTABL1 13-9 13-52 13-53 36-8# BTABL2 36-15# BTABL3 14-7 14-38 36-22# BTABL4 14-38 36-32# BTABL5 14-22 14-32 36-42# BTABL6 36-52# BTO1AS 30-26 31-7# BTO2AS 31-15# 32-20 CDATE1 12-12* 12-49 14-6* 14-10 15-10* 15-13 23-13* 23-14 37-19# CHAN01 6-7# CHAN02 6-8# 7-32 15-57 15-57 33-5 33-5 33-21 33-21 34-13 34-13 CLCK50 5-30# 7-24 CLCK60 5-31# 7-21 7-24 32-17 CLCKHZ 7-21* 7-24* 8-8 23-8 32-12# CLCKLD 11-6 23-32 32-2# CLK50$ 6-11# 7-22 COLON 5-15# CONFIG 6-4# 7-18 CR 5-13# 35-16 35-17 35-19 35-21 35-22 35-23 35-27 35-28 35-30 35-33 35-35 35-43 35-45 35-55 35-59 35-60 35-62 35-69 35-70 CTICK1 8-14 8-16 8-18 8-23 8-24 8-26 9-4 9-6 11-3 11-5 15-12* 23-11* 23-12* 23-29 23-31 37-20# CTICK2 7-25 8-16 8-18 8-24 8-26 37-21# CTRLH 5-9# CVDAY 25-106 30-14 30-19# CVMNTH 26-47 30-15 30-30# CVYEAR 25-125 30-16 31-2# D4DERR 34-7# 36-51 D4MERR 34-5# 36-41 D4YERR 34-3# 36-31 DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page S-2 Cross reference table (CREF V05.01) DA1ASK 12-45 13-3# 13-54 DA1SEP 12-47 13-8 13-10 13-20# 13-28 13-44 DATBUF 12-6 14-34 14-36* 15-4 15-6 25-102* 25-121* 26-43* 36-2 36-3 36-4 36-9 36-10 36-11 36-16 36-17 36-18 36-24 36-29 36-34 36-39 36-44 36-49 37-26# DATE4 14-8# 36-23 36-33 36-43 DATE4A 15-4# 36-53 DATE4Y 12-52 14-4# DATELD 12-15 15-19 30-2# DAYC 6-23# 14-34 14-36* 25-85 25-93 25-102* 36-2 36-4 36-44 DEVPTR 7-30* 29-35 37-15# EMTERB 6-1# 29-28 FF 5-12# FILTRN 7-33 8-3# HT 5-10# 35-20 35-21 35-30 35-35 35-56 LAREA 33-5 33-21 37-6# LBUF 7-10 9-11 9-21 9-25 9-29 10-12 10-19 10-22 10-32 11-8 12-14 12-17 12-22 12-27 12-32 14-24 15-18 15-25 15-29 15-33 23-30 23-36 36-28 36-38 36-48 37-6 37-29# LBYTE 6-3# 31-19 31-21 LCR 6-20# LDATE 6-15# 9-25 12-14 12-17 12-22 12-27 12-32 14-24 15-18 15-29 36-28 36-38 36-48 LDBLK 7-29 37-2# LF 5-11# 17-21 35-16 35-17 35-19 35-21 35-22 35-23 35-27 35-28 35-30 35-33 35-35 35-43 35-45 35-55 35-59 35-60 35-62 35-69 35-70 LFNAM 6-17# 9-29 10-12 10-19 10-22 10-32 15-33 LLNAM 6-19# LMI 6-18# LOGDAT 12-51 15-15# LOGTIM 11-26 23-16 23-29# LRBLK 8-4* 33-4* 33-5 33-20* 33-21 37-14# LRECL 6-13# LRECN 6-14# LTIME 6-16# 9-11 9-21 11-8 15-25 23-30 23-36 MAFD 35-37# 36-6 MAFDD 12-23 35-38# MAFM 35-39# 36-13 MAFMM 12-28 35-40# MAFY 35-41# 36-20 MAFYY 12-33 35-42# MAREA 7-4 7-5 7-9 7-25 8-14 8-23 11-3 15-13 23-14 23-29 29-19 29-20 29-26 37-11# 37-14 37-15 37-19 37-20 37-21 37-23 37-24 37-26 37-27 37-29 MASKPM 21-23 35-30# MBUF2 7-30 33-12 37-8# MENEM 34-9 35-5# MERCOI 29-31 35-8# MERFNF 29-34 35-9# MERHNL 29-23 35-10# MERIE 33-11 35-6# MEROE 33-16 35-7# MERROR 23-23 29-22 29-30 29-33 33-10 33-15 34-4 34-6 34-8 35-3# MFAYF 25-133 35-62# MFD4 34-3 34-5 34-7 35-12# MFD4D 34-8 35-15# MFD4M 34-6 35-14# MFD4Y 34-4 35-13# MFDJE 25-145 35-63# MFNR 13-11 35-65# DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page S-3 Cross reference table (CREF V05.01) MFNRD 35-66# 36-5 MFNRM 35-67# 36-12 MFNRY 35-68# 36-19 MFSCC 34-12 35-11# MFZNR 25-131 35-64# MIANY 15-42 35-57# MIAYA 10-4 35-20# MIDAT 9-26 15-30 35-25# MIDNU 15-54 35-59# MIFMD 25-105 35-49# MIFMM 26-46 35-47# MIFMN 10-23 35-44# MIFMT 23-35 35-53# MIFMY 25-124 35-51# MIIT 10-37 11-15 12-39 35-58# MILLW 9-34 35-23# MILVN 15-51 35-69# MINAM 9-30 15-34 35-26# MINUS1 5-19# 32-13 MIPTT 11-30 35-36# MISTC 11-4 11-7 11-12* 35-29# MITAS 10-35 35-54# MITFD 25-108 35-48# MITFM 26-49 35-46# MITFN 10-26 35-43# MITFT 23-39 35-52# MITFY 25-127 35-50# MITHNK 23-38 25-107 25-126 26-48 35-45# MITIA 15-40 35-55# MITIM 9-22 15-26 15-38 35-24# MITLI 15-37 35-22# MITST 11-13 35-28# MITY 8-29 35-19# MIWIY 10-17 35-21# MIYUL 10-36 11-14 12-38 15-41 35-56# MONTHC 6-22# 25-93 26-43* 36-9 36-11 36-34 MONTHT 26-25 30-34 35-74# MOVEBY 9-12 9-24 9-28 9-32 10-14 10-25 11-10 12-20 12-25 12-30 12-35 15-28 15-32 15-36 23-37 29-3# MPMHR 21-16 21-20 35-31# MTELL 11-29 13-14 35-35# MTER 23-24 35-27# MUL45 24-30# 25-65 26-24 26-42 MULTIM 22-42 23-9 24-3# MWCNR 8-20 35-16# MWCPD 12-37 35-33# MWCPDD 12-18 35-34# MYESNO 27-20 35-32# N037 5-21# 30-25 31-4 32-29 N060 5-22# 31-24 N072 5-23# 32-23 N074 5-24# 30-33 NEMERR 7-7 34-9# NMBR03 5-27# 32-14 NMBR05 5-28# 30-35 NMBR06 5-29# DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page S-4 Cross reference table (CREF V05.01) NO 27-23 27-49# NOBUF 20-18# 20-57 NONO 20-25# 20-55 20-58 21-5 NULL 5-20# 10-32 OPENCH 7-31 29-13# PARALP 13-32 26-2# 36-40 PARNOS 13-38 25-3# 36-30 36-50 PARTIM 9-17 11-36 20-3# PDNBUE 25-53 25-59 37-24# PDNBUF 25-45 37-23# PERIOD 5-16# PM 20-63 21-29 21-32# PRTEXI 33-13 34-4 34-6 34-8 34-11# PTT 11-3# 11-37 R6 4-16# R7 4-18# RMONAP 6-2# 7-17 SALPHA 18-31 18-35 18-67# SAVELO 15-23 33-19# SCCEXI 7-35 34-12# SCTRL 18-41 18-44# SEPCHR 13-21 18-3# 20-28 SNO 18-39 18-53# SNULL 18-27 18-42 18-84# SPACE 5-14# 14-24 17-23 17-26 17-41 18-40 31-12 SPP 18-75# 18-77 18-79 SSP 18-29 18-33 18-37 18-60# STACK 5-6 5-7# START 7-3# 37-31 STROFF 6-25# 14-34 14-36* 15-4 15-6 25-102* 25-121* 26-43* 36-2 36-3 36-4 36-9 36-10 36-11 36-16 36-17 36-18 36-24 36-29 36-34 36-39 36-44 36-49 SUB24H 22-12 22-15 22-45# SUB60M 22-17 22-50# SUB60S 22-19 22-52# SYSGEN 6-5# TERROR 20-53 23-23# TNSTR 19-3# 20-59 TRANSF 8-5 33-3# TSTSTR 27-26 27-33 28-2# TTYBIN 10-20 11-33 13-18 16-3# 21-26 27-22 TTYBUF 9-10 9-16 10-13 11-22 11-24 11-32 11-35 12-46 13-17 13-19 13-48 15-49 20-16 20-65 21-9 21-12 21-15 21-25 21-27* 21-28 21-30 21-33 21-36 21-39* 22-11 22-14 22-16 22-18 22-21 22-45* 22-46 22-48* 22-50* 22-52* 23-25 27-21 37-27# TTYCNT 16-14# 16-21 TTYIN 16-23 17-3# YEAR72 5-32# 31-5 YEARC 6-24# 25-121* 36-16 36-18 36-24 YES 27-30 27-50# YESNO 10-7 10-39 11-18 12-43 15-45 27-3# YR2000 25-21# 25-43* 25-72 DAYLOG GARY F. SALLEE VERSION 3 MACRO V05.01b Sunday 15-Dec-85 17:13 Page M-1 Cross reference table (CREF V05.01) ...CM0 29-19 ...CM1 29-26 33-5 33-21 ...CM2 7-25 8-14 8-23 11-3 15-13 23-14 23-29 29-26 29-26 33-5 33-5 33-5 33-5 33-21 33-21 33-21 33-21 ...CM3 15-57 34-13 ...CM5 7-4 7-25 8-14 8-20 8-23 8-29 9-34 10-4 10-17 10-26 10-35 10-36 10-37 11-3 11-13 11-14 11-15 11-29 11-30 12-37 12-38 12-39 13-11 13-12 13-14 13-15 15-13 15-37 15-38 15-40 15-41 15-42 15-51 15-54 21-23 23-14 23-23 23-24 23-25 23-29 23-38 23-39 25-107 25-108 25-126 25-127 25-131 25-133 25-145 26-48 26-49 27-20 29-19 29-22 29-23 29-26 29-30 29-31 29-33 29-34 29-35 33-5 33-10 33-11 33-15 33-16 33-21 34-3 34-4 34-5 34-6 34-7 34-8 34-9 34-11 34-12 ...CM6 7-25 8-14 8-23 11-3 15-13 23-14 23-29 ...CM7 33-5 33-21 .CLOSE 2-4# 15-57 34-13 .DATE 2-5# 12-11 14-5 15-15 .DSTAT 2-4# 29-19 .EXIT 2-3# 15-58 34-14 .GTIM 2-5# 7-25 8-14 8-23 11-3 23-29 .LOOKU 2-3# 29-26 .PRINT 2-3# 8-20 8-29 9-34 10-4 10-17 10-26 10-35 10-36 10-37 11-13 11-14 11-15 11-29 11-30 12-37 12-38 12-39 13-11 13-12 13-14 13-15 15-37 15-38 15-40 15-41 15-42 15-51 15-54 21-23 23-23 23-24 23-25 23-38 23-39 25-107 25-108 25-126 25-127 25-131 25-133 25-145 26-48 26-49 27-20 29-22 29-23 29-30 29-31 29-33 29-34 29-35 33-10 33-11 33-15 33-16 34-3 34-4 34-5 34-6 34-7 34-8 34-9 34-11 34-12 .READW 2-4# 33-5 .SDTTM 2-5# 15-13 23-14 .SETTO 2-3# 7-4 .TTINR 2-5# .TTYIN 2-5# 17-18 .WRITW 2-4# 33-21 MLR0BR 3-11# 34-4 34-6 34-8 MLR0JM 3-27# PERROJ 3-22# PERROR 3-6# 34-4 34-6 34-8