📄 ckcbwr.txt
字号:
cannot be included in a C string, since it is the C string terminator.If you really want to output a backslash followed by a B, an L, or an N (as isneeded to configure certain modems, etc), use "output \\B".In C-Kermit 6.1 or later, you can disarm and re-arm the special OUTPUT-commandescapes (\B, \L, and \N) with SET OUTPUT SPECIAL-ESCAPES { OFF, ON }.(3) MULTIPLE SESSIONSC-Kermit does not support multiple sessions. When you SET LINE (or SET PORT,same thing) to a new device, or SET HOST to a new host, the previous SET LINEdevice or network host connection is closed, resulting in hangup of the modemor termination of the network connection. In windowing environments likeHP-VUE, NeXTSTEP, OS/2, etc, you can run separate copies of Kermit in differentwindows to achieve multiple sessions.To achieve multiple sessions through a single serial port (e.g. when dialingup), you can install SLIP or PPP on your computer and then use C-Kermit'sTCP/IP support over the SLIP or PPP connection, assuming you also haveTCP/IP networking installed on your computer.On UNIX systems that support the "term" program, you can establish aconnection to another UNIX system with C-Kermit and then achieve multiplesessions using "term" client programs like trsh (see ckubwr.txt and the termdocumentation for details).(4) NETWORK COMMUNICATIONThe most frequently asked question in many newsgroups is "Why does it takesuch a loooong time to make a telnet connection to (or from) my (e.g.) LinuxPC?" (this applies to C-Kermit or to regular Telnet). This question hastwo answers, one of them specific to C-Kermit 7.0: 1. Most telnet servers nowadays perform reverse DNS lookups on the client (for security and/or logging reasons). If the Telnet client cannot be found by the local DNS server, the DNS request goes out to the Internet at large, and this can take quite some time. The solution to this problem is to make sure that both client and host are registered in DNS. 2. C-Kermit 7.0 strictly enforces Telnet protocol rules. One such rule is that all negotiations must be responded to. If C-Kermit sends a negotiation and the host does not respond, C-Kermit will wait a long time for the reply (in case the network is congested or the host is slow), but eventually will time out. To eliminate the waits (and therefore risk possible protocol mismatches -- or worse -- between Telnet client and server), tell C-Kermit to SET TELNET WAIT OFF (or include the /NOWAIT switch with the TELNET command).C-Kermit itself performs reverse DNS lookups unless you tell it not to. Thisis to allow C-Kermit to let you know which host it is actually connected toin case you have made a connection to a "host pool" (multihomed host). Youcan disable C-Kermit's reverse DNS lookup with SET TCP REVERSE-DNS-LOOKUP OFF.In multiuser operating systems such as UNIX and VMS, TCP/IP RLOGIN connectionsare available only to privileged users, since "login" is a privileged socket.And assuming you are allowed to use it in the first place, it is likely tobehave differently depending on what type of host you are rlogging in to, dueto technical reasons having to do with conflicting interpretations of RFC793(Out-Of-Band Data) and Rlogin (RFC1122)... "Specifically, the TCP urgentpointer in BSD points to the byte after the urgent data byte, and anRFC-compliant TCP urgent pointer points to the urgent data byte. As a result,if an application sends urgent data from a BSD-compatible implementation to anRFC-1122 compatible implementation then the receiver will read the wrongurgent data byte (it will read the byte located after the correct byte in thedata stream as the urgent data byte)." Rlogin requires the use of OOB datawhile Telnet does not. Therefore, it is possible for Telnet to work betweenall systems while BSD and System V TCP/IP implementation are almost always abad mix.On a TCP/IP TELNET connection, you should normally have PARITY set to NONE and(except in VMS C-Kermit) FLOW-CONTROL also set to NONE. If file transfer doesnot work with these settings (for example, because the remote TELNET serveronly gives a 7-bit data path), use SET PARITY SPACE. Do not use SET PARITYMARK, EVEN, or ODD on a TELNET connection -- it interferes with TELNETprotocol.If echoing does not work right after connecting to a network host or afterdialing through a TCP/IP modem server, it probably means that the TELNETserver on the far end of the connection is executing the TELNET protocolincorrectly. After initially connecting and discovering incorrect echoing(characters are echoed twice, or not at all), escape back, give theappropriate SET DUPLEX command (FULL or HALF), and then CONNECT again.For a consistently misbehaving connection, you can automate this process ina macro or TAKE file.TELNET sessions are treated just like serial communications sessions as far as"terminal bytesize" and "command bytesize" are concerned. If you need to viewand/or enter 8-bit characters during a TELNET session, you must tell C-Kermitto SET TERMINAL BYTESIZE 8, SET COMMAND BYTESIZE 8, and SET PARITY NONE.If you SET TERMINAL DEBUG ON or SET DEBUG SESSION (same thing), TELNETprotocol negotiations will be displayed on your screen. But most of theinteresting negotiations happen at the time the SET HOST or TELNET commandis given, before CONNECT mode is entered, so you won't see them on yourscreen. However, you can still capture them in the debug log ("log debug").C-Kermit version 6.0 has a new set of SET TCP commands, to control TCP-levelparameters, such as "keepalive" protocol (that allows C-Kermit to detectmore quickly and reliably when a connection is broken). Use SHOW NET to seetheir values and SET TCP to change them.(5) THE SERVICES DIRECTORYIs explained fully in "Using C-Kermit", 2nd Edition, Chapter 7.(6) MODEMS AND DIALINGWarning: Some phone companies are eliminating the busy signal. Instead,they issue a voice message such as "press 1 to automatically redial untilthe number answers, or...". Obviously this is a disaster for modem calls.If your service has this feature, there's nothing Kermit can do about it.Your modem will respond with NO CARRIER rather than BUSY, and Kermit willdeclare the call a failure, rather than trying to redial the same number.The list of modem types supported by C-Kermit is obtained by typing: set modem type ?at the C-Kermit> prompt. Note that the ITU-T (V.25bis) modem type issupported only in asynchronous mode, not synchronous (HDLC) mode -- there isno support in C-Kermit for synchronous communication (except for SET NET X.25,which is only available on certain platforms).If a built-in modem type doesn't work for you, and the modem is a modernhigh-speed (data compressing, error correcting) modem that uses the Hayes ATcommand set, try: SET MODEM TYPE GENERIC-HIGH-SPEEDModems can be used by C-Kermit only when they are visible as or through aregular serial port device. Note that certain modems can not be used in thisnormal way on many kinds of computers: Winmodems, RPI modems, Controllerlessmodems, the IBM Mwave, etc; all of these require special drivers that performsome, most, or all of the modem's functions in software. Such drivers aregenerally NOT available in UNIX or other non-Windows (or non-OS/2, in the caseof the Mwave) platforms.An important change in C-Kermit 6.0 is that when you give a SET MODEM TYPEcommand to tell Kermit what kind of modem you have, Kermit also sets a numberof other modem-related parameters automatically from its internal modemdatabase. Thus, the order in which you give modem-related commands issignificant, whereas in prior releases they could be given in any order.In particular, MODEM SPEED-MATCHING is set according to whether the modemis known to be capable of speed buffering. SET MODEM TYPE HAYES-2400automatically turns SPEED-MATCHING ON, because when the Hayes 2400 reportsa particular speed in its CONNECT message, that means its interface speedhas changed to that speed, and C-Kermit's must change accordingly if it isto continue communicating. This might cause some confusion if you use"set modem type hayes" for dialing a more advanced type of modem.The new default for flow control is "auto", meaning "do the right thing".So (for example) if your version of C-Kermit supports SET FLOW RTS/CTS andyour modem also supports RTS/CTS, then Kermit will automatically set itsflow control to RTS/CTS *and* set modem's flow control to RTS/CTS too beforeattempting to use the modem.For this reason, don't assume that "set modem type hayes" should be used forany modem that uses the Hayes AT command set. "set modem type hayes" reallydoes mean Hayes 1200 or 2400, which in turn means no hardware flow control,and no speed buffering. This choice will rarely work with a modern high-speedmodem.(7) DIALING HINTS AND TIPSIf you want to dial a number that starts with #, you'll need to quote the"#" character (as \# or \{35}), since it is also a comment introducer: C-Kermit>dial #98765421-1-212-5551212 ; Looks like a comment ?You must specify a number to dial C-Kermit>dial \#98765421-1-212-5551212 ; Works OKWhen using a dialing directory, remember what happens if a name is not found: C-Kermit>dial xyzcorp Lookup: "xyzcorp" - not found - dialing as givenThis normally does no harm, but some modems might behave strangely when givendial strings that contain certain letters. For example, a certain Germanmodem treats any dial string that contains the letter "s" as a command tofetch a number from its internal list, and replies OK to the ATD command,which is normally not a valid response except for partial dialing. To avoidthis situation, use: lookup xyzcorp if success dialRemember: In many C-Kermit implementations (depending on the underlyingoperating system -- mostly Windows, OS/2, and System-V-based UNIX versions,and in C-Kermit 6.1, also VMS), you can't CONNECT to a modem and type themodem's dialing command (like "ATDT7654321") manually, unless you first tellC-Kermit to: SET CARRIER-WATCH OFFThis is because (in these implementations), the CONNECT command requires themodem's Carrier Detect (CD) signal to be on, but the CD signal doesn't come onuntil after dialing is complete. This requirement is what allows C-Kermit topop back to its prompt automatically when the connection is hung up. See thedescription of SET CARRIER-WATCH in "Using C-Kermit".Similarly, if your dialed connection drops when CARRIER-WATCH is set to AUTOor ON, you can't CONNECT back to the (now disconnected) screen to see whatmight have happened unless you first SET CARRIER-WATCH OFF.Don't SET FLOW RTS/CTS if your modem is turned off, or if it is not presentingthe CTS signal. Otherwise, the serial device driver might get stuck waitingfor this signal to appear.The HANGUP command has no effect when C-Kermit is in remote mode. This ison purpose. If C-Kermit could hang up its own controlling terminal, thiswould (a) most likely leave behind zombie processes, and (b) pose a securityrisk.If you have a high-speed, error-correcting, data-compressing, speed-bufferingmodem, you should fix the modem's interface speed as high as possible,preferably (at least) four times higher than its maximum connection(modulation) speed to allow compression to work at full advantage. In thistype of setup, you must also have an effective means of flow control enabledbetween C-Kermit and the modem, preferably hardware (RTS/CTS) flow control.On platforms that do not support hardware flow control, it is usually possibleto select software flow control (Xon/Xoff), and C-Kermit will do its best toset the modem for local Xon/Xoff flow control too (but then, of course,Ctrl-S and Ctrl-Q characters can not be transmitted on the connection).C-Kermit knows about a large number of modems, depending on how it was built(type "set modem type ?" and "show features" for further info). Thisknowledge is imbedded in the SET MODEM and DIAL commands. If you are havingtrouble dialing your modem, SET DIAL DISPLAY ON to watch the dialinginteractions between C-Kermit and your modem. Consult Chapters 3-4 of "UsingC-Kermit" (2nd Ed) for modem-dialing troubleshooting instructions.If it takes your call longer to be completed than the timeout interval thatC-Kermit calculates, you can use the SET DIAL TIMEOUT command to overrideC-Kermit's value. But beware: the modem has its own timeout for completingthe call. If it is a Hayes-like modem, C-Kermit adjusts the modem's valuetoo by setting register S7. But the maximum value for S7 might be smallerthan the time you need! In that case, C-Kermit sets S7 to 0, 255, or other(modem-specific) value to signify "no timeout".WARNING: Certain modems might have a maximum dial timeout shorter than whatKermit expects it to be. If Kermit attempts to set register S7 to a valuehigher than your modem's maximum, the modem will say "ERROR" and you will geta "Failure to initialize modem" error. In that case, use SET DIAL TIMEOUT tooverride C-Kermit's calculation of the timeout value with the highest valuethat is legal for your modem, e.g. 60.If you DIAL a modem, disconnect, then SET HOST or TELNET, and then HANGUP,Kermit sends the modem's hangup command, such as "+++ATHO". There is no goodway to avoid this, because this case can't reliably be distinguished from thecase in which the user does SET HOST <terminal-server>, SET MODEM TYPE <name>,DIAL. In both cases we have a valid modem type selected and we have a networkconnection. If you want to DIAL and then later make a regular networkconnection, you will have to SET MODEM TYPE NONE or SET MODEM HANGUP RS232 toavoid this phenomenon.The SET MODEM KERMIT-SPOOF command works only for Telebit and US Roboticsmodem types; it is OFF by default. You may wish to experiment with largepackets (1K or greater) and various window sizes with spoofing disabled in themodem. In most situations the transfer rates achieved by Kermit with slidingwindows and long packets are better than with protocol spoofing turned on.Also, attribute (A) packets are not passed by Telebit modems with spoofingenabled so if they are desired spoofing must be turned off.Some modems have a feature called adaptive dialing. When they are told todial a number using Tone dialing, they check to make sure that dialtone hasgone away after dialing the first digit. If it has not, the modem assumes thephone line does not accept Tone dialing and so switches to Pulse. Whendialing out from a PBX, there is almost always a secondary dialtone.Typically you take the phone off-hook, get the PBX dialtone, dial "9" to getan outside line, and then get the phone company's dialtone. In a situationlike this, you need to tell the modem to expect the secondary dialtone. OnHayes and compatible modems, this is done by putting a "W" in the dial stringat the appropriate place. For example, to dial 9 for an outside line, andthen 7654321, use ATDT9W7654321. In Kermit 95, this is accomplished with: SET PBX-OUTSIDE-PREFIX 9W(replace "9" with whatever your PBX's outside-line prefix is).DEC modems... Reportedly, these don't work right when connected to a DECterminal server -- result codes are never reported (on the other hand, thismight be a modem configuration problem). Dialing "by hand", "blind" stillworks. Also, reportedly "For people who do have DEC modems directly connectedto DEC computers the DF03, DF100-series, and DF200-series modem dialers shouldwork. The only thing that is not straightforward is that the DF124-CA,DF124-CM modems must use the DF200-series since they speak Digital ModemCommand Language (DMCL) and AT commands. The Digital Scholar Plus is a DF242so it uses the DF200-series."If C-Kermit's dialing methods are insufficient for your purposes, you canwrite a C-Kermit script program to do the dialing.(7.1) DIALING AND FLOW CONTROL
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -