1 serial interface [standard models only, 2 rs 232 implementation [standard models only – KEPCO KLP Series Developers Guide, Rev 3 User Manual

Page 96

Advertising
background image

8-2

KLP-DEV 041213

8.2.1

SERIAL INTERFACE [STANDARD MODELS ONLY]

The serial interface behaves like the GPIB interface in that the command is parsed after receiv-
ing a control character of either a Line Feed or Carriage Return. The serial interface supports
four special control characters:

Escape (1B

H

)

Causes the input buffer to be cleared. This character is used to ensure
that the buffer is empty when the host powers on since it is possible
that the KLP Power Supply was previously powered on and received
some characters prior to the initialization of the host computer.

Backspace (08

H

)

Causes the last character in the input buffer to be removed from the
input buffer queue.

Carriage Return (0D

H

)

Causes the input buffer to be parsed by the KLP Power Supply.

Line Feed (0A

H

)

Causes the input buffer to be parsed by the KLP Power Supply.

Six characters (#, $, !, @, &, %) are not permitted in RS 232 programming strings. These char-
acters are reserved for LAN communications, and their use in other serial programming proto-
cols will likely result in interrupted communications.

8.2.2

RS 232 IMPLEMENTATION [STANDARD MODELS ONLY]

The following paragraphs are provided to help the user understand how the RS 232 serial inter-
face is implemented in the KLP Power Supply. Since the RS 232 protocol does not use a parity
bit, the echo mode is the default method used to ensure reliable communication between the
command originator (computer) and the KLP Power Supply, thus avoiding a more complex
“handshake” protocol.

Upon initial application of source power to the KLP input, or after restoration of source power fol-
lowing an interruption, the power supply will return the identification string described in Appen-
dix A, PAR. A.6, to the host controller. This indicates that the KLP is initialized and ready to
accept programming commands.

When the KLP Power Supply is in the RS 232 echo mode it returns all data received from the
host controller. The KLP Power Supply provides two additional options that allow handshake
communication: the Prompt method and the XON XOFF method. In standard echo mode the
controller must verify that each character is echoed back by the KLP. As shown in Figure 8-1,
there are times when the KLP does not echo back the character from the controller, requiring
that the controller resend the character. By using the handshake options (prompt and XON
XOFF) the host controller can ensure that serial data interrupts occurring after parsing of the
incoming message do not result in lost data.

Figure 8-1 illustrates the default echo mode, the prompt method and the XON XOFF method
described in the following paragraphs.

Only four control characters (characters between 00

H

and 1F

H

) are acknowledged by the power

supply:

• Carriage Return (CR, 0D

H

)

• Line Feed (LF, 0A

H

)

• Back Space (BS, 08

H

)

• Escape (ESC, 01B

H

)

Advertising