GPIB
4-14 370B User Manual
A useful addressing variation assigns the 370B address to a variable and uses
that variable in place of the specific numeric address. In the following examples,
the address is set to “6”. This method works for both the example controllers
when running BASIC and allows the destination of several commands to be
altered by changing only the value of one variable: this is the scheme used in the
IBM PC with the GURU card , running BASICA.
Hewlett Packard 2001300 Series:
720 DEVICE=706
730 OUTPUT DEVICE;”250,250,750,750”,END
or
720 ASSIGN @DEVICE TO 706
730 OUTPUT @DEVICE;”WIN 250,250,750,750”,END
The examples in Table 4–2 shown how the syntax of several different controllers
can vary.
Table 4-2: Controller Output Syntax
Controller Language Output Command
IBM PC with BASICA WRT$=string"
CALL
IBWRT(DEV%,WRT$)
HP 200/300 SERIES BASIC OUTPUT 710;STRING",END
HP 9825/200ĆSERIES HPL wrt 710,string"
Commands with a question mark (?) are query commands which solicit
information from the 370B. After the controller sends a query command, it must
acquire the resulting response from the 370B. Examples using the HOR? query
command follow. IBM PC:
IBM PC:
150 WRT$=”HOR?”
160 CALL IBWRT(DSO%,WRT$) ’Send query.
170 RD$+SPACE$(100)
180 CALL IBRD(DSO%,RD$) ’Input responses.
Hewlett Packard 2001300 Series:
150 DIM SET$(100)
160 OUTPUT 710;”HOR?”,END
170 ENTER 710;SET$
Sending Queries and
Receiving Responses