.title k11dsp dispatch to correct terminal i/o for RT11, PRO/RT,TSX .ident /2.24/ .include /IN:K11MAC.MAC/ ; 08-Nov-84 16:16:40 Brian Nelson ; ; Collect K11PRT, K11RTT and K11TSX into separete overlays in ; the same region (either disk or virtual). Dispatch to the ; correct one based on (1) the exectype flag set at program ; entry in XINIT, or (2) force PRO/350 mode if the device is ; X?: (checked in ASSDEV below). While the cost in address ; space is a bit to create overlay table entries for all of ; the ept's in each module is about 300 words, doing so will ; save me the need to create multiple save images every time ; I change Kermit-11. Additionally, one save image for all ; systems sounds like a nice idea to me. dispatch: tst proflg ; is this a pro/350 today? bne pro ; yes tst tsxflg ; is this tsx/tsx+ bne tsx jsr pc ,@(r0) ; no, it plain old RT11. Use return ; multiple terminal service for i/o pro: tst (r0)+ ; pro/rt11, do the right thing jsr pc ,@(r0) ; simple return tsx: cmp (r0)+ ,(r0)+ ; tsx jsr pc ,@(r0) ; call the routine return ; and exit ttysav:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttysav .word x.ttysav .word t.ttysav ttyrst:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttyrst .word x.ttyrst .word t.ttyrst deadev:: mov #200$ ,r0 jmp dispatch 200$: .word m.deadev .word x.deadev .word t.deadev assdev::mov @r5 ,r0 ; get the first character of the name cmpb @r0 ,#'0 ; if a digit, then insure proflag is blo 5$ ; is turned off (in case this is a cmpb @r0 ,#'9 ; normal 11 with MT and XL service. bhi 5$ ; not a mt line setting clr proflg ; turn off the XC/XL flag please 5$: cmpb @r0 ,#'C&137 ; /44/ CLn: and TSX+? beq 6$ ; /44/ Yes cmpb @r0 ,#'X&137 ; if XC or XL, then treat as a PRO/350 bne 10$ ; no 6$: tst tsxflg ; are we tsx? beq 7$ ; no mov sp ,tsxcl ; and set tsx and cl mode 7$: clr tsxflg ; shut off tsx mode, enable PRO mov sp ,proflg ; simple to do br 100$ ; and dispatch to the correct thing 10$: cmpb @r0 ,#'T&137 ; /39/ SET LIN TT: ? bne 30$ ; /39/ no clr proflg ; /39/ yes, for RT11 use console then tst tsxflg ; /39/ already been here or real TSX+ bne 20$ ; /39/ yes, leave things alone then mov #-1 ,tsxflg ; /39/ flag to use TSX tt handling cmpb parity ,#PAR$NONE ; /39/ no parity? beq 15$ ; /39/ yes, fake space parity then tstb parity ; /39/ parity already set up? bne 20$ ; /39/ yes 15$: mov #PAR$SPACE,parity ; /39/ need 8bit quoting also 20$: movb #60. ,setrec+p.spsiz ; /39/ console port won't do XON/XOFF movb #60. ,setsen+p.spsiz ; /39/ fast enough to avoid data loss movb #60. ,senpar+p.spsiz ; /43/ Here for safety. 30$: 100$: mov #200$ ,r0 jmp dispatch 200$: .word m.assdev .word x.assdev .word t.assdev ttyini:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttyini .word x.ttyini .word t.ttyini ttyfin:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttyfin .word x.ttyfin .word t.ttyfin contrp:: mov #200$ ,r0 jmp dispatch 200$: .word m.contrp .word x.contrp .word t.contrp conrst:: mov #200$ ,r0 jmp dispatch 200$: .word m.conrst .word x.conrst .word t.conrst xbinre:: mov #200$ ,r0 jmp dispatch 200$: .word m.xbinre .word x.xbinre .word t.xbinre pakrea:: binrea:: mov #200$ ,r0 jmp dispatch 200$: .word m.binrea .word x.binrea .word t.binrea pakwri:: binwri:: mov #200$ ,r0 jmp dispatch 200$: .word m.binwri .word x.binwri .word t.binwri cantyp:: mov #200$ ,r0 jmp dispatch 200$: .word m.cantyp .word x.cantyp .word t.cantyp ttxon:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttxon .word x.ttxon .word t.ttxon senbrk:: mov #200$ ,r0 jmp dispatch 200$: .word m.senbrk .word x.senbrk .word t.senbrk ttpars:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttpars .word x.ttpars .word t.ttpars gttnam:: mov #200$ ,r0 jmp dispatch 200$: .word m.gttnam .word x.gttnam .word t.gttnam setspd:: mov #200$ ,r0 jmp dispatch 200$: .word m.setspd .word x.setspd .word t.setspd chkabo:: mov #200$ ,r0 jmp dispatch 200$: .word m.chkabo .word x.chkabo .word t.chkabo ttspee:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttspee .word x.ttspee .word t.ttspee ttyset:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttset .word x.ttset .word t.ttset ttrfin:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttrfin .word x.ttrfin .word t.ttrfin ttrini:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttrini .word x.ttrini .word t.ttrini finrt:: mov #200$ ,r0 ; /37/ clean up lines jmp dispatch ; /37/ 200$: .word m.finrt ; /37/ .word x.finrt ; /37/ .word t.finrt ; /37/ ttydtr:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttydtr .word x.ttydtr .word t.ttydtr ttyhan:: mov #200$ ,r0 jmp dispatch 200$: .word m.ttyhan .word x.ttyhan .word t.ttyhan kbread:: mov #200$ ,r0 jmp dispatch 200$: .word m.kbread .word x.kbread .word t.kbread tidias:: tidiar::return rstsrv::clr r0 return inqdtr::mov #-1 ,r0 return .end