next up previous contents
Next: CL_RDS_SVC Up: Detailed Description of Functions Previous: CL_ORD_SVC   Contents

CL_PS_SVC

Requests/sets state of ZY power supplies.
ZIYRet CL_PS_SVC(PM_CL_PS)
Parameters:
All parameters are contained in the PM_CL_PS structure.
struct PM_CL_PS

{
  SRVD sd;
  int  State;
  float PS1;
  float PS2;
  float PS3;
  float PS4;
};
sd.Name

The name of the ZY.
sd.Flags

The operation of the CL_PS_SVC RPC function call is determined by the following two flag bits. They are mutually exclusive:
CL_PS_READ
This requests the state of the supplies (on/off) and their voltages.
CL_PS_SET
This sets the state of the supplies (on/off)
sd.ErrorMsg

Not used.
sd.TID

Not used.
sd.TS

Not used.
State

The value in this data member represents the state of the power supplies as follows:
value: Power Supply State
0 Off
1 On

If the CL_PS_SET flag is set in sd.Flags, then the power supplies will be turned on or off according to the value in this data member.
PS1

Not used.
PS2

Not used.
PS3

Not used.
PS4

Not used.
Return Value:

A ZIYRet structure, which contains the success code and an error message, if the call failed (see ZIYRet, section 4.2.2.)
Remarks:

This function allows the control and monitoring of the ZYs power supplies. When used with the CL_PS_READ flag, the voltages of the power supplies can be checked, so this function can also be used for troubleshooting purposes (voltage values are also returned when the CL_PS_SET flag is set, but they will be in transition between on and off or off and on, and are therefore not valid.) Cycling the power supplies on or off also enables or disables the electronics that they supply power to, of course. Therefore, this function provides a way to control the operation of laser system, the oscillator system, and the receiver through software commands.
Example:

PM_CL_PS p;


p.sd.Name = "zy10";             // address ZY10
p.sd.ErrorMsg = null_str;       // Keep XDR lib happy
p.sd.Flags = CL_PS_SET;         // Set power supply state
p.State = 1;                    // Turn them on.

CL->rexec(CL_PS_SVC, (xdrproc_t)xdr_PM_CL_PS, (char *)&p,
          (xdrproc_t)xdr_ZIYRet, (char *)&in, sizeof(ZIYRet));
See also:

CL_AXIS_SVC, CL_STW_SVC, PM_CL_PS

next up previous contents
Next: CL_RDS_SVC Up: Detailed Description of Functions Previous: CL_ORD_SVC   Contents
Ramon E. Creager 2002-03-11