Legrand / Raritan / Server Technology Xerus™ JSON-RPC API

Loading...
Searching...
No Matches
Classes | Public Types | Public Member Functions | Public Attributes | List of all members
pdumodel::Pdu Interface Reference

Main PDU interface. More...

## Classes
struct | LoadSheddingModeChangedEvent
| Event: Load shedding mode was enabled or disabled. More...
struct | MetaData
| PDU metadata. More...
struct | OutletSequenceState
| Outlet sequencing status More...
struct | OutletSequenceStateChangedEvent
| Event: Outlet sequencing state has changed. More...
struct | PortAppearedEvent
| Event: Serial port has appeared. More...
struct | PortDisappearedEvent
| Event: Serial port has disappeared. More...
struct | PortWithProperties
| Port with id and properties, used in PortAppearedEvent and getPorts() More...
struct | Sensors
| PDU sensors. More...
struct | Settings
| PDU settings. More...
struct | SettingsChangedEvent
| Event: PDU settings have been changed. More...
struct | Statistic
| PDU statistics. More...

## Public Types
enum | PduOrientation { PO_NONE , PO_BOTTOMFEED , PO_TOPFEED }
| PDU orientations. More...
enum | StartupState { SS_ON , SS_OFF , SS_LASTKNOWN }
| Outlet power state on device startup More...

## Public Member Functions
Nameplate | getNameplate ()
| Retrieve the PDU nameplate information.
MetaData | getMetaData ()
| Retrieve the PDU metadata.
Sensors | getSensors ()
| Retrieve the PDU sensors.
sensors::Logger | getSensorLogger ()
| Get the sensor logger.
sensors::AlertedSensorManager | getAlertedSensorManager ()
| Get the alerted sensor manager.
vector< Controller > | getControllers ()
| Get the list of sub controllers.
vector< Outlet > | getOutlets ()
| Get the list of outlets.
vector< OverCurrentProtector > | getOverCurrentProtectors ()
| Get the list of overcurrent protectors.
vector< Inlet > | getInlets ()
| Get the list of inlets.
vector< TransferSwitch > | getTransferSwitches ()
| Returns list of Transfer Switches.
peripheral::DeviceManager | getPeripheralDeviceManager ()
| Get the peripheral device manager.
hmi::InternalBeeper | getBeeper ()
| Get the built-in beeper, if there is any.
Settings | getSettings ()
| Retrieve the PDU settings.
boolean | isLoadSheddingActive ()
| Retrieve the current load shedding state.
int | setSettings (in Settings settings)
| Change the PDU settings.
void | setLoadSheddingActive (in boolean active)
| Enable or disable load shedding.
vector< portsmodel::Port > | getFeaturePorts ()
| Get all feature ports of this device.
vector< portsmodel::Port > | getSensorPorts ()
| Get all sensor ports of this device.
vector< portsmodel::Port > | getRemoteHubPorts ()
| Get all remote hub ports of this device.
vector< PortWithProperties > | getPorts (in peripheral::PortType portType, in portsmodel.Port.DeviceTypeId devType)
| Get all serial ports of this device using filters.
int | enterRS485ConfigModeAndAssignCtrlBoardAddress (in int addr)
| Enter RS485 config mode and assign an address to a relay board.
int | enterRS485ConfigModeAndAssignSCBoardAddress (in int deviceId, in int addr)
| Enter RS485 config mode and assign an address to a sub controller device with a given device ID.
int | leaveRS485ConfigMode ()
| Leave RS485 config mode.
int | setAllOutletPowerStates (in Outlet::PowerState pstate)
| Switch all outlets.
int | setMultipleOutletPowerStates (in vector< int > outletNumbers, in Outlet::PowerState state, in boolean respectSequence)
| Switch multiple outlets.
int | cycleAllOutletPowerStates ()
| Power-cycle all outlets.
int | cycleMultipleOutletPowerStates (in vector< int > outletNumbers, in boolean respectSequence)
| Power-cycle multiple outlets.
Statistic | getStatistic ()
| Retrieve PDU statistics.
OutletSequenceState | getOutletSequenceState ()
| Retrieve the current outlet sequencing status.
void | cancelOutletSequence ()
| Stop a currently running outlet sequence.

## Public Attributes
constant int | ERR_INVALID_PARAM = 1
| Invalid parameters.

## Detailed Description

Main PDU interface.

Definition at line 29 of file Pdu.idl.

## Member Enumeration Documentation

## ◆ PduOrientation

enum pdumodel::Pdu::PduOrientation

PDU orientations.

Enumerator
PO_NONE | No PDU orientation (non-reversible ETO, default)
PO_BOTTOMFEED | Bottom feed PDU orientation (reversible ETO, normal order)
PO_TOPFEED | Top feed PDU orientation (reversible ETO, reversed order)

Definition at line 34 of file Pdu.idl.

## ◆ StartupState

enum pdumodel::Pdu::StartupState

Outlet power state on device startup

Enumerator
SS_ON | Outlet will be switched on
SS_OFF | Outlet will be switched off
SS_LASTKNOWN | Restore last known power state.

Definition at line 75 of file Pdu.idl.

## Member Function Documentation

## ◆ cycleAllOutletPowerStates()

int pdumodel::Pdu::cycleAllOutletPowerStates | ( |  | ) |

Power-cycle all outlets.

Returns
  0 if OK
  5 if relay control is disabled in the PDU settings

## ◆ cycleMultipleOutletPowerStates()

int pdumodel::Pdu::cycleMultipleOutletPowerStates | ( | in vector< int > | outletNumbers,
|  | in boolean | respectSequence
| ) |  |

Power-cycle multiple outlets.

Parameters

  outletNumbers | List of outlet numbers (0-based)
  respectSequence | `true` to switch in defined sequence order

Returns
  0 if OK
  3 if any of the selected outlets is disabled
  5 if relay control is disabled in the PDU settings

## ◆ enterRS485ConfigModeAndAssignCtrlBoardAddress()

int pdumodel::Pdu::enterRS485ConfigModeAndAssignCtrlBoardAddress | ( | in int | addr | ) |

Enter RS485 config mode and assign an address to a relay board.

Warning
  This is dangerous! Do not use except for manufacturing.

Parameters

  addr | New relay board address

Returns
  0 if OK
  1 if any parameters are invalid

## ◆ enterRS485ConfigModeAndAssignSCBoardAddress()

int pdumodel::Pdu::enterRS485ConfigModeAndAssignSCBoardAddress | ( | in int | deviceId,
|  | in int | addr
| ) |  |

Enter RS485 config mode and assign an address to a sub controller device with a given device ID.

Warning
  This is dangerous! Do not use except for manufacturing.

Parameters

  deviceId | Device id of the sub controller which is supposed to get the address
  addr | New relay board address

Returns
  0 if OK
  1 if any parameters are invalid

## ◆ getAlertedSensorManager()

sensors::AlertedSensorManager pdumodel::Pdu::getAlertedSensorManager | ( |  | ) |

Get the alerted sensor manager.

Returns
  Alerted sensor manager

## ◆ getBeeper()

hmi::InternalBeeper pdumodel::Pdu::getBeeper | ( |  | ) |

Get the built-in beeper, if there is any.

Returns
  Beeper interface

## ◆ getControllers()

vector< Controller > pdumodel::Pdu::getControllers | ( |  | ) |

Get the list of sub controllers.

Returns
  List of sub controllers

## ◆ getFeaturePorts()

vector< portsmodel::Port > pdumodel::Pdu::getFeaturePorts | ( |  | ) |

Get all feature ports of this device.

This returns an entry for all feature ports, no matter whether something is connected or not. A device with n feature ports will return n entries here.

Returns
  List of all Feature Ports

## ◆ getInlets()

vector< Inlet > pdumodel::Pdu::getInlets | ( |  | ) |

Get the list of inlets.

Returns
  List of inlets, indexed by their number (0-based)

## ◆ getMetaData()

MetaData pdumodel::Pdu::getMetaData | ( |  | ) |

Retrieve the PDU metadata.

Returns
  PDU metadata

## ◆ getNameplate()

Nameplate pdumodel::Pdu::getNameplate | ( |  | ) |

Retrieve the PDU nameplate information.

Returns
  Nameplate information

## ◆ getOutlets()

vector< Outlet > pdumodel::Pdu::getOutlets | ( |  | ) |

Get the list of outlets.

Returns
  List of outlets, indexed by their number (0-based)

## ◆ getOutletSequenceState()

OutletSequenceState pdumodel::Pdu::getOutletSequenceState | ( |  | ) |

Retrieve the current outlet sequencing status.

Returns
  Sequencing status

## ◆ getOverCurrentProtectors()

vector< OverCurrentProtector > pdumodel::Pdu::getOverCurrentProtectors | ( |  | ) |

Get the list of overcurrent protectors.

Returns
  List of OCPs, indexed by their number (0-based)

## ◆ getPeripheralDeviceManager()

peripheral::DeviceManager pdumodel::Pdu::getPeripheralDeviceManager | ( |  | ) |

Get the peripheral device manager.

Returns
  Peripheral device manager

## ◆ getPorts()

vector< PortWithProperties > pdumodel::Pdu::getPorts | ( | in peripheral::PortType | portType,
|  | in portsmodel.Port.DeviceTypeId | devType
| ) |  |

Get all serial ports of this device using filters.

This returns an entry for all detected ports, no matter whether something is connected or not. The ports may be filtered by peripheral::PortType and/or supported device type portsmodel.Port.DeviceTypeId.

Parameters

  portType | filter for port type, or use peripheral::Portype.UNSPECIFIED
  devType | filter the ports that support a specific device, or use portsmodel::Port.DeviceTypeId.UNSPECIFIED

Returns
  List of ports with id and properties.

## ◆ getRemoteHubPorts()

vector< portsmodel::Port > pdumodel::Pdu::getRemoteHubPorts | ( |  | ) |

Get all remote hub ports of this device.

This returns an entry for all remote hub ports, no matter whether something is connected or not. A device with n remote hub ports will return n entries here.

Returns
  List of all Remote Hub Ports

## ◆ getSensorLogger()

sensors::Logger pdumodel::Pdu::getSensorLogger | ( |  | ) |

Get the sensor logger.

Returns
  Sensor logger reference

## ◆ getSensorPorts()

vector< portsmodel::Port > pdumodel::Pdu::getSensorPorts | ( |  | ) |

Get all sensor ports of this device.

This returns an entry for all sensor ports, no matter whether something is connected or not. A device with n sensor ports will return n entries here.

Returns
  List of all Sensor Ports

## ◆ getSensors()

Sensors pdumodel::Pdu::getSensors | ( |  | ) |

Retrieve the PDU sensors.

Returns
  PDU sensors

## ◆ getSettings()

Settings pdumodel::Pdu::getSettings | ( |  | ) |

Retrieve the PDU settings.

Returns
  PDU settings

## ◆ getStatistic()

Statistic pdumodel::Pdu::getStatistic | ( |  | ) |

Retrieve PDU statistics.

Returns
  PDU statistics

## ◆ getTransferSwitches()

vector< TransferSwitch > pdumodel::Pdu::getTransferSwitches | ( |  | ) |

Returns list of Transfer Switches.

This list may be empty.

## ◆ isLoadSheddingActive()

boolean pdumodel::Pdu::isLoadSheddingActive | ( |  | ) |

Retrieve the current load shedding state.

Returns
  `true` if load shedding is currently enabled

## ◆ leaveRS485ConfigMode()

int pdumodel::Pdu::leaveRS485ConfigMode | ( |  | ) |

Leave RS485 config mode.

Returns
  0 if OK

## ◆ setAllOutletPowerStates()

int pdumodel::Pdu::setAllOutletPowerStates | ( | in Outlet::PowerState | pstate | ) |

Switch all outlets.

Parameters

  pstate | New power state for all outlets

Returns
  0 if OK
  5 if relay control is disabled in the PDU settings

## ◆ setLoadSheddingActive()

void pdumodel::Pdu::setLoadSheddingActive | ( | in boolean | active | ) |

Enable or disable load shedding.

Parameters

  active | `true` to enable, `false` to disable load shedding

## ◆ setMultipleOutletPowerStates()

int pdumodel::Pdu::setMultipleOutletPowerStates | ( | in vector< int > | outletNumbers,
|  | in Outlet::PowerState | state,
|  | in boolean | respectSequence
| ) |  |

Switch multiple outlets.

Parameters

  outletNumbers | List of outlet numbers (0-based)
  state | New power state for all outlets in list
  respectSequence | `true` to switch in defined sequence order

Returns
  0 if OK
  3 if any of the selected outlets is disabled
  5 if relay control is disabled in the PDU settings

## ◆ setSettings()

int pdumodel::Pdu::setSettings | ( | in Settings | settings | ) |

Change the PDU settings.

Parameters

  settings | New PDU settings

Returns
  0 if OK
  1 if any parameters are invalid

Note
  The Settings structure can be "sparse"; fields missing in the JSON representation will remain unchanged.

## Member Data Documentation

## ◆ ERR_INVALID_PARAM

constant int pdumodel::Pdu::ERR_INVALID_PARAM = 1

Invalid parameters.

Definition at line 31 of file Pdu.idl.

The documentation for this interface was generated from the following file:

- Pdu.idl