Program data syntax rules
Program data conveys a variety of types of parameter information related to
the command header. At least one space must separate the command header
or query header from the program data.
<program mnemonic><separator><data><terminator>
When a program mnemonic or query has multiple program data, a comma
separates sequential program data.
<program mnemonic><separator><data>,<data><terminator>
For example, :DISPlay:PIXel 10,12,2 has three program data: 10, 12, and 2.
There are two main types of program data used in commands: character and
numeric program data.
Character Program Data
Character program data conveys parameter information as alpha or
alphanumeric strings. For example, the :TIMebase:MODE command can be
set to normal or delayed. The character program data in this case may be
NORMal or DELayed. The command :TIMebase:MODE DELayed sets the
time base mode to delayed.
The available mnemonics for character program data are always included
with the instruction’s syntax definition. When sending commands, either the
long form or short form (if one exists) may be used. Uppercase and
lowercase letters may be mixed freely. When receiving query responses,
uppercase letters are used exclusively.
Numeric Program Data
Some command headers require program data to be expressed numerically.
For example, :TIMebase:RANGe requires the desired full-scale range to be
expressed numerically.
For numeric program data, you have the option of using exponential notation
or using suffix multipliers to indicate the numeric value. The following
numbers are all equal:
28 = 0.28E2 = 280e-1 = 28000m = 0.028K = 28e-3K
When a syntax definition specifies that a number is an integer, it means that
the number should be whole. Any fractional part would be ignored,
truncating the number. Numeric data parameters that accept fractional
values are called real numbers.
Introduction to Programming
Program data syntax rules
18
Содержание 54620A
Страница 6: ...6 ...
Страница 9: ...1 Introduction to Programming ...
Страница 21: ...2 Programming Getting Started ...
Страница 35: ...3 Programming over HP IB ...
Страница 40: ...40 ...
Страница 41: ...4 Programming over RS 232 C ...
Страница 48: ...48 ...
Страница 49: ...5 Programming and Documentation Conventions ...
Страница 53: ...Programming and Documentation Conventions The command tree 53 ...
Страница 60: ...60 ...
Страница 61: ...6 Status Reporting ...
Страница 63: ...Status Reporting Data Structures Figure 4 Status Reporting 63 ...
Страница 68: ...68 ...
Страница 69: ...7 Installing and Using the Programmer s Reference ...
Страница 76: ...76 ...
Страница 77: ...8 Programmer s Quick Reference ...