4-1
IM 701310-17E
Before Programming
1
2
3
4
5
6
App
Index
4.1 Messages
Program Message Unit Format
The program message unit format is shown below
,
<Program header>
<Program data>
Space
<Program Header>
The program header indicates the command type. For
details, see page 4-3.
<Program Data>
If certain conditions are required in executing a
command, program data is added. A space (ASCII
code “20H”) separates the program data from the
header. If there are multiple sets of program data, they
are separated by commas (
,
).
For details, see page 4-5.
Example
:ACQuire:MODE NORMal<PMT>
Header
Data
Response Messages
The response message format is shown belo.
<RMT>
;
<Response message unit>
<Response Message Unit>
A response message consists of one or more
response message units; each response message unit
corresponds to one response.
Response message units are separated by a semicolon
(
;
).
For details regarding the format of the response
message unit, see the next section.
Exampe
Unit
Unit
:ACQUIRE:MODE NORMAL;HRMode 1<RMT>
<RMT>
A response message terminator. It is
NL^EOM
.
Messages
Messages are used to exchange information between
the controller and the instrument. Messages that are
sent from the controller to the instrument are called
program messages and messages that are sent
back from the instrument to the controller are called
response messages.
If a program message contains a message unit that
requests a response (a query), the instrument returns
a response message upon receiving the program
message. A single response message is always
returned in response to a single program message.
Program Messages
The program message format is shown below
<PMT>
;
<Program message unit>
<Program Message Unit>
A program message consists of one or more program
message units; each unit corresponds to one
command. The instrument executes the received
commands in order.
Each program message unit is separated by a
semicolon (
;
).
For details regarding the format of the program
message unit, see the next section.
Example
Unit
Unit
:ACQuire:MODE NORMal;HRMode 1<PMT>
<PMT>
PMT is a program message terminator. The following
three types are available.
NL
(New Line):
Same as LF (Line
Feed). ASCII code “0AH”
^EOM
:
The END message as defined by USBTMC
(The data byte that is sent simultaneously
with the END message is the last data of the
program message.)
NL^EOM
: NL with an END message added
(NL is not included in the program
message.)
Chapter 4
Before Programming