dpyPowermanager Namespace Reference

Deepsy PowerManager namespace that includes the different enums, structs or method signatures that should be used.

Classes

struct  PowerEvent
 A struct which represents the message that might be received from the service. It indicates when it was asked, the next action, and the level of the request. More...
 
struct  PowerRequest
 A struct which represents the message that might be received from the service. It indicates when it was asked, the next action, and the level of the request. More...
 
struct  Timers
 A struct which store the values of the power wakeup timers. More...
 
struct  TransitionIntervals
 A struct which store the values of the transition intervals. More...
 

Typedefs

typedef boost::function< void(const bool &available)> service_availability_handler
 Prototype of the handler function used to monitor service availability. More...
 
typedef boost::function< void(boost::system::error_code &ec, dpyPowermanager::PowerEvent event)> event_handler_function
 Handlers to the functions the client has to implement. More...
 
typedef boost::function< void(boost::system::error_code ec, bool active)> debug_pm_handler_function
 Debug handler to check if the debug is active or not.
 
typedef boost::function< void(boost::system::error_code &ec)> answer_pm_handler_function
 Answer handler function.
 
typedef boost::function< void(boost::system::error_code &ec, dpyPowermanager::Timers)> timers_pm_handler_function
 Timers handler function.
 
typedef boost::function< void(boost::system::error_code &ec, bool rightConfiguration)> power_rails_handler_function
 Power Rails handler function.
 
typedef boost::function< void(boost::system::error_code &ec, bool standbyEnabled, bool haltEnabled)> timers_state_pm_handler_function
 Timers State handler function.
 
typedef boost::function< void(boost::system::error_code &ec, dpyPowermanager::TransitionIntervals)> transition_intervals_pm_handler_function
 Transition Intervals handler function.
 
typedef boost::function< void(boost::system::error_code &ec, struct tm dateTime)> wakeup_time_pm_handler_function
 Wakeup Time handler function.
 
typedef boost::function< void(boost::system::error_code &ec, int minutes)> ignition_off_timeout_pm_handler_function
 Ignition Off Timeout handler function.
 

Enumerations

enum  Cause { DEFAULT = 0, CRITICAL_BATTERY = 1, MCU_ERROR = 2, IGNITION_OFF_TIMEOUT = 3 }
 The enum definition of the different types of causes. More...
 
enum  Request {
  REQ_POWER_ON = 0, REQ_REBOOT = 1, REQ_STANDBY = 2, REQ_SHUTDOWN = 3,
  REQ_ABORT = 4
}
 The enum definition of the different types of Power Manager Requests. More...
 
enum  Action { POWER_ON = 0, REBOOT = 1, STANDBY = 2, SHUTDOWN = 3 }
 The enum definition of the different types of Power Manager Requests. More...
 
enum  EventType { STARTED_MSG = 0, COMPLETED_MSG = 1, ABORTED_MSG = 2 }
 Identity of the kind of received message. More...
 
enum  ConfigType { NONE = 0, COMPLETED = 1, STARTED = 2, STARTED_COMPLETED = 3 }
 An enum definition which represents the different types of messages that it is wanted to be subscribed. More...
 
enum  Debug { NA_DEBUG = 0, ENABLE = 1, DISABLE = 2 }
 An enum definition which represents the different modes of the Automatic Power configuration. More...
 

Typedef Documentation

typedef boost::function<void(boost::system::error_code& ec, dpyPowermanager::PowerEvent event)> event_handler_function

Power event handler function.

typedef boost::function<void(const bool &available)> service_availability_handler
Parameters
availabletrue if the service is available, false otherwise

Enumeration Type Documentation

enum Action
Enumerator
POWER_ON 

The request to switch on the system.

REBOOT 

The request to restart the system.

STANDBY 

The request to turnon standby mode (suspend to ram).

SHUTDOWN 

The request to switchoff the system.

enum Cause
Enumerator
CRITICAL_BATTERY 

The action of warning the critical battery status.

MCU_ERROR 

The MCU is not ready for the transition.

enum ConfigType
Enumerator
NONE 

No messages.

COMPLETED 

COMPLETED messages.

STARTED 

STARTED messages.

STARTED_COMPLETED 

COMPLETED and STARTED messages.

enum Debug
Enumerator
NA_DEBUG 

Not available.

ENABLE 

Manual mode, debug mode disabled.

DISABLE 

Automatic mode, debug mode enabled.

enum EventType
Enumerator
STARTED_MSG 

A Started message, it indicates that it is wanted to change the power state. However, it exits the possibility of aborting it.

COMPLETED_MSG 

A Completed message, it indicates that it is going to turn on the indicated action.

ABORTED_MSG 

An Aborting message, it indicates that the previous action was aborted.

enum Request
Enumerator
REQ_POWER_ON 

The request to switch on the system.

REQ_REBOOT 

The request to restart the system.

REQ_STANDBY 

The request to turn on standby mode (suspend to ram).

REQ_SHUTDOWN 

The request to switch off the system.

REQ_ABORT 

The request to abort a request on course. It is only possible to abort the following requests: REBOOT, STANDBY and SHUTDOWN.