home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / pdp11 / k11sho.mac < prev    next >
Text File  |  2020-01-01  |  17KB  |  775 lines

  1.     .title    k11sho    do the show command in an overlay
  2.     .ident    /2.0.01/
  3.  
  4. ;    31-Jan-84  08:28:16  Brian Nelson
  5. ;
  6. ;    Remove SHOW code from K11CMD.MAC for placement into an overlay.
  7. ;    Had not realized how large Kermit was getting.
  8.  
  9.  
  10.  
  11.  
  12.  
  13.     .if ndf, K11INC
  14.     .ift
  15.     .include    /IN:K11MAC.MAC/
  16.     .include    /IN:K11CDF.MAC/
  17.     .endc
  18.  
  19.     .enabl    lc
  20.     .enabl    gbl
  21.     .psect    $code
  22.  
  23.  
  24.     .sbttl    the show command
  25.  
  26.  
  27.  
  28. c$show::$name    <SHO>
  29.     calls    getcm0    ,<argbuf,#sholst>
  30.     tst    r0
  31.     bmi    110$
  32.     jsr    pc    ,@r1
  33.     return
  34.  
  35. 110$:    message    <Unknown SHOW topic>,cr
  36.     return
  37.  
  38.  
  39. sho$al:    message
  40.     call    sho$at
  41.     call    sho$bl
  42.     call    sho$de
  43.     call    sho$df
  44.     call    sho$dl
  45.     call    sho$es
  46.     call    sho$fi
  47.     call    sho$ha
  48.     call    sho$li
  49.     call    sho$pa
  50.     call    sho$pk
  51.     call    sho$ph
  52.     call    sho$pr
  53.     call    sho$ps
  54.     call    sho$rf
  55.     call    sho$rx
  56.     call    sho$so
  57.     call    sho$ti
  58.     call    sho$ve
  59.     message
  60.     return
  61.  
  62.  
  63.  
  64.     $cmglob    =    0
  65.  
  66.     command    sholst    ,ALL    ,3    ,sho$al
  67.     command    sholst    ,BINARY-TYPE,3    ,sho$bt
  68.     command    sholst    ,BLOCK_CHECK_TYPE,3,sho$bl
  69.     command    sholst    ,BLOCK-CHECK-TYPE,3,sho$bl
  70.     command    sholst    ,CONSOLE,3    ,sho$co
  71.     command    sholst    ,DATE    ,3    ,sho$da
  72.     command    sholst    ,DEBUG    ,3    ,sho$de
  73.     command    sholst    ,DEFAULT,3    ,sho$df
  74.     command    sholst    ,DELAY    ,3    ,sho$dl
  75.     command    sholst    ,DIRECTORY,3    ,sho$df
  76.     command    sholst    ,ESCAPE    ,3    ,sho$es
  77.     command    sholst    ,FILETYPE,3    ,sho$fi
  78.     command    sholst    ,HANDSHAKE,3    ,sho$ha
  79.     command    sholst    ,LINE    ,3    ,sho$li
  80.     command    sholst    ,PACKET    ,3    ,sho$pk
  81.     command    sholst    ,PARAMETERS,4    ,sho$pa
  82.     command    sholst    ,PARITY    ,3    ,sho$pr
  83.     command    sholst    ,PAUSE    ,3    ,sho$ps
  84.     command    sholst    ,PHONE    ,3    ,sho$ph
  85.     command    sholst    ,RECORD_FORMAT,3,sho$rf
  86.     command    sholst    ,RECORD-FORMAT,3,sho$rf
  87.     command    sholst    ,RELEASE_NOTES,3,sho$rl
  88.     command    sholst    ,RSX    ,3    ,sho$rx
  89.     command    sholst    ,START-OF-PACKET,3,sho$so
  90.     command    sholst    ,START_OF_PACKET,3,sho$so
  91.     command    sholst    ,TIME    ,3    ,sho$ti
  92.     command    sholst    ,VERSION,3    ,sho$ve
  93.     command    sholst    ,DIAL    ,3    ,sho$dp
  94.     command    sholst
  95.  
  96. sho$dp:    tst    (sp)+            ; Show DIAL is a special case
  97.     jmp    xxsdia            ; where we load an adjacent overlay
  98.  
  99.     global    <xxsdia>
  100.  
  101.  
  102.     .sbttl    routines for the show command
  103.     .enabl    lsb
  104.  
  105. sho$de:    tst    trace            ; any debugging turned on now ?
  106.     bne    10$            ; yes
  107.     message    <No debugging or logging is active>,cr
  108.     br    100$            ; exit
  109.  
  110. 10$:    message    <Debug file is >
  111.     print    #logfil
  112.     clr    r0            ; index := 0
  113.     message
  114.  
  115. 20$:    tst    200$(r0)        ; end of the list yet ?
  116.     beq    100$            ; yes, bye
  117.     print    205$(r0)        ; print the header
  118.     bit    200$(r0),trace        ; see if a bit is turned on
  119.     beq    30$            ; no
  120.     message    <enabled>,cr        ; say so then
  121.     br    40$            ; next please
  122. 30$:    message    <disabled>,cr        ; if off then also say so
  123. 40$:    tst    (r0)+            ; next please
  124.     br    20$            ; all done yet ?
  125.  
  126. 100$:    return                ; simple
  127.  
  128.  
  129.     .Save
  130.     .psect    $Pdata,d
  131. 200$:    .word    log$co    ,log$fi    ,log$pa    ,log$st    ,0
  132. 205$:    .word    210$    ,220$    ,230$    ,240$
  133. 210$:    .asciz    /Remote connection logging /
  134. 220$:    .asciz    /File opens and  creations /
  135. 230$:    .asciz    /Packet logging to logfile /
  136. 240$:    .asciz    /State  logging to logfile /
  137.     .even
  138.     .restore
  139.  
  140.  
  141.  
  142.  
  143. sho$li:    tstb    ttdial            ; show the terminal show
  144.     bne    300$            ; something is there
  145.     message    <No remote line has been set>,cr
  146.     return
  147. 300$:    message    <Current remote link device name is >
  148.     print    #ttdial            ; print it and exit
  149.     message
  150.     message    <The current speed for the link  is >
  151.     calls    ttspee    ,<#ttdial>
  152.     sub    #20    ,sp        ; try to format the response a little
  153.     mov    sp    ,r1        ; allocate a buffer and point to it
  154.     deccvt    r0,r1,#4        ; convert to decimal, 4 wide
  155.     print    r1    ,#4        ; print it
  156.     add    #20    ,sp        ; pop the buffer
  157.     message    < baud>,cr        ; and finish off the message
  158.     return
  159.  
  160.     .dsabl    lsb
  161.  
  162.  
  163.  
  164.  
  165.     .sbttl    show time and version
  166.     .enabl    lsb
  167.  
  168. sho$dy::calls    ascdat    ,<#errtxt,#0>
  169.     print    #errtxt
  170.     MESSAGE    < >
  171.     calls    asctim    ,<#errtxt,#0>
  172.     print    #errtxt
  173.     message
  174.     return
  175.  
  176.  
  177. sho$ti:    calls    asctim    ,<#errtxt,#0>
  178.     message    <The time is >
  179.     print    #errtxt
  180.     message
  181.     return
  182.  
  183. sho$da:    calls    ascdat    ,<#errtxt,#0>
  184.     message    <The date is >
  185.     print    #errtxt
  186.     message
  187.     return
  188.  
  189. sho$df:    message    <Directory for send opens and receive creates: >
  190.     tstb    defdir
  191.     beq    10$
  192.     print    #defdir
  193.     message
  194.     return
  195. 10$:    message    <none>,cr
  196.     return
  197.  
  198.  
  199. sho$ve::message    <Kermit-11 >
  200.     sub    #40    ,sp        ; allocate a buffer
  201.     mov    sp    ,r1        ; point to it
  202.     movb    #release,(r1)+        ; is this test or for real
  203.     deccvt    #baselev,r1        ; convert baseline level to ascii
  204.     add    #6    ,r1        ; skip past it
  205.     movb    #'.    ,(r1)+        ; a dot
  206.     deccvt    #edit    ,r1        ; the edit number now
  207.     mov    sp    ,r1        ; point back to the buffer
  208.     calls    cvt$$    ,<r1,#14.,#377>    ; drop all the extra spaces out
  209.     print    r1,r0            ; simple
  210.     print    #lasted
  211.     message                ; a crlf
  212.     add    #40    ,sp
  213.     return
  214.  
  215.  
  216.     .dsabl    lsb
  217.  
  218.     global    <lasted,release,baselev,edit>
  219.  
  220.  
  221.     .sbttl    show filetype and show block-check
  222.     .enabl    lsb
  223.  
  224.  
  225. sho$fi:    cmpb    $image    ,#text        ; text files
  226.     bne    10$            ; not text
  227.     message    <Filetype set to ASCII>,cr
  228.     br    20$
  229. 10$:    cmpb    $image    ,#binary    ; binary ?
  230.     bne    20$            ; really ?
  231.     message    <Filetype set to BINARY (fixed 512, no carriage control)>,cr
  232. 20$:    tst    filprot
  233.     beq    25$
  234.     message    <Files will not be superceded>,cr
  235. 25$:    return
  236.     
  237.  
  238.  
  239. sho$bl:    movb    setrec+p.chkt,r0    ; get the checksum type please
  240.     bne    30$            ; it's been set already
  241.     movb    #defchk    ,r0        ; no, set the default checktype in
  242. 30$:    sub    #'1    ,r0        ; convert to an index for printing
  243.     asl    r0            ; times 2 for word addressing
  244.     print    100$(r0)        ; and say so
  245.     return
  246.  
  247.  
  248.     .save
  249.     .psect    $Pdata,d
  250. 100$:    .word    110$,120$,130$
  251. 110$:    .asciz    /1-Character-Checksum/<cr><lf>
  252. 120$:    .asciz    /2-Character-Checksum/<cr><lf>
  253. 130$:    .asciz    /3-Character-CRC-CCITT/<cr><lf>
  254.     .even
  255.     .restore
  256.  
  257.     .dsabl    lsb
  258.  
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.     .sbttl    show parameters and show escape
  266.     .enabl    lsb
  267.  
  268. sho$es::mov    conesc    ,r1
  269.     bne    10$
  270.     mov    #con$es    ,r1
  271. 10$:    add    #100    ,r1        ; echo it back out
  272.     mov    r1    ,-(sp)        ; allocate a buffer
  273.     mov    sp    ,r1        ; point to it
  274.     message    <Connection escape character set to ^>
  275.     print    r1    ,#1        ; simple
  276.     message
  277.     tst    (sp)+            ; pop buffer and exit
  278.     return                ; bye
  279.  
  280.  
  281. sho$pa:    message    <SEND  packet  eol character  >
  282.     movb    conpar+p.eol,r0
  283.     octout    r0
  284.     message    <   (octal)>,cr
  285.     message    <SEND  maximum  packet  size  >
  286.     movb    conpar+p.spsiz,r0
  287.     decout    r0
  288.     message
  289.     message    <SEND/RECEIVE packet timeout  >
  290.     movb    conpar+p.time,r0
  291.     decout    r0
  292.     message
  293.     message    <RETRY  maximum for  packets  >
  294.     decout    maxtry            ; retry count
  295.     message
  296.     return
  297.  
  298.     global    <conpar    ,maxtry>
  299.  
  300.     .dsabl    lsb
  301.  
  302.  
  303.  
  304.  
  305.     .sbttl    show packet statistics
  306.     .enabl    lsb
  307.  
  308. c$stat::
  309. sho$pk:    sub    #120    ,sp        ; /43/ Allocate a buffer please
  310.     print    #300$            ; /43/ A header
  311.     clr    r3            ; /43/ Current item to Dump
  312.     mov    #27.    ,r4        ; /43/ Number items to dump
  313. 10$:    mov    sp    ,r5        ; /43/ And a pointer to it
  314.     tst    pcnt.r+2(r3)        ; /43/ Anything there to dump?
  315.     bne    15$            ; /43/ Yes
  316.     tst    pcnt.s+2(r3)        ; /43/ No, what about SENT packets?
  317.     beq    90$            ; /43/ No, skip the whole thing
  318. 15$:    mov    r5    ,r1        ; /43/ Fill the buffer with spaces
  319.     mov    #110    ,r2        ; /43/ Count for the fill
  320. 20$:    movb    #40    ,(r1)+        ; /43/ Stuff a space
  321.     sob    r2    ,20$        ; /43/ And go back for more
  322.     mov    r3    ,r1        ; /43/ Current TYPE
  323.     beq    30$            ; /43/ So skip TYPE field
  324.     asr    r1            ; /43/ Divide by two
  325.     asr    r1            ; /43/ Again
  326.     add    #100    ,r1        ; /43/ Get the letter type now
  327.     movb    r1    ,(r5)+        ; /43/ Insert into the buffer
  328.     br    40$            ; /43/ Insert data now
  329. 30$:    tstb    (r5)+            ; /43/ First entry is NULL
  330. 40$:    add    #5    ,r5        ; /43/ Skip over a couple spaces
  331.     mov    #pcnt.s    ,r1        ; /43/ SENT packet count
  332.     call    200$            ; /43/ Convert double quantity
  333.     mov    #pcnt.r    ,r1        ; /43/ RECEIVED packet count
  334.     call    200$            ; /43/ Convert double quantity
  335.     mov    totp.s    ,r1        ; /43/ Total SENT packet count
  336.     call    200$            ; /43/ Convert double quantity
  337.     mov    totp.r    ,r1        ; /43/ Total RECEIVED packet count
  338.     call    200$            ; /43/ Convert double quantity
  339.     movb    #CR    ,(r0)+        ; /43/ Insert carriage control
  340.     movb    #LF    ,(r0)+        ; /43/ Insert carriage control
  341.     clrb    @r0            ; /43/ All done, .asciz
  342.     mov    sp    ,r0        ; /43/ Now DUMP it
  343.     print    r0            ; /43/ Simple
  344. 90$:    add    #4    ,r3        ; /43/ Move up to next entry
  345.     sob    r4    ,10$        ; /43/ More to do ?
  346.                     ; /43/ No, dump character counts
  347.     print    #310$            ; /43/ A header
  348.     message    <Characters Sent: >    ; /43/
  349.     mov    sp    ,r4        ; /43/ Buffer address
  350.     mov    #charout,r1        ; /43/ Data characters in
  351.     call    190$            ; /43/ Print it
  352.     message    <    Received: >    ; /43/ Data characters in
  353.     mov    #charin    ,r1        ; /43/ Point to it
  354.     call    190$            ; /43/ And dump
  355.     message                ; /43/ CRLF
  356.     mov    #times+2,r1        ; /43/
  357.     tst    (r1)+            ; /43/ A real clock going ?
  358.     beq    100$            ; /43/ No, may be rt11 today
  359.     message    <Time in seconds: >    ; /43/
  360.     call    190$            ; /43/
  361.     message                ; /43/ CRLF
  362.     call    brate            ; /43/ Data rates also
  363. 100$:    add    #120    ,sp        ; /43/ Pop local buffer and exit
  364.     return                ; /43/ Bye
  365.  
  366.  
  367. 190$:    clr    r2            ; /43/ Convert for character counts
  368.     mov    r4    ,r0        ; /43/ Buffer address
  369.     call    $cddmg            ; /43/ Convert 32 bit integer
  370.     clrb    @r0            ; /43/ .asciz
  371.     print    r4            ; /43/ Dump and exit
  372.     return                ; /43/ Bye
  373.  
  374.  
  375. 200$:    add    r3    ,r1        ; /43/ Get address to convert
  376.     clr    r2            ; /43/ Insure no leading zeroes
  377.     mov    r5    ,r0        ; /43/ Set buffer address
  378.     call    $cddmg            ; /43/ Convert
  379.     add    #14    ,r5        ; /43/ Position for next time
  380.     return                ; /43/ Exit
  381.  
  382.  
  383.     .save
  384.     .psect    $Pdata,D
  385. 300$:    .ascii    /Type  Last Sent   Last Rec    Tot Sent    Tot Rec/
  386.     .byte    cr,lf,cr,lf,0
  387. 310$:    .ascii    /Total character count, less packet framing, but after data/
  388.     .byte    cr,lf
  389.     .ascii    /formatting (ie, includes repeat compression and prefixing)/
  390.     .byte    cr,lf
  391.     .ascii    /from last transaction./
  392.     .byte    cr,lf,cr,lf,0
  393.     .even
  394.     .restore
  395.  
  396.     .dsabl    lsb
  397.  
  398.     global    <pcnt.r,pcnt.s,totp.r,totp.s,$cddmg>
  399.  
  400.  
  401.  
  402.  
  403.     .sbttl    More for STAT and SHO PACKETS
  404.     .enabl    lsb            ; /56/
  405.  
  406. brate:    mov    charout+2,r1        ; /43/ Compute effective baud rate
  407.     mov    charout+0,r0        ; /43/ for the last transaction.
  408.     add    charin+2,r1        ; /43/ Don't care which way it was
  409.     adc    r0            ; /43/ Overflow?
  410.     add    charin    ,r0        ; /43/ Done
  411.     div    times+6,r0        ; /43/ At last (forget the 16 high)
  412.     message    <Physical data  rate: >    ; /43/ A header
  413.     decout    r0            ; /43/ Dump the DATA
  414.     message    < char/second>,cr    ; /43/
  415.     mov    fileout+2,r1        ; /43/ Compute effective baud rate
  416.     mov    fileout+0,r0        ; /43/ for the last transaction.
  417.     add    filein+2,r1        ; /43/ Don't care which way it was
  418.     adc    r0            ; /43/ Overflow?
  419.     add    filein    ,r0        ; /43/ Done
  420.     div    times+6,r0        ; /43/ At last (forget the 16 high)
  421.     message    <File transfer  rate: >    ; /43/ A header
  422.     decout    r0            ; /43/ Dump the DATA
  423.     message    < char/second>,cr    ; /43/
  424.     mov    rdrate+2,r1        ; /56/
  425.     beq    100$            ; /56/
  426.     mov    rdrate+0,r0        ; /56/
  427.     div    rdrate+4,r0        ; /56/
  428.     message    <Characters per read: >    ; /56/
  429.     decout    r0            ; /56/
  430.     message                ; /56/
  431. 100$:    return                ; /43/
  432.  
  433.     .dsabl    lsb            ; /56/
  434.  
  435.     global    <rdrate>        ; /56/
  436.  
  437.  
  438.  
  439.     .sbttl    more show command (delay and pause)
  440.  
  441.  
  442.  
  443. sho$ps:    message    <Pause time before packet transmission >
  444.     decout    pauset
  445.     message
  446.     return
  447.  
  448. sho$dl:    message    <Delay time  before sending  SEND-INIT >
  449.     decout    sendly
  450.     message
  451.     return
  452.  
  453.  
  454.     .enabl    lsb
  455.  
  456. sho$rf:    cmpb    df$rfm    ,#fb$stm    ; r.var or stream ascii today ?
  457.     bne    10$
  458.     message    <Created files will be Stream Ascii>,cr
  459.     return
  460. 10$:    message    <Created files will be Variable with implied CRLF>,cr
  461.     return
  462.  
  463.  
  464.     global    <df$rfm    ,fb$stm    ,pauset    ,sendly>
  465.  
  466.     .dsabl    lsb
  467.  
  468.  
  469.     .sbttl    more show
  470.     .enabl    lsb
  471.  
  472.  
  473. sho$ha:    movb    handch    ,r0        ; any handshake garbage today?
  474.     beq    100$            ; no
  475.     cmpb    r0    ,#'Q&37        ; xonning today ?
  476.     bne    10$            ; no
  477.     message    <Handshake character set to XON (^Q)>,cr
  478.     return
  479. 10$:    cmpb    r0    ,#cr        ; carriage return turnaround?
  480.     bne    20$
  481.     message    <Handshake character set to CR (^M)>,cr
  482.     return
  483. 20$:    cmpb    r0    ,#'S&37        ; xoff is it ? (??)
  484.     bne    30$            ; no
  485.     message    <Handshake character set to XOFF (^S)>,cr
  486.     return
  487. 30$:
  488. 100$:    return
  489.     
  490.     .dsabl    lsb
  491.  
  492.  
  493.  
  494.  
  495.     .sbttl    show parity
  496.  
  497. sho$pr:    mov    parity    ,r0
  498.     message    <Parity is set to >
  499.     asl    r0
  500.     print    parlst(r0)
  501.     clr    r0
  502.     return
  503.  
  504.     .save
  505.     .psect    $pdata
  506.  
  507. parlst:    .word    50$,10$,20$,30$,40$,50$
  508. 10$:    .asciz    /ODD/<cr><lf>
  509. 20$:    .asciz    /EVEN/<cr><lf>
  510. 30$:    .asciz    /MARK/<cr><lf>
  511. 40$:    .asciz    /SPACE/<cr><lf>
  512. 50$:    .asciz    /NONE/<cr><lf>
  513.     .restore
  514.  
  515.     .assume    par$od    eq    1
  516.     .assume    par$ev    eq    2
  517.     .assume    par$ma    eq    3
  518.     .assume    par$sp    eq    4
  519.     .assume    par$no    eq    5
  520.  
  521.     global    <parity>
  522.  
  523.  
  524.  
  525.     .sbttl    show rsx
  526.  
  527.     .enabl    lsb
  528.  
  529. sho$rx:    message    <TC.DLU is set to >
  530.     tstb    tcdlu
  531.     bne    10$
  532.     message    <current system setting.>,cr
  533.     br    20$
  534. 10$:    decout    tcdlu
  535.     message
  536. 20$:    clr    r0
  537.     return
  538.  
  539.  
  540. sho$co:    tst    proflg
  541.     beq    40$
  542.     message    <PRO/350 console is set to >
  543.     tst    con8bit
  544.     bne    30$
  545.     message    <7 bit mode>,cr
  546.     br    40$
  547. 30$:    message    <8 bit mode>,cr
  548. 40$:    clr    r0
  549.     return
  550.  
  551. sho$at:    message    <Attribute packet transmission >
  552.     tst    sendat
  553.     bne    50$
  554.     message    <DISABLED>,cr
  555.     br    60$
  556. 50$:    message    <ENABLED>,cr
  557. 60$:    return
  558.  
  559.     .dsabl    lsb
  560.  
  561.  
  562. sho$so:    message    <RECEIVE start of packet character is ^>
  563.     mov    recsop    ,-(sp)
  564.     add    #100    ,@sp
  565.     mov    sp    ,r0
  566.     print    r0
  567.     message
  568.     message    <SEND    start of packet character is ^>
  569.     mov    sensop    ,@sp
  570.     add    #100    ,@sp
  571.     mov    sp    ,r0
  572.     print    r0
  573.     tst    (sp)+
  574.     message
  575.     return
  576.  
  577.  
  578.     .sbttl    show binary filetype list
  579.     .enabl    lsb
  580.  
  581.  
  582. sho$bt:    message    <Default binary filetype list: >
  583.     mov    bintyp    ,r1
  584.     tstb    @r1            ; is there anything there at all
  585.     bne    10$            ; yes
  586.     message    <none>,cr        ; no
  587.     br    100$            ; exit
  588. 10$:    mov    bintyp    ,r1        ; get the address of the list
  589. 20$:    mov    #5    ,r2        ; the list is simply a concatenated
  590.     message                ; string of filetypes rather than
  591. 30$:    tstb    @r1            ; the more general one of a list
  592.     beq    40$            ; of pointers.
  593.     message    < *>            ; format it into *.xyz
  594.     print    r1    ,#4        ; dump current one
  595.     add    #4    ,r1        ; next
  596.     sob    r2    ,30$        ; and print the next one
  597.     br    20$            ; insert a newline
  598. 40$:    message                ; insert a <cr><lf>
  599. 100$:    return                ; and exit
  600.  
  601.  
  602.  
  603.     .dsabl    lsb
  604.     .enabl    lsb
  605.  
  606. sho$ph:    message    <Current defined phone numbers>,cr
  607.     message
  608.     mov    #pnhead    ,r2
  609.     tst    (r2)            ; /48/ Anything there?
  610.     bne    10$            ; /48/ Yes
  611.     message    <None defined>,cr    ; /48/ No
  612.     br    20$            ; /48/ Exit
  613. 10$:    mov    (r2)    ,r2        ; /48/ Get pointer to next
  614.     beq    20$            ; /48/ Nothing
  615.     mov    r2    ,r3        ; /48/ Copy pointer
  616.     add    #2    ,r3        ; /48/ Point to the text
  617.     print    r3            ; /48/ Dump
  618.     message                ; /48/ CR/LF
  619.     br    10$            ; /48/ Next please
  620. 20$:    message                ; /48/ Done with phone numbers
  621. 100$:    return
  622.  
  623.     .dsabl    lsb
  624.  
  625.     global    <pnhead>        ; /48/ Listhead for phone numbers
  626.  
  627.  
  628.  
  629.  
  630.     .sbttl    show RELEASE_NOTES
  631.     .enabl    lsb
  632.  
  633. sho$rl::print    #200$
  634.     print    #210$
  635.     print    #220$
  636.     return
  637.  
  638.     .save
  639.     .psect    $pdata    ,d
  640. 200$:
  641. .byte    CR,LF
  642. .ascii    / A problem was discovered with attribute  packet  processing/<CR><LF>
  643. .ascii    /in versions of Kermit-11  prior to  3.49.  This implies that/<CR><LF>
  644. .ascii    /versions 3.49 or later of Kermit-11 will not  be  completely/<CR><LF>
  645. .asciz    /compatable  with older versions. The best workaround until a/<CR><LF>
  646. 210$:
  647. .ascii    /copy of version 3.49 or later can be obtained is to  disable/<CR><LF>
  648. .ascii    /attribute   packet   processing  with  the  SET  NOATTRIBUTE/<CR><LF>
  649. .ascii    /command, and manually use the SET FILE TYPE  FIXED  (or  SET/<CR><LF>
  650. .asciz    /FILE  BINARY)  command  on  both  Kermit-11's  in  order  to/<CR><LF>
  651. 220$:
  652. .ascii    /transfer binary files (such as  task  images).  For  further/<CR><LF>
  653. .ascii    /information please see K11.BWR and K11INS.DOC /<CR><LF>
  654. .byte    CR,LF,0
  655.  
  656.     .even
  657.     .restore
  658.     .dsabl    lsb
  659.  
  660.  
  661.  
  662.  
  663.     .sbttl    the copy command
  664.     .enabl    lsb
  665.  
  666. c$copy::$name    <COP>
  667.     call    gettwo            ; insure the 'to:' argument is here
  668.     tst    r0            ; did it work out ok ?
  669.     bne    100$            ; we really could have done this in
  670.     mov    argbuf    ,r2        ; the command macro.
  671.     calls    copy    ,<cmdbuf,r2,#0>    ; do the rename now
  672.     tst    r0            ; did it work ?
  673.     bne    40$            ; yes
  674.     decout    r1            ; print the block count
  675.     print    #210$            ; and a header
  676.     print    r2            ; and the file copied to
  677.     print    #200$            ; a cr/lf
  678.     br    100$            ; bye
  679. 40$:    direrr    r0            ; no, print the error message
  680.  
  681. 100$:    return
  682.  
  683.     .save
  684.     .psect    $Pdata,d
  685. 200$:    .byte    cr,lf,0
  686. 210$:    .asciz    / blocks copied /
  687.     .even
  688.     .restore
  689.     .dsabl    lsb
  690.  
  691.     global    <argbuf    ,cmdbuf    ,gettwo>
  692.  
  693.  
  694.  
  695.  
  696.  
  697.  
  698.     .sbttl    the rename command
  699.  
  700. c$rena::$name    <REN>
  701.     call    gettwo            ; insure a 'to:' argument is here
  702.     tst    r0            ; did it work out ok?
  703.     bne    100$            ; no
  704.     mov    argbuf    ,r2        ; point to the arguement buffer
  705.     calls    rename    ,<cmdbuf,r2,#0>    ; do the rename now
  706.     tst    r0            ; did it work ?
  707.     beq    100$            ; yes
  708.     direrr    r0            ; no, print the error message
  709.  
  710. 100$:    return
  711.  
  712.     global    <argbuf    ,cmdbuf    ,gettwo>
  713.  
  714.  
  715.  
  716. c$del::    $name    <DEL>
  717.     calls    delete    ,<argbuf,#0>
  718.     direrr    r0
  719.     return
  720.  
  721.     global    <argbuf    ,cmdbuf>
  722.  
  723.  
  724.     .sbttl    get/and or read second command argument
  725.     .enabl    lsb
  726.  
  727. ;    input:    argbuf    command args
  728. ;    output:    cmdbuf    first arg
  729. ;        argbuf    second arg
  730. ;        r0    error code from read if done, else zero
  731.  
  732.  
  733. gettwo::save    <r1,r2>            ; save temps please
  734.     mov    argbuf    ,r2        ; point to the arguement buffer
  735.     tstb    @r2            ; anything there (should be) ?
  736.     beq    100$            ; no
  737.     dec    r2
  738. 10$:    inc    r2            ; next byte
  739.     tstb    @r2            ; We have to finish parsing this
  740.     beq    20$            ; end of it, prompt for 'To:'
  741.     cmpb    @r2    ,#40        ; find a space yet ?
  742.     bne    10$            ; no
  743.     clrb    (r2)+            ; yes, make it .asciz
  744.     copyz    argbuf    ,cmdbuf        ; save the first part of the arg
  745.     br    30$            ; got old and new so we are all set
  746.  
  747. 20$:    mov    argbuf    ,r2        ; point to the 'to:' part to read
  748.     copyz    r2    ,cmdbuf        ; save the from part
  749.     print    #200$            ; and read the rest of it
  750.     calls    echo    ,<#0>        ; ensure terminal can echo
  751.     calls    kbread    ,<r2>        ; do it
  752.     tst    r0            ; did it work ?
  753.     bne    100$            ; no
  754.     calls    cvt$$    ,<r2,r1,#377>    ; yes, remove all junk
  755.     tst    r0            ; anything left ?
  756.     beq    20$            ; no
  757.     add    r2    ,r0        ; yes, make it .asciz
  758.     clrb    @r0            ; simple
  759.  
  760. 30$:    copyz    r2    ,argbuf        ; return arg number two in argbuf
  761.     clr    r0            ; no errors please
  762. 100$:    unsave    <r2,r1>            ; pop temps and exit
  763.     return
  764.  
  765.     .save
  766.     .psect    $Pdata,D
  767. 200$:    .asciz    /To:   /
  768.     .even
  769.     .restore
  770.     .dsabl    lsb
  771.  
  772.  
  773.  
  774.     .end
  775.