.title auxmes ; ; routines used to let ecr periodically go to top of screen and ; wait for any messages from send, postman, etc ; ; F. borger May 28, 1986 ; .mcall qiow$,clef$,mrkt$,wtse$,dir$ .psect rwdata,rw,d,lcl,rel,con ; ; DPB to set/clear nomessages characteristic ; ;clrflg::.word 0 ;flag for top 2 lines cleared domess: qiow$ sf.smc,tolun,toefn,,tiosb,, ; Clear/set wrap. messbf: .byte tc.img ; clear/set nomessages mode messch: .byte 0 ; no-messages mode (0/1 = off/on). messln = .-messbf ; Size of set options. ; ; QIO dpbs to move cursor to top and back down again ; ;HOMCUR::QIOW$ IO.WLB!TF.WAL,TOLUN,TOEFN,,TIOSB,, ;HOMONL::QIOW$ IO.WLB!TF.WAL,TOLUN,TOEFN,,TIOSB,, ;BOTCUR::QIOW$ IO.WLB!TF.WAL,TOLUN,TOEFN,,TIOSB,, ; ; DPB's for mark time use ; ;CLEF1S::CLEF$ TOEFN ;MARK1S::MRKT$ TOEFN,1,2 ;WAIT1S::WTSE$ TOEFN ; ; Buffers for above directives: ; ;HOMMES::.ascii <33>/[3;80H/<33>/[1J/ ; erase top 3 lines of screen for mess ;HOONLY::.ASCII <33>/[1;1H/ ; then Home cursor ; HOMLEN=.-HOMMES ; ONLYLN=.-HOONLY ;BOTMES::.ASCII <33>/[24;6H/<33>/[0K/ ; Put cursor back after prompt & erase ; BOTLEN=.-BOTMES ; .EVEN ut.ac=20 ;define terminal activities byte .psect code,ro,i,lcl,rel,con .SBTTL okmess enable messages ;+ ; ; OKMESS - ; ; This routine enables messages by clearing the tc.img characteristic ; ; Inputs: ; None. ; ; Outputs: ; All registers are preserved. ; ;- okmess:: clrb messch ; clear nomessages mode dir$ #domess ; Turn the characteristic off. call chkerr ; Check/report any errors. 100$: return ; ; .SBTTL nomess disables messages ;+ ; ; NOMESS - ; ; This routine disables messages by setting the tc.img characteristic ; ; Inputs: ; None. ; ; Outputs: ; All registers are preserved. ; ;- nomess:: movb #1,messch ; set nomessages mode dir$ #domess ; Turn the characteristic on call chkerr ; Check/report any errors. 100$: return .sbttl getmes ; ; sub to move cursor to top of screen, detach and enable messages, ; wait one second, then re-attach, disable messages, and go back to ; bottom for more info ; ; ;getmes:: ; mov r0,-(sp) ;save reg ; mov .crtsk,r0 ;get my atl ; mov a.ti(r0),r0 ;now have pud pointer ; ;set activity bit in privileges byte ; bisb #ut.ac,u.pr(r0) ;for automatic log-out option ; mov (sp)+,r0 ;restore it ; tst clrflg ;should we clear three lines ? ; beq 1$ ;yes, clear them ; dir$ #homonl ;put cursor home ; br 2$ ;1$: dir$ #homcur ; put cursor home & clear 3 lines ;2$: call okmess ; enable messages ; dir$ #DETACH ; Detach for possible messages ; dir$ #CLEF1S ; Clear previous flag ; dir$ #MARK1S ; Mark time for 1 second ; dir$ #WAIT1S ; Wait for it ; dir$ #ATTACH ; Re-attach terminal ; call nomess ; disable messages ; dir$ #BOTCUR ; Put cursor at bottom after prompt ; return .end