![Tektronix 2714 Скачать руководство пользователя страница 200](http://html1.mh-extra.com/html/tektronix/2714/2714_programmers-manual_1077901200.webp)
Programming
6–2
2714 & 2715 Programmer Manual
RS-232 Program Examples
This section contains two RS-232 program examples:
H
Talk/Listen Demo Program (Example 6–1)
H
CATV XMOD Command Demo Program (Example 6–2)
NOTE
. The 2714 or 2715 must have a spectral display on its screen when these
programs are executed. If the 2714 or 2715 is displaying a menu when either
program is executed, the program will not run properly.
The Talk/Listen Demo Program accepts single commands or queries, and
performs the command function or returns the query response.
The CATV XMOD Command Demo Program executes the
CATV XMOD
command, and displays the test data in a single-column format.
These interactive programs include extensive error checking and a friendly
human interface. The code clearly defines program variables and their use, and
subroutine linkage. The code also contains useful comments that clarify program
requirements.
Each example program configures the 2714 or 2715’s RS-232 interface to use the
VERBOSE mode (see Verbose Mode and Error Handling on page 1–9). As a
result, the 2714 or 2715 sends a response back to the program for each command
it receives. The program terminates normally if the operator enters [ESC] from
the computer keyboard. Otherwise, the program analyzes and displays each
possible VERBOSE mode response and takes one of the following actions:
H
If a command results in the response
OK
, the program displays the response
and waits for the next operator entry (Example 6–1), or the program executes
the
CATV XMOD
command (Example 6–2).
H
If a command or query results in an error, the program retrieves and displays
the 2714 or 2715’s response,
ERR
, followed by the associated event code. It
then awaits the next operator entry.
H
If a query does not result in the response
ERR
, the program displays the
spectrum analyzer’s query response and awaits the next operator entry.
Program Example 6–1 illustrates interactive control of the 2714 or 2715 with the
RS-232 interface. It accepts single commands or queries, and performs the
command function or returns the query response. As an example, Figure 6–1
shows how the terminal display appears after sending the
ID?
query when this
program is running.
Talk/Listen Demo Program
Содержание 2714
Страница 4: ......
Страница 11: ...Introduction ...
Страница 12: ......
Страница 38: ...Introduction to Programming 1 26 2714 2715 Programmer Manual ...
Страница 39: ...Message Structure ...
Страница 40: ......
Страница 54: ...Instrument Specific Message Structure 2 14 2714 2715 Programmer Manual ...
Страница 55: ...Functional Groups ...
Страница 56: ......
Страница 85: ...Command Query ...
Страница 86: ......
Страница 179: ...Status Reporting ...
Страница 180: ......
Страница 197: ...Programming ...
Страница 198: ......
Страница 266: ...Programming 6 68 2714 2715 Programmer Manual ...
Страница 267: ...Appendices ...
Страница 268: ......
Страница 276: ...Appendix A RS 232 Concepts A 8 2714 2715 Programmer Manual ...
Страница 296: ...Appendix B GPIB System Concepts B 20 2714 2715 Programmer Manual ...
Страница 297: ...Index ...
Страница 298: ......
Страница 307: ......
Страница 308: ......