Using remote control panel APIs

 

You can use these APIs to write a program that can access the control panel remotely. With the APIs, your program can access many commands and queries.

The remote control panel function of Operations Console provides a set of APIs that system administrators can use to control the system through programs. The APIs allow custom programs to interact with the system control panel and perform many common system control panel functions.

You can use these APIs only if you are using the remote control panel that is connected with the serial console cable. You cannot use these APIs with the virtual control panel or remote control panel connected with a parallel cable.

The interface to the remote control panel APIs is established through a standard TCP/IP socket connection. The socket connection can be implemented in any programming language that supports sockets on the Windows® platform (Java™ , C/C++, Visual Basic to name a few).

To use the remote control panel APIs, follow these steps:

  1. Start Operations Console with the remote control panel function.

  2. From a custom program, open a socket connection to port 2150 on the same PC.

  3. Send a supported command from the set of commands that are described below.

  4. Receive the byte stream that is sent back on the same socket connection.

  5. Repeat steps 3 and 4 as necessary on the same socket connection.

  6. Close the socket connection when done.

Your program needs to interpret the byte stream that is sent back from the system. The returned byte stream consists of a predefined format, which is the same for all commands. The byte stream is at least 4 bytes long. Some commands return additional bytes.

The first 2 bytes (0 and 1) will return the command status, typically successful or unsuccessful. The next 2 bytes (2 and 3) will be a 16-bit number N, which tells how many additional bytes will follow these first 4 bytes. If N is nonzero, then there will be additional information in bytes 4 through 4 + N. This information will be additional data related to the command, such as TRUE or FALSE.

If the command sent is not one of the command strings defined below, then the return code in bytes 0 and 1 of the return value will be 32 (0x20). This means Command not Supported.

Your programs can perform the following control panel functions by using the following APIs.

 

Parent topic:

Control panel