Keithley 194 Instruction Manual page 119

High speed voltmeter
Table of Contents

Advertisement

IEEE-488 PROGRAMMING
Obtaining
Data
Before the instrument
will transmit its data string, it must
be properly addressed to talk by the controller. The basic
controller
sequence for requesting
data is as follows:
1. The controller
sets the ATN line true.
2. The Model 194 is addressed to talk by placing the ap-
propriate talk command byte on the data lines. For the
default primary address (9), the correct talk command
byte is $49.
3. The controller
places the ATN line false.
4. The controller
then begins its input sequence and in-
puts data bytes in succession until all are taken. General-
ly, the sequence will cease when
the terminator
is
detected. Some controllers
terminate on EOI.
Generally, data is placed into a string or numeric variable
as the bytes are received. For example, a typical sequence
for the HP-85 computer
is:
In this instance, the complete reading string is placed in
the A$ variable. In cases where numeric input is required,
the instrument
should be operated in a mode without
a
prefix and suffix (Gl or G4, for example). Under these con-
ditions,
readings can be placed directly
into a numeric
variable as in the example below
A is the variable into which the numeric value is placed.
If the prefix and suffix are not eliminated
with the correct
G command,
an incorrect value may be placed into the
numeric variable.
In the G6 and G7 (binary modes), data bytes can be placed
into a string variable in a similar manner. However, some
form of algorithm
must be used to convert
data into
displayable
form. Consult
your controller's
instruction
manual for details.
HP-65 Programming
Example-Use
the following
program
to obtain and display an instrument
data string.
COMMENTS
Place instrument
in
rel"ote.
Select data format,
aveiagc mode.
Get reading fn,m
instrument.
Display the reading.
In this program, the instrument
is first placed in remote
(line Id), and several operating
mod&
arc then prw
grammed. 'The instrument
is placed in the GO data ior-
mat, average, and correct reading modes (line 20). x~ri d.&l
is then requested (line 30) and displayed
(line 40). Sot?
that data with prefix, without
suffix is displayed because
the instrument
is in the GO mode.
Model
8573 Programming
Example-Add
the following
lines to the modified declaration file paragraph (4.6.3) and
run the resulting program to obtain and display an instru-
ment data string.
In the above program, the instrument
is placed in rem<jtc
(line 10) and then programmed for data format, wav~fwn~,
and reading modes (line 20). A rwding
is then rcquestcd
(line 40) and then displayed
(line SO).
4-29

Advertisement

Table of Contents
loading

Table of Contents