"Hugo Cornwall "The Hacker's handbook"" - читать интересную книгу автора

protocol: this means that when the user sends a character to the host
computer, the host immediately sends back the same character to the
user's computer, by way of confirmation. What the user sees on his
computer screen, therefore, has been generated, not locally by his
direct action on the keyboard, but remotely by the host computer.
(One effect of this is that there may sometimes be a perceptible
delay between keystroke and display of a letter, particularly if you
are using a packet-switched connection--if the telephone line is
noisy, the display may appear corrupt). This echoing protocol is
known as full duplex, because both the user's computer and the host
are in communication simultaneously.
However, use of full duplex/echo is not universal, and all
terminal emulators allow you to switch on and off the facility. If,
for example, you are talking into a half-duplex system (i.e. no
echo), your screen would appear totally blank. In these
circumstances, it is best if your software reproduces on the screen
your keystrokes.
However, if you have your computer set for half-duplex and the host
computer is actually operating in full duplex. each letter will
appear twice--once from the keyboard and once, echoing from the host,
ggiiwiinngg tthhiiss ssoorrtt ooff eeffffeecctt. Your terminal
emulator needs to able to toggle between the two states.

Data Format/Parity Setting - In a typical asynchronous protocol, each
character is surrounded by bits to show when it starts, when it ends,
and to signify whether a checksum performed on its binary equivalent
comes out even or odd. The character itself is described, typically,
in 7 bits and the other bits, start, stop and parity, bringing the
number up to 10. (See chapter 2.) However, this is merely one very
common form, and many systems use subtle variants -- the ideal
terminal emulator software will let you try out these variants while
you are still on line. Typical variants should include:


Word length Parity No stop bits


7 Even 2
7 Odd 2
7 Even 1
7 Odd 1
8 None 2
8 None 1
8 Even 1
8 Odd 1


(NB although the ASCII character set is 7 bit, 8 bits are sometimes
transmitted with a ~padding~ bit; machine code instructions for 8-bit
and 16-bit machines obviously need 8-bit transmissions.)