.TITLE UCLFUN .IDENT /V01.00F/ .ENABL LC ; ;Orginial Author: Ray Carpenter, Shell Research Ltd. 1983 ;Modified: B. Kup, TH Darmstadt, 1984 ; .SBTTL Macros, Globals and Definitions ; .MCALL .PRINT,.EXIT,.GTIM ; CMDLEN = 510 CMDBUF = 512 JSW = 44 CHAIN$= 400 MX.LEN = 38. .SBTTL Code ; .PSECT $CODE ; $UCL: BIT #CHAIN$,@#JSW ;have we been chained to? BNE UCL1 .PRINT #IDMSG ;say 'hello' BR UCLEXT ; UCL1: CMP @#CMDLEN,#MX.LEN ;Check if command length < 46(8) BGT UCL2 ; ; Print: ?UCL-E-The command 'xxxx' has no meaning here ; .PRINT #ERMSG1 MOV #CMDBUF,R0 ;point behind end of command string ADD @#CMDLEN,R0 MOVB #200,-(R0) ;replace last char NUL by EOL <200> .PRINT #CMDBUF ;repeat command .PRINT #ERMSG2 ;'has no meaning here' BR UCLEXT UCL2: .GTIM #AREA,#TIME MOV TIME+2,R1 ;get ticks BIC #^C<16>,R1 ;mask range 0,2,..,16 (8 messages) .PRINT TABLE(R1) ;to index into the message table ; UCLEXT: .EXIT .SBTTL Data areas ; .PSECT $DATA ; AREA: .BLKW 10 ;EMT arg blk TIME: .WORD 0,0 ; TABLE: .WORD MSG2, MSG3, MSG4, MSG5, MSG6, MSG7, MSG8, MSG9 IDMSG: .ASCIZ /UCL V01.00F/ ERMSG1: .ASCII /?UCL-F-Kommando '/<200> ERMSG2: .ASCIZ /' unverstaendlich'/ MSG2: .ASCIZ /So viel getippt... und noch dazu falsch!/ MSG3: .ASCIZ /Versuch's nochmal!/ MSG4: .ASCIZ /Mist... wieder falsch!/ MSG5: .ASCIZ /?UCL-F-Wie bitte?/ MSG6: .ASCIZ /?UCL-F-Fehler/ MSG7: .ASCIZ /Was soll das bedeuten?/ MSG8: .ASCIZ /Leider voellig unverstaendlich!/ MSG9: .ASCIZ /?UCL-F-Kommando wiederholen/ .END $UCL