Technical data

66 Agilent Signal Generators Programming Guide
Using IO Interfaces
RS–232 Programming Interface Examples
Character Format Parameters
The signal generator uses the following character format parameters when communicating through
RS–232:
Character Length: Eight data bits are used for each character, excluding start, stop, and parity
bits.
Parity Enable: Parity is disabled (absent) for each character.
Stop Bits: One stop bit is included with each character.
If You Have Problems
1. Verify that the baud rate, parity, and stop bits are the same for the computer and signal
generator.
2. Verify that the RS–232 cable is identical to the cable specified in Table 2- 2.
3. Verify that the application is using the correct computer COM port and that the RS–232 cable is
properly connected to that port.
4. Verify that the controller’s flow control is set to RTS–CTS.
RS–232 Programming Interface Examples
NOTE The portions of the programming examples discussed in this section are taken from the full
text of these programs that can be found in Chapter 3, “Programming Examples.”
“Interface Check Using HP BASIC” on page 67
“Interface Check Using VISA and C” on page 67
“Queries Using HP Basic and RS–232” on page 68
“Queries for RS–232 Using VISA and C” on page 68
Before Using the Examples
Before using the examples: On the signal generator select the following settings:
Baud Rate – 9600 must match computer’s baud rate
RS–232 Echo – Off
The following sections contain HP Basic and C lines of programming removed from the programming
interface examples in Chapter 3, Programming Examples,, these portions of programming demonstrate
the important features to consider when developing programming for use with the RS–232 interface.
NOTE For RS–232 programming examples, refer to “RS- 232 Programming Interface Examples
(ESG/PSG Only)” on page 152.