home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / old / ckermit5a190 / ckop200.ini < prev    next >
Text File  |  2020-01-01  |  11KB  |  276 lines

  1. ; FILE P200.INI (CKOP200.INI)
  2. ;  Macros for invoking P version 2.xx from OS/2 C-Kermit.
  3. ;
  4. ; Jeffrey Altman, Altmania Productions and Seer Technologies, New York
  5. ;  <p00118@psilink.com>
  6. ;  Version 9
  7. ;  December 30, 1994
  8. ;
  9. ; P is an external protocol package providing X-modem, Y-modem, Y-modem-G
  10. ; and Z-modem send and receive capabilities on OS/2 via Serial, IBM TCP/IP 2.0,
  11. ; and Named Pipe connections written by Jyrki Salmi <jytasa@jyu.fi>.
  12. ;
  13. ; The P protocol dynamic link library is freeware available from most major
  14. ; ftp sites (ftp-os2.nmsu.edu, ftp.cdrom.com), bulletin board services
  15. ; and CompuServe (IBMCOM and OS2BVEN).  From the documentation:
  16. ;
  17. ;"3. Distribution policy
  18. ;
  19. ;    P.EXE - the front-end for the DLL is distributed as public
  20. ;    domain, which means that anyone can modify and recompile the
  21. ;    sources and do whatever they want with it. However, credits to
  22. ;    the original author (me) would be highly appreciated but not
  23. ;    required, if found so repugnant.
  24. ;
  25. ;    P.DLL - the transfer protocol engine is distributed as
  26. ;    freeware, which means that the author (me) wants to keep his
  27. ;    copyright to the program but gives everyone the right to use
  28. ;    and copy it freely, without of charge."
  29. ;
  30. ; P version 2.xx was designed with OS/2 C-Kermit in mind.  The following
  31. ; macro definitions provide X,Y, and Z modem file send and receive
  32. ; capabilities on all connection types supported by OS/2 C-Kermit 5A(190)
  33. ; excluding NetBIOS and DECnet.  With C-Kermit versions prior to 5A(190)
  34. ; only asynchronous connections are supported.
  35. ;
  36. ; Commands:
  37. ;    sz/rz - send/receive with Zmodem
  38. ;    sy/ry - send/receive with Ymodem
  39. ;    sg/rg - send/receive with Ymodem-G
  40. ;    sx/rx - send/receive with Xmodem
  41. ;
  42. ; As of this writing, the current release of P is 2.04.
  43. ;
  44. ; WARNING:
  45. ;   As of version 2.04, P's TCP/IP support only works with IBM TCP/IP 2.0.
  46. ;   If when trying these commands on a TCP/IP TELNET connection, you receive
  47. ;   an error "cannot load SO32DLL" this means that you are not using IBM
  48. ;   TCP/IP version 2.0.
  49. ;   This file should need no changes in order to work with future 2.xx
  50. ;   releases of P that support other TCP/IP protocol stack packages.
  51. ;
  52. ; DISCLAIMER:
  53. ;   These macro definitions are included with C-Kermit as a convenience
  54. ;   to users of P 2.xx.  Columbia University is not a source for the P
  55. ;   software, nor does it support P in any way.
  56. ;
  57. echo Initializing X,Y,YG,Z-modem support using P version 2.xx...
  58.  
  59. ; define some global variables
  60. ; these settings may be altered at any time within kermit by redefining them
  61. define p_recv_dir .     ; where files received by P are placed
  62. define p_commbufs 4096  ; size of the communication buffers
  63. define p_filebuf 32768  ; size of the file I/O buffers
  64.  
  65. if < \v(version) 501190 goto asynconly
  66.  
  67. ; Send via Zmodem
  68. define sz -
  69.   if equal "\v(connection)" "serial" goto async, -
  70.   if equal "\v(connection)" "named_pipe" goto pipe, -
  71.   if equal "\v(connection)" "tcp/ip_telnet" goto socket, -
  72.   echo "sz not supported on \v(connection) connections.",-
  73.   end, -
  74.   :async, -
  75.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  76.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  77.        -resume -protocol zmodem -send \%1, end, -
  78.   :pipe, -
  79.     !p.exe -type pipe -handle \v(ttyfd) -commbufs \m(p_commbufs) -resume -
  80.        -filebuf \m(p_filebuf) -mileage -protocol zmodem -send \%1, end, -
  81.   :socket, -
  82.     !p.exe -type socket -handle \v(ttyfd) -telnet -commbufs \m(p_commbufs) -
  83.            -resume -filebuf \m(p_filebuf) -mileage -protocol zmodem -
  84.            -send \%1, end
  85.  
  86. ; Receive via Zmodem
  87. define rz -
  88.   if equal "\v(connection)" "serial" goto async, -
  89.   if equal "\v(connection)" "named_pipe" goto pipe, -
  90.   if equal "\v(connection)" "tcp/ip_telnet" goto socket, -
  91.   echo "rz not supported on \v(connection) connections.",-
  92.   end, -
  93.   :async, -
  94.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  95.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  96.        -resume -protocol zmodem -directory \m(p_recv_dir) -receive, end, -
  97.   :pipe, -
  98.     !p.exe -type pipe -handle \v(ttyfd) -commbufs \m(p_commbufs) -
  99.        -filebuf \m(p_filebuf) -mileage -protocol zmodem -
  100.        -resume -directory \m(p_recv_dir) -receive, end, -
  101.   :socket, -
  102.     !p.exe -type socket -handle \v(ttyfd) -telnet -commbufs \m(p_commbufs) -
  103.        -filebuf \m(p_filebuf) -mileage -protocol zmodem -
  104.        -resume -directory \m(p_recv_dir) -receive, end
  105.  
  106. ; Send via Ymodem-G
  107. define sg -
  108.   if equal "\v(connection)" "serial" goto async, -
  109.   if equal "\v(connection)" "named_pipe" goto pipe, -
  110.   if equal "\v(connection)" "tcp/ip_telnet" goto socket, -
  111.   echo "sy not supported on \v(connection) connections.",-
  112.   end, -
  113.   :async, -
  114.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  115.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  116.        -protocol ymodem-g -send \%1, end, -
  117.   :pipe, -
  118.     !p.exe -type pipe -handle \v(ttyfd) -commbufs \m(p_commbufs) -
  119.        -filebuf \m(p_filebuf) -mileage -protocol ymodem-g -send \%1, end, -
  120.   :socket, -
  121.     !p.exe -type socket -handle \v(ttyfd) -telnet -commbufs \m(p_commbufs) -
  122.        -filebuf \m(p_filebuf) -mileage -protocol ymodem-g -send \%1, end
  123.  
  124. ; Receive via Ymodem-G
  125. define rg -
  126.   if equal "\v(connection)" "serial" goto async, -
  127.   if equal "\v(connection)" "named_pipe" goto pipe, -
  128.   if equal "\v(connection)" "tcp/ip_telnet" goto socket, -
  129.   echo "ry not supported on \v(connection) connections.",-
  130.   end, -
  131.   :async, -
  132.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  133.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  134.        -protocol ymodem-g -directory \m(p_recv_dir) -receive, end, -
  135.   :pipe, -
  136.     !p.exe -type pipe -handle \v(ttyfd) -commbufs \m(p_commbufs) -
  137.        -filebuf \m(p_filebuf) -mileage -protocol ymodem-g -
  138.        -directory \m(p_recv_dir) -receive, end, -
  139.   :socket, -
  140.     !p.exe -type socket -handle \v(ttyfd) -telnet -commbufs \m(p_commbufs) -
  141.        -filebuf \m(p_filebuf) -mileage -protocol ymodem-g -
  142.        -directory \m(p_recv_dir) -receive, end
  143.  
  144. ; Send via Ymodem
  145. define sy -
  146.   if equal "\v(connection)" "serial" goto async, -
  147.   if equal "\v(connection)" "named_pipe" goto pipe, -
  148.   if equal "\v(connection)" "tcp/ip_telnet" goto socket, -
  149.   echo "sy not supported on \v(connection) connections.",-
  150.   end, -
  151.   :async, -
  152.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  153.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  154.        -protocol ymodem -send \%1, end, -
  155.   :pipe, -
  156.     !p.exe -type pipe -handle \v(ttyfd) -commbufs \m(p_commbufs) -
  157.        -filebuf \m(p_filebuf) -mileage -protocol ymodem -send \%1, end, -
  158.   :socket, -
  159.     !p.exe -type socket -handle \v(ttyfd) -telnet -commbufs \m(p_commbufs) -
  160.        -filebuf \m(p_filebuf) -mileage -protocol ymodem -send \%1, end
  161.  
  162. ; Receive via Ymodem
  163. define ry -
  164.   if equal "\v(connection)" "serial" goto async, -
  165.   if equal "\v(connection)" "named_pipe" goto pipe, -
  166.   if equal "\v(connection)" "tcp/ip_telnet" goto socket, -
  167.   echo "ry not supported on \v(connection) connections.",-
  168.   end, -
  169.   :async, -
  170.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  171.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  172.        -protocol ymodem -directory \m(p_recv_dir) -receive, end, -
  173.   :pipe, -
  174.     !p.exe -type pipe -handle \v(ttyfd) -commbufs \m(p_commbufs) -
  175.        -filebuf \m(p_filebuf) -mileage -protocol ymodem -
  176.        -directory \m(p_recv_dir) -receive, end, -
  177.   :socket, -
  178.     !p.exe -type socket -handle \v(ttyfd) -telnet -commbufs \m(p_commbufs) -
  179.        -filebuf \m(p_filebuf) -mileage -protocol ymodem -
  180.        -directory \m(p_recv_dir) -receive, end
  181.  
  182. ; Send via Xmodem
  183. define sx -
  184.   if equal "\v(connection)" "serial" goto async, -
  185.   if equal "\v(connection)" "named_pipe" goto pipe, -
  186.   if equal "\v(connection)" "tcp/ip_telnet" goto socket, -
  187.   echo "sx not supported on \v(connection) connections.",-
  188.   end, -
  189.   :async, -
  190.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  191.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  192.        -protocol xmodem -send \%1, end, -
  193.   :pipe, -
  194.     !p.exe -type pipe -handle \v(ttyfd) -commbufs \m(p_commbufs) -
  195.        -filebuf \m(p_filebuf) -mileage -protocol xmodem -send \%1, end, -
  196.   :socket, -
  197.     !p.exe -type socket -handle \v(ttyfd) -telnet -commbufs \m(p_commbufs) -
  198.        -filebuf \m(p_filebuf) -mileage -protocol xmodem -send \%1, end
  199.  
  200. ; Receive via Xmodem
  201. define rx -
  202.   if equal "\v(connection)" "serial" goto async, -
  203.   if equal "\v(connection)" "named_pipe" goto pipe, -
  204.   if equal "\v(connection)" "tcp/ip_telnet" goto socket, -
  205.   echo "rx not supported on \v(connection) connections.",-
  206.   end, -
  207.   :async, -
  208.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  209.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  210.        -protocol xmodem -directory \m(p_recv_dir) -receive \%1, end, -
  211.   :pipe, -
  212.     !p.exe -type pipe -handle \v(ttyfd) -commbufs \m(p_commbufs) -
  213.        -filebuf \m(p_filebuf) -mileage -protocol xmodem -
  214.        -directory \m(p_recv_dir) -receive \%1, end, -
  215.   :socket, -
  216.     !p.exe -type socket -handle \v(ttyfd) -telnet -commbufs \m(p_commbufs) -
  217.        -filebuf \m(p_filebuf) -mileage -protocol xmodem -
  218.        -directory \m(p_recv_dir) -receive \%1, end
  219.  
  220. end 0
  221.  
  222. ; Support for async connections only when \v(connection) is not defined.
  223.  
  224. :ASYNCONLY
  225.  
  226. ; Send via Zmodem
  227. define sz -
  228.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  229.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  230.        -protocol zmodem -send \%1, end, -
  231.  
  232. ; Receive via Zmodem
  233. define rz -
  234.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  235.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  236.        -protocol zmodem -directory \m(p_recv_dir) -receive, end, -
  237.  
  238. ; Send via Ymodem-G
  239. define sg -
  240.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  241.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  242.        -protocol ymodem-g -send \%1, end, -
  243.  
  244. ; Receive via Ymodem-G
  245. define rg -
  246.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  247.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  248.        -protocol ymodem-g -directory \m(p_recv_dir) -receive, end, -
  249.  
  250. ; Send via Ymodem
  251. define sy -
  252.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  253.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  254.        -protocol ymodem -send \%1, end, -
  255.  
  256. ; Receive via Ymodem
  257. define ry -
  258.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  259.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  260.        -protocol ymodem -directory \m(p_recv_dir) -receive, end, -
  261.  
  262. ; Send via Xmodem
  263. define sx -
  264.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  265.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  266.        -protocol xmodem -send \%1, end, -
  267.  
  268. ; Receive via Xmodem
  269. define rx -
  270.     !p.exe -type async -handle \v(ttyfd) -speed \v(speed) -
  271.        -commbufs \m(p_commbufs) -filebuf \m(p_filebuf) -mileage -
  272.        -protocol xmodem -directory \m(p_recv_dir) -receive \%1, end, -
  273.  
  274. :p200end
  275.  
  276.