#include <cascade/app/CascadePowerLEDMessage.h>
Public Types | |
enum | Command { kTurnOnPowerLED = 0, kTurnOffPowerLED, kGetPowerLEDStatus } |
CascadePowerLED. More... | |
enum | State { kOff = 0, kOn = 1 } |
Public Member Functions | |
CascadePowerLEDMessage () | |
Static Public Member Functions | |
static const char * | PowerLEDWormholeURL () |
static u32 | MessageID () |
CascadePowerLED. | |
Public Attributes | |
Command | m_command |
State | m_state |
bool | m_bResult |
CascadePowerLEDMessages are sent to the power led wormhole to control and get the status of the power led, if present. Clients that wish to control or get status of the power led should use class CascadePowerLED, rather than use CascadePowerLEDMessage directly. CascadePowerLED provides an easy wrapper for using CascadePowerLEDMessages.
Control programs that manipulate the power led directly should create the power led wormhole, wait on it for CascadePowerLEDMessages, and perform the appropriate command, as described below. At most there is one control program running on a device listening for power led messages and controling the power led directly.
Clients need not be concerned with platform specific details of controlling the power led, they can just send CascadePowerMessages to the power led wormhole. Usually they will do this by using class CascadePowerLED.
|
that clients use CascadePowerLED directly rather than construct their own CascadePowerLEDMessages. |
|
represents the state of the power led CascadePowerLEDMessages contain a member variable (m_state) that represents |
|
the power led message constructor CascadePowerLEDMessage() constructs a power led message. It is recommended |
|
returns the messageID of the CascadePowerLEDMessage MessageID() is the messageID used to send and receive CascadePowerLEDMessages. |
|
returns the wormhole URL of the power led wormhole PowerLEDWormholeURL() is used to get the wormhole URL of the power led |
|
the result of the power led message dispatch m_bResult contains the result of the power led message dispatch. Send a power led message to the power led wormhole and consult m_bResult of the reply message to determine if the command was dispatched successfully. It is recommended that clients use CascadePowerLED for automatic usage and decoding of CascadePowerLEDMessages.
|
|
the command of the power led message m_command contains the command of the power led message. When the power led message |
|
the state of the power led m_state contains the state of the power led message after the power led message |