A-17
A3
A3
VXI-11 RPC PROTOCOL
The information about the RPC Protocol in Section C is reprinted from the
VXI-11 Specification. Consult the VXI-11 Specification for more information
about using the VXI-11 RPC Protocol.
B.
Basic RPC Programming
The following steps are the general steps to create an RPC program.
1. Obtain the man page for RPC on your system. If it is not available, confirm
that you have RPC installed. Many systems do not have RPC installed since it
is frequently considered an option. The man page gives an overview of RPC
usage and will usually provide information on additional resources such as
“rpcgen”.
2. Obtain the AB80-3 application note from the ICS website. Study this ap-
plication note, but do understand that it is intended as an overview and is not
detailed. In the summary section you will note several URL references for
detailed RPC information. Skim through them to determine what information
is available should it be needed.
3. Obtain the VXI-11 RPCL from either the last 2-3 pages of the VXI-11 base
specification or from paragraph C in this Appendix. This needs to be copy/pasted
into a text file which will be fed into the rpcgen utility.
4. Use your system's rpcgen tool to process the VXI-11 RPCL definition file
you created in step-3. The result should be a .H and .C pair of files. These files
will be used by your client application to perform VXI-11 functions.
5. Study the VXI-11 functions as defined in the VXI-11 specification. In par-
ticular study the create_link, device_write and device_read. These are the core
instructions required to do simple communication with a VXI-11 device.
6. Create a simple program to execute the following steps. Following the last
step, you should have an IDN reply from the VXI-11 Device (80xx). The IDN
reply provides an ASCII string defining the instrument model information.
a) Initialize the RPC layer.
b) Execute a create_link to the 80xx
c) Execute a device_write of “*IDN?” to the 80xx.
d) Execute a device_read from the 80xx.