IBM 7220 Car Amplifier User Manual


 
6-5
Chapter 6, COMPUTER OPERATION
Because of the parallel nature of the GPIB and its very effective use of the control
lines including the implementation of a three-wire handshake (see below),
comparatively high data rates are possible, up to a few hundred thousand bytes per
second. In typical setups the data rate of the GPIB itself is not the factor that limits
the rate of operation of the control program.
6.3.08 Handshaking and Echoes
A handshake is a method of ensuring that the transmitter does not send a byte until
the receiver is ready to receive it, and, in the case of a parallel interface, that the
receiver reads the data lines only when they contain a valid byte.
GPIB Handshaking
The GPIB interface includes three lines (*DAV, *NRFD, *NDAC) which are used to
implement a three-wire handshake. The operation of this is completely defined by the
IEEE-488 standard and is fully automatic, so that the user does not need to know
anything about the handshake when writing programs for the GPIB. Note that each
command must be correctly terminated.
RS232 Handshaking
In the RS232 standard there are several control lines called handshake lines (RTS,
DTR outputs and CTS, DSR, DCD inputs) in addition to the data lines (TD output
and RD input). However, these lines are not capable of implementing the handshaking
function required by the model 7220 on a byte-by-byte basis and are not connected in
the model 7220 apart from the RTS and DTR outputs which are constantly asserted.
Note that some computer applications require one or more of the computer’s RS232
handshake lines to be asserted. If this is the case, and if the requirement cannot be
changed by the use of a software switch, the cable may be used in conjunction with a
null modem. A null modem is an adaptor which connects TD on each side through to
RD on the other side, and asserts CTS, DSR, and DCD on each side when RTS and
DTR are asserted on the other side.
With most modern software there is no need to assert any RS232 handshake lines and
a simple three-wire connection can be used. The actual handshake function is
performed by means of bytes transmitted over the interface.
The more critical handshake is the one controlling the transfer of a command from the
computer to the lock-in amplifier, because the computer typically operates much
faster than the lock-in amplifier and bytes can easily be lost if the command is sent
from a program. (Note that because of the limited speed of human typing, there is no
problem in the terminal mode.) Therefore an echo handshake is used, which works in
the following way: after receiving each byte, the lock-in amplifier sends back an echo,
that is a byte which is a copy of the one that it has just received, to indicate that it is
ready to receive the next byte. Correspondingly, the computer does not send the next
byte until it has read the echo of the previous one. Usually the computer makes a
comparison of each byte with its echo, and this constitutes a useful check on the
validity of the communications.
Where the echo is not required, it can be suppressed by negating bit 3 in the RS232