..$rec::.ascii <000>/REC/ ; RECEIVE ..$rem::.ascii <000>/REM/ ; REMOTE ..$ren::.ascii <000>/REN/ ; RENAME ..$sen::.ascii <000>/SEN/ ; SEND ..$ser::.ascii <000>/SER/ ; SERVER ..$set::.ascii <000>/SET/ ; SET ..$sho::.ascii <000>/SHO/ ; SHOW ..$spa::.ascii <000>/SPA/ ; SPACE ..$sys::.ascii <000>/SYS/ ; SYSTEM ..$tak::.ascii <000>/TAK/ ; TAKE ..$tra::.ascii <000>/TRA/ ; TRANSMIT ..$typ::.ascii <000>/TYP/ ; TYPE ..$who::.ascii <000>/WHO/ ; WHO slowgr::.word 2 ; cutoff for group numbers slowdo::.word 0 ; if <> 0, then slow xfers down slowbd::.word 1200. throtl::save >>>>> DB1:K11M41.MAC[2,2] <<<<< fu$def::.word 0 ; if rms needs the DNA filled in xinit:: call getsys ; rsx or m+ xk$dev::.asciz /XK0:/ xk$spd::.word 9600. setcc:: qiow$s #io.det,#lun.tt,#ef.tt,,#kbiost ttyini::save ttyfin:: ; no more abort handling ttrini:: ttrfin:: ttysav:: ttyset:: ttyrst:: noecho:: echo:: gttnam::save ; save temps please kbread:: binrea::tstb handch ; doing ibm style xon handshaking BDN binwri:: xbinre::save ; save a register for a friend chkabo::calls xbinrea ,<#lun.tt,#-1> ; simple read on console terminal l$ttyo:: sttyou:: l$pcrl:: logout:: exit:: quochk:: dskuse:: cantyp:: ttxon:: save ; use r0 to point into xrb getuic:: drpprv:: getprv:: suspen:: ttypar:: chkpar::clr r0 ttyhan::save ttydtr:: ttspee:: setspd::save setsla::save ; save temps we may want ttpars:: ; NEEDS TO BE GLOBAL(RBD) assdev::tst proflg namcvt:: ascdat::save asctim::save sercmd:: systat:: dodir:: runjob:: runmcr:: rsxsys:: qspool::movb #1 ,r0 ;rsxspl::mov r0 ,-(sp) ; save temps detach::qiow$s #io.det,#5,#ef.tt,,#kbiost syserp:: syserr:: >>>>> DB1:K11PK .MAC[2,2] <<<<< runjob::mov r5 ,-(sp) ; convert f4/bp2 call format $runjo::clr -(sp) $pklog:: >>>>> DB1:K11RMS.MAC[2,2] <<<<< sydisk::.ascii /SY:/ fablst::.word 0 ,fab1 ,fab2 ,fab3 ,fab4 namlst::.word 0 ,nam1 ,nam2 ,nam3 ,nam4 namlen::.word 0 ,0 ,0 ,0 ,0 rablst::.word 0 ,rab1 ,rab2 ,rab3 ,rab4 df$rat::.word fb$cr df$rfm::.word fb$var open:: calls fopen ,<@r5,2(r5),4(r5),#0> create::calls fcreate ,<@r5,2(r5),4(r5),#0> fopen:: save ; save registers fcreat::save ; save registers settyp::mov fablst(r0),r1 close:: save ; save registers we may have rewind::mov @r5 ,r0 binfil::save ; save registers we may use getsiz::mov @r5 ,r1 ; return error in r0, size in r1 getatr::save ; save these please putatr::save ; save these please getrec::mov 2(r5) ,r0 ; get the channel number putrec::mov r1 ,-(sp) getc:: mov @r5 ,r0 getcr0::save ; save temps putc:: save ; simply save r1 and call putcr0 putcr0::save ; save registers we use fu$dir::.word 0 ; style wildcarding on your non-standard lookup::save RNFAB1::FAB$B ; Old file name RNNAM1::NAM$B ; NAM definition RNFAB2::FAB$B ; New file name RNNAM2::NAM$B ; NAM definition rename::save ; save temps please delete::save ; save registers we may overwrite fparse::save ; save registers we may overwrite tsksiz::sub #40 ,sp ; use the stack for a buffer getsys::sub #40 ,sp ; use the stack for a buffer GSABAS:: ; GSA base address GSAMIN:: ; Minimum allocation GSAREQ:: ; Size of this request GSA:: getmcr::save ; just for kicks, save these >>>>> DB1:K11RTC.MAC[2,2] <<<<< doconn::tstb ttname ; insure that a device name is set dorsx:: return >>>>> DB1:K11SER.MAC[2,2] <<<<< server::mov remote ,-(sp) ; save the local/remote flag remfin::clr paknum ; packetnumber := 0 rembye::clr paknum ; packetnumber := 0 remget::call seropn ; get the link line intialzied remhos::call seropn ; get the link line intialzied remspa::calls doremo ,<#'U,#1,#null> remdir::calls doremo ,<#'D,#1,@r5> K11GLDXRF[.050032]K11GLD.XRF[.050032]    X14|H [4;Ik(&'( k ߫H&P` \RrPP2PPzPP{PPPPP2P~\$\\TD 0D \~ hi) +\ ^( n ^( np\^txY\^ˀ\!kVk<\F˰<˴ˬ\VVkˤ1`@lP ABCDEFGHIJKLMNOPQRSTUVWXYZ$.?0123456789<@<SЬTЬ UQS>?\\\\\\\\\`:#@'="\abcdefghi\\\\\\\jklmnopqr\\\\\\\~stuvwxyz\\\\\\\\\\\\\\\\\\\\\\{ABCDEFGHI\\\\\\}JKLMNOPQR\\\\\\\\STUVWXYZ\\\\\\0123456789\\\\\  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~@ggh<i|o<m<4p<p<k|Zn<l fr rwx<x<x<x޺<w@]@@fjnr]Ze@@|> | |v<H|  |  |xz|  |zt f r   < &^ @&@'*/V,"?Lh:hmBmz|z{x`y~|fN|@@|@͂|@ ݃ƃ<ns<|Ŏ |️|ep|u|-@率|<ᄇ2ֻr||ZRM | ntB|xyvZw|J=|R>|J? nnaa|bddfhe connect command for RSX tists:: .blkw 2 ; for the connect command for RSX mcrcmd::.blkw 1 ; if <>, then we got a mcr/ccl cmd line binmod::.blkw 1 ; for RSTS, something is open mode 1 sy.ini::.blkw 1 ; for KERMIT.INI stuff handch::.blkw 1 ; for ibm systems ? duplex::.blkw 1 ; if eq, full (default), else half sparsz::.blkw 1 ; size of our sinit packet chksiz::.blkw 1 ; current checksum size in bytes chktyp::.blkw 1 ; the current checksum type maxtry::.blkw 1 ; maximum number of retries conesc::.blkw 1 ; escape character for connection sertim::.blkw 1 ; timeout waiting for server cmd inserv::.blkw 1 ; currently we are a server ranerr::.blkw 1 ; generate random checksum errors if ne seed:: testc:: .blkw 1 ; for debugging skipfl::.blkw 1 ; should we send a EOF DISCARD packet parity::.blkw 1 ; save parity setting for SHOW command logfil::.blkb 40 ; a log filename for the SHOW command cccnt:: .blkw 1 ; number of control C's so far doauto::.blkw 1 ; if <>, then do auto binary (default) sendat::.blkw 1 ; if zero, NEVER send attribute packets sendly::.blkw 1 ; wait before sending SINIT pauset::.blkw 1 ; wait before sending a packet oldpau::.blkw 1 ; save the old time for pausing defdir::.blkb filsiz+2 ; default directory for send and rec ttcnpa:: ttparm::.blkb 50 ; saved terminal settings ttnapa::.blkb 50 outlun::.blkw 1 ; zero for TI else lun.ou cmdlun::.blkw 1 ; current command file lun cmdadr::.blkw 1 ; saved address of command routine cmdnum::.blkw 1 ; index into the current command list hlpbuf:: cmdbuf::.blkb 120 ; 80 byte buffer for reading commands argbuf::.blkb 120 ; also for reading args for commands hlptop:: srcnam::.blkb filsiz+2 ; original send filespec filnam::.blkb filsiz+2 ; output from directory lookup routine index:: .word 0 ; index into directory recpkt::.blkb 210 ; 128 byte buffer receive packet buffer packet::.blkb 210 ; a general packet ttname::.blkb 20 ; our current terminal link name ttdial::.blkb 20 ; save the remote name here ttcons::.blkb 20 ; our console name for virtual tty consav::.blkb 20 trace:: .blkw 1 ; for file and packet logging debug:: .blkw 1 ; console debugging sermod::.blkw 1 ; if we are currently a server reccnt::.blkw 1 ; total received count sencnt::.blkw 1 ; total sent count totp.r::.blkw 34 ; total rec by packet type totp.s::.blkw 34 ; total sent by packet type pcnt.r::.blkw 34 ; packet count by type for RPACK pcnt.s::.blkw 34 ; packet count by type for SPACK pcnt.n::.blkw 1 atrctx::.blkw 1 ; context for attribute packets senpar::.blkb 20 ; remotes connection parameters conpar:: recpar::.blkb 20 ; our connection parameters setsen::.blkb 20 ; we may override the default setrec::.blkb 20 ; save for receive parameters image:: .blkw 1 ; if in image mode $image::.blkw 1 ; save image flag for autobyte numtry::.blkw 1 ; number of retrys oldtry::.blkw 1 ; old value of numtry paknum::.blkw 1 ; current packet number mod 64 remote::.blkw 1 ; if <> then we are remote state:: .blkw 1 ; current state linkst::.blkw 1 ; if <> then a link is active outopn::.blkw 1 ; did recsw ever create anything inopn:: .blkw 1 ; did sendsw ever open anything size:: .blkw 1 ; size of last call to bufferfill xgottn::.blkw 1 ; got an xpacket in server xmode:: .blkw 1 ; if <> then doing text output to ti: do8bit::.blkw 1 ; if <> then doing 8 bit prefixing snd8bi::.blkw 1 set8bi::.blkw 1 ; if <> then set bit seven on character ebquot::.blkw 1 ; if doing 8 bit prefixing, this is it errtxt::.blkb 102 ; a buffer for SYSERR(errnum,buffer) rtwork::.blkw 10 ; for RT11 exec calls conflo::.blkw 1 ; for RT11 connect flow control rtque:: .blkw 12*12 ; allocate extra que elements for RT11 at$len::.blkw 1 at$typ::.blkw 1 at$cre::.blkw 1 at$id:: .blkw 1 at$bil::.blkw 1 at$are::.blkw 1 at$pas::.blkw 1 at$bsi::.blkw 1 at$acc::.blkw 1 at$enc::.blkw 1 at$dis::.blkw 1 at$pr0::.blkw 1 at$pr1::.blkw 1K11GLDXRF[.050032]K11GLD.XRF[.050032]    X14|H [4;Ik(&'( k ߫H&P` \RrPP2PPzPP{PPPPP2P~\$\\TD 0D \~ hi) +\ ^( n ^( np\^txY\^ˀ\!kVk<\F˰<˴ˬ\VVkˤ1`@lP ABCDEFGHIJKLMNOPQRSTUVWXYZ$.?0123456789<@<SЬTЬ UQS>?\\\\\\\\\`:#@'="\abcdefghi\\\\\\\jklmnopqr\\\\\\\~stuvwxyz\\\\\\\\\\\\\\\\\\\\\\{ABCDEFGHI\\\\\\}JKLMNOPQR\\\\\\\\STUVWXYZ\\\\\\0123456789\\\\\  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~@ggh<i|o<m<4p<p<k|Zn<l fr rwx<x<x<x޺<w@]@@fjnr]Ze@@|> | |v<H|  |  |xz|  |zt f r   < &^ @&@'*/V,"?Lh:hmBmz|z{x`y~|fN|@@|@͂|@ ݃ƃ<ns<|Ŏ |️|ep|u|-@率|<ᄇ2ֻr||ZRM | ntB|xyvZw|J=|R>|J? nnaa|bddfrk ok suspen::save ; save temps setcc:: getuic:: logout:: quochk:: qspool:: noecho:: echo:: runjob::clr r0 getprv:: drpprv:: throtl::return getatr::mov #er$iop ,r0 putatr::clr r0 binfil::clr r0 chkpar::clr r0 systat:: sercmd::mov #er$iop ,r0 okuser::mov (sp)+ ,@sp dskuse::mov @r5 ,r0 getmcr::mov @r5 ,r0 detach::mov #er$iop ,r0 fetch:: .dstat #rtwork,r5 $mul:: mov r0 ,-(sp) $div:: mov r0 ,-(sp) $ash:: tst 2(sp) ; left shift or rigth shift? >>>>> DB1:K11PRT.MAC[2,2] <<<<< ttysav:: ttyrst:: deadev:: assdev:: ttyini::save ; always save temps please ttyfin::save ; save temps please contrp::clr ttctlc conrst::.scca #rtwork ,#0 xbinre:: binrea::save ; we may want to use these here binwri::save cantyp::save ; save temps ttxon:: call clrxc ; get the driver to clear xoff status ttpars::clr r0 ; always unit zero for PRO/RT gttnam::mov @r5 ,r0 ; for PRO/RT, always return TT: setspd::mov #377 ,r0 chkabo::bis #40000!10000!100,@#JSW ; enable special input modes ttspee:: ttyset:: ttrfin:: ttrini::clr r0 ttydtr:: ttyhan::mov #er$iop ,r0 kbread::mov r2 ,-(sp) >>>>> DB1:K11CVT.MAC[2,2] <<<<< namcvt::save ; save these in case we use them chkext::save ; save scratch registers we will use >>>>> DB1:K11CMD.MAC[2,2] <<<<< kermit::calls setcc ,<#cctrap> ; enable control C trapping ? c$rec:: $name c$send::$name c$serv::$name ; allow patching this out (why??) opentt::tst linksts ; already open ? clostt::save c$exit::call sd$off c$nop:: return ; a NO-OP command ??? rm$bye:: c$bye:: $name rm$fin:: c$fin:: $name rm$get:: c$get:: $name rm$spa::$name rm$hlp::$name rm$hos::$name rm$dir::$name rm$typ::$name rm$who::$name rm$del::$name rm$ren::$name ; do a remote rename please rm$cop::$name ; do a remote Kopy please tkecho::.word -1 ; if <> then echo the take file c$loc:: $name c$rem:: $name c$test::return getcmd::clrb argbuf getcm0::save cctrap::cmp cccnt ,#cc$max direr$::mov r0 ,-(sp) ; direrr will select whether or not gettwo::save ; save temps please >>>>> DB1:K11SEN.MAC[2,2] <<<<< sen.sw:: sendsw::movb @r5 ,state ; do a SINIT first thing please sinfo:: save ; save ALL registers please sinit:: movb #'S&137 ,-(sp) ; normal sinit operation for sending >>>>> DB1:K11REC.MAC[2,2] <<<<< recsw:: clr paknum ; packet_number := 0 rec.sw::movb @r5 ,state ; assume RECEIVE-INIT for starters >>>>> DB1:K11RTT.MAC[2,2] <<<<< assdev::save ; we may want to use these ttyini::save ; we will need this one contrp::.scca #rtwork ,#ttctlc conrst::.scca #rtwork ,#0 ttysav::save ; we will use this one ttyrst::save ; we will use this one xbinre:: binrea::save ; we may want to use these here binwri::save ; save registers we may need ttpars::mov r1 ,-(sp) ; save scratch register please gttnam::save ; save registers please ttyfin::call ttpars ; finish up mt service setspd::save ; save temps that we will use ttspee::save ; save these please spdlst::.word 50. ,75. ,110. ,134. ,150. ,300. ,600. spdmap::.word 0 ,400 ,1000 ,1400 ,2000 ,2400 ,3000 ttxon:: cantyp:: ttyset:: ttydtr:: ttrfin:: ttrini::clr r0 ttyhan::mov #er$iop ,r0 kbread::mov r2 ,-(sp) chkabo::bis #40000!10000!100,@#JSW ; enable special input modes K11GLDXRF[.050032]K11GLD.XRF[.050032]   X14|H [4;Ik(&'( k ߫H&P` \RrPP2PPzPP{PPPPP2P~\$\\TD 0D \~ hi) +\ ^( n ^( np\^txY\^ˀ\!kVk<\F˰<˴ˬ\VVkˤ1`@lP ABCDEFGHIJKLMNOPQRSTUVWXYZ$.?0123456789<@<SЬTЬ UQS>?\\\\\\\\\`:#@'="\abcdefghi\\\\\\\jklmnopqr\\\\\\\~stuvwxyz\\\\\\\\\\\\\\\\\\\\\\{ABCDEFGHI\\\\\\}JKLMNOPQR\\\\\\\\STUVWXYZ\\\\\\0123456789\\\\\  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~@ggh<i|o<m<4p<p<k|Zn<l fr rwx<x<x<x޺<w@]@@fjnr]Ze@@|> | |v<H|  |  |xz|  |zt f r   < &^ @&@'*/V,"?Lh:hmBmz|z{x`y~|fN|@@|@͂|@ ݃ƃ<ns