home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / archives / msr313src.zip / msiibm.ini < prev    next >
Text File  |  1988-12-21  |  6KB  |  155 lines

  1. ; MS-Kermit Initialization File for the IBM PC, XT, AT, PS2, etc.
  2. ; Requires MS-DOS Kermit 2.31 or later.  Won't work with earlier versions.
  3. ;
  4. ; For use with Columbia University systems.
  5. ;   By Christine Gianone, Vace Kundakci
  6. ;   December 1988
  7. ;
  8. ; See MSIIBM.DOC for an explanation of how to use the macros defined here.
  9. ; Rename this file to MSKERMIT.INI to make it your Kermit initialization file.
  10. ;
  11. ; Variables used:
  12. ;   \%c  VM/CMS User ID for CUVMB
  13. ;   \%u  UNIX User ID for CUNIXA-D
  14. ;   \%s  UNIX system selected through CUNIX terminal server: CUNIXA,CUNIXB,...
  15.  
  16. ; User IDs on various systems.  Substitute your own IDs.
  17. ;
  18. def \%c XYZCU          ; CMS ID
  19. def \%u xyz            ; UNIX ID
  20.  
  21. echo Columbia University IBM PC Kermit Initialization file...
  22.  
  23. ; General settings
  24. ;
  25. set warning on         ; Change this to "off" to allow overwriting of files.
  26. set speed 9600         ; Use 9600 bits per second by default
  27.  
  28. ; Behavior of INPUT command in script programs
  29. ;
  30. set input timeout quit ; Exit from script if input pattern not found
  31. set input echo on      ; Echo characters that arrive during INPUT
  32. set input case observe ; Match according to alphabetic case
  33.  
  34. ; Terminal emulation settings
  35. ;
  36. set term vt102         ; Emulate a DEC VT-102 terminal
  37. set term roll off      ; For use with Page Up / Page Down
  38. set term wrap on       ; Have Kermit automatically wrap lines at column 80
  39.  
  40. ; More DOS commands you can issue from the "Kermit-MS>" prompt.
  41. ;
  42. def edit run epsilon \%1   ; This lets you say "edit foo" at Kermit prompt.
  43. def more run more < \%1    ; Like TYPE, but pauses after each screen.
  44. def rename run ren \%1 \%2 ; DOS REN command.
  45.  
  46. ; Macros for connecting to different systems thru the IBM/Rolm CBX
  47. ;
  48. def cuvmb  do cbx,o c cuvm\13,  i 10 PLETE,      do 3695, o vmb\13, do 4381
  49. def cuvml  do cbx,o c cuvm\13,  i 10 PLETE,      do 3695, o vml\13, do 4381
  50. def simb   do cbx,o c simb\13,  i 10 PLETE, pau, do 7171, do 3270
  51. def siml   do cbx,o c siml\13,  i 10 PLETE, pau, do 7171, do 3270
  52. def clio   do cbx,o c clio\13,  i 10 PLETE, pau, do 7171, do clog
  53. def cunix  do cbx,o c cunix\13, i 10 PLETE, pau, do cuts, do unix
  54. def cunixa def \%s cunixa,do cunix
  55. def cunixb def \%s cunixb,do cunix
  56. def cunixc do cbx,o c cunixc\13,i 10 PLETE, pau, out \13, do unix
  57. def cunixd def \%s cunixd,do cunix
  58.  
  59. ; Sample macro for high-speed PC-to-PC direct connection on port 2
  60. ; Assumes you have your COM2 connected with a null modem cable to
  61. ; another PC.  The PC/AT, PS/2, and compatibles can run at this speed.
  62. ;
  63. def pc set port 2,set sp 57600,set par non,set flow xon,set hand none
  64.  
  65. ; Macros for navigating thru front end and login prompts
  66. ;
  67. def cbx  do def,o \13,i 10 MODIFY?                          ; IBM/Rolm CBX
  68. def 3695 i 5 ING CHARACTERS:\32\32                          ; COMTEN
  69. def 7171 pau,cle,o \13,i 5 TERMINAL TYPE:\32,o vt-100\13    ; 7171 front end
  70. def 4381 do vml,i 5 BREAK KEY,o \b,i 5 .\17,o LOG \%c\13,c  ; VM/CMS linemode
  71. def 3270 pau,cle,o \13,o L \%c\13,do vmf,c                  ; VM/CMS fullsc.
  72. def clog pau,cle,o \13,o CLIO\9,pause,o CLIO\13,do vmf,c    ; CLIO login
  73.  
  74. ; CU Terminal Servers (cutsa, cutsb, etc)
  75. ; Send carriage return, look for ">" prompt.  Try 8 times (for speed
  76. ; recognition), then give up.
  77. ;
  78. def cuts set inp tim p,out \13,pau,-
  79. set co 8,:loop ,out \13,i 3 >,if suc goto ok,if count goto loop,-
  80. ech Failed,stop,:ok ,out \%s\13,set inp tim q
  81.  
  82. ; UNIX login with speed matching
  83. ;
  84. def unix set inp timeout proc,-
  85. set count 8,:loop ,out \13,i 5 login:\32,if suc goto ok,-
  86. if count goto loop,ech Failed,stop,:ok ,out \%u\13,do dec,-
  87. set inp tim q,connect
  88.  
  89. ; Macros for interacting with different systems:
  90. ; . set parity appropriately,
  91. ; . make <- Backspace key send appropriate deletion character,
  92. ; . make Ctrl-C send appropriate interruption character.
  93. ;
  94. def vml do tty,set par m,set k \270 \8,  set k \3 \Kbreak    ; VM linemode
  95. def vmf do def,set par e,set k \270 \8\4,set k \3 \3,do simk ; VM fullscreen
  96. def dec do def,set par n,set k \270 \127,set k \3 \3         ; DEC, SUN, etc
  97.  
  98. def def set tim of,set loc of,set hand non,set flow xon,do nosimk ; Default
  99. def tty set tim on,set loc on,set hand xon,set flow non,do nosimk ; IBM TTY
  100.  
  101. ; Macro to dial CBX from Hayes or compatible modem at 1200 bps.
  102. ; Change 1200 to 2400 if dialing at 2400 bps.
  103. ;
  104. def hcbx do dec,set sp 1200,o \13,o AT\13,i OK,o ATDT 8541812,i CONNECT
  105. def hxc do hcbx, do xcunixc ; Make similar macros for other systems.
  106.  
  107. ; Sample Key relocations, ones that you want in effect all the time.
  108. ; . Toggle mode line on keypad plus key
  109. ; . Put ESC on Tab key
  110. ; These are defined in a macro, so that they can be restored by "nosimk".
  111. ;
  112. def defk set key \334 \Kmodeline, set key \271 \27
  113. do defk
  114.  
  115. ; Key definitions for using the 7171 3270 simulator, e.g. with CLIO.
  116. ; Just type "do simk" to invoke them.
  117. ; Type "do nosimk" to restore all default key definitions.
  118. ;
  119. def simk do sk1, do sk2, do sk3, do sk4
  120. def nosimk set key clear, do defk
  121.  
  122. ; F1 sends ESC 1 (PF1), F2 sends ESC 2 (PF2), etc.
  123. def sk1  set k \315 \{27}1,set k \316 \{27}2,set k \317 \{27}3,do sk1b
  124. def sk1b set k \318 \{27}4,set k \319 \{27}5,set k \320 \{27}6,do sk1c
  125. def sk1c set k \321 \{27}7,set k \322 \{27}8,set k \323 \{27}9,do sk1d
  126. def sk1d set k \324 \{27}0
  127.  
  128. ; Shift F1 sends ESC Q (PF11), etc. (letters from top row of keyboard)
  129. def sk2  set k \852 \27Q,set k \853 \27W,set k \854 \27E,do sk2b
  130. def sk2b set k \855 \27R,set k \856 \27T,set k \857 \27Y,do sk2c
  131. def sk2c set k \858 \27U,set k \858 \27I,set k \860 \27O,set k \861 \27P
  132.  
  133. ; Alt-F1 thru Alt-F4 are like PF21 thru PF24 (letters from second row)
  134. def sk3 set k \2408 \27A, set k \2409 \27S,set k \2410 \27D,set k \2411 \27F
  135.  
  136. ; Ins key sends Ctrl-X,Keypad Del sends Ctrl-D.
  137. ; Arrows: up = Ctrl-P, Left = Ctrl-H, Right = Ctrl-E, Down = Ctrl-N
  138. def sk4 set k \338 \24,set k \840 \16,set k \331 \08,set k \333 \05,do sk4b
  139. def sk4b set k \336 \14,set k \339 \04
  140.  
  141. ; Colors
  142.  
  143. define amy   set term color 1 31 45  ; pink on purple
  144. define ocean set term color 0 37 44  ; white on blue
  145. define sky   set term color 0 34 47  ; blue on white
  146. define sea   set term color 0 32 44  ; green on blue
  147. define gb    set term color 0 32 40  ; green on black
  148. define bw    set term color 0 30 47  ; black on white
  149.  
  150. ; Set desired color, greet, and start.
  151.  
  152. set terminal color 10 ; Fast screen updating
  153. do sky
  154. echo \13Smile!
  155.