13-13
IM 253421-01E
13
Communication Commands1 (System of Commands before the 488.2-1987 Standard)
13.2 Sample Program
Before Programming
This section describes sample programs for a IBM PC/AT and compatible system with
National Instruments GPIB-PCIIA board installed. Sample programs in this manual are
written in Quick BASIC version 4.0/4.5
Programming Format
The programming format for this instrument is as follows.
C Par Terminator
The used codes are ASCII codes.
Example
DA
2
CR LF
command
parameter
terminator
Commands
One to three capital characters are used to designate a command.
Parameters
Characters or numericals are in ASCII code.
Terminator
• For GP-IB:
When this instrument is set to listener mode, either [CR+LF], [LF], or [EOI] can be
used as the terminator.
When this instrument is set to talker mode, the terminator set using the DL
command becomes valid. See page 13-2.
• For RS-232-C:
See page 11-8 and 13-2.
Sending Several Commands
You can express several commands on one line. In such a case, enter a “;”
(semicolon) between two commands (c parameter).
Note
It makes no difference whether a space, tab or similar is entered between command and
parameter.
Query
A command followed by a “?” (question mark) is called a query command. When such
a command is sent, the current data will appear.
Query
Current data
DA?
⇒
DA1
Parameter Values
Up to 5 digits after the decimal point will be recognized.