Reading Hp-Ib Messages - HP 8340B Operating Instructions Manual

Synthesized sweepers
Hide thumbs Also See for 8340B:
Table of Contents

Advertisement

The secondary command DATA sets the ATN line False; all other secondary commands (CMD, TALK,
LISTEN, UNL, MLA, and MTA) set ATN True. Information accompanying the SEND statement can be
either ASCII encoded characters that correspond to the HP-IB functions (see Table 3-3), or computer-
recognized mnemonics. For example, to read the status bytes from the HP 8340B/41B, the HP-IB
sequence is:
UNL
MLA (the computer's) TAD (HP 8340B/41B's)
SPE
(data bytes) SPD
UNT
This sequence is accomplished, in BASIC, by using either computer-recognized mnemonics:
100
SEND 7; UNL
MLA
TALK 19
CMD 24
110
ENTER 7 USING
120
SEND 7; CMD 25
UNT
where CMB 24 is SPE, and CMD 25 is SPD; or the same sequence can be accomplished using ASCII
encoded HP-IB information:
100
SEND 7; CMD M?5S"&CHR$<24>
110
ENTER 7 USING "#,B" ; S
120
SEND 7; CMD CHR$(25)&M_"
In line 100, ? is the ASCII code for UNL, 5 is a representative MLA, and S is TA19. In line 120, "
(underscore) is the ASCII code for UNT. In both examples the ATN line is set True or False by tfTe
computer, depending on the context of the mnemonics, and does not require any specific commands.
(This is an illustrative example only; status bytes can be more easily read using a simple OUTPUT
"OS" statement.)
Reading HP-IB Messages
The HP-IB lines are read by examining the computer's status registers, using the STATUS statement.
The STATUS statement has this syntax:
The function assignment of each status register is computer specific. Figure 3-27 shows represen¬
tative status register assignments, from the HP 9826 and HP-85A computers.
HP 8340B/41B
Operating Information
3-93

Advertisement

Table of Contents
loading

This manual is also suitable for:

8341b

Table of Contents