mcuApi.h
Go to the documentation of this file.
228 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::PowerInformationConfig &)> power_mng_handler_function;
234 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::LedsConfig &)> leds_handler_function;
240 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::PowerStateConfig &)> power_states_handler_function;
246 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::TimersConfig &)> timers_handler_function;
252 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::UpdateConfig &)> update_firmware_handler_function;
258 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::GUIDConfigList &)> guid_handler_function;
265 typedef boost::function<void(boost::system::error_code error_code, char &, char &)> eqvar_handler_function;
271 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::WorkingTimeConfig &)> working_time_handler_function;
277 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::MCUStatus &)> mcu_status_handler_function;
283 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::BatteryProtectionConfig &)> battery_protection_handler_function;
289 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::DateConfig &)> rtc_date_handler_function;
295 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::GpioConfig &)> gpio_handler_function;
301 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::GpiosAvailable &)> gpios_events_handler_function;
307 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::I2CValue &)> i2c_handler_function;
313 typedef boost::function<void(boost::system::error_code error_code, const dpyFirmware::FirmwareVersionInfo& fw_version)> version_handler_function;
319 typedef boost::function<void(boost::system::error_code error_code, dpyMcu::CanStatusEvent &)> can_status_handler_function;
331 typedef boost::function<void(boost::system::error_code error_code)> set_power_button_state_handler_function;
338 typedef boost::function<void(boost::system::error_code error_code, bool enabled)> get_power_button_state_handler_function;
396 void asyncSetLedsConfig(dpyMcu::leds_handler_function handler, dpyMcu::LedsColor color, std::uint32_t period, std::uint32_t duty_cycle);
409 void asyncSetBatteryProtectionConfig(dpyMcu::battery_protection_handler_function handler, float idle_voltage, float voltage_percentage_threshold,
508 void asyncSetGpioValue(dpyMcu::gpio_handler_function handler, std::uint32_t gpio_number, bool gpio_value);
524 void asyncGetI2CValue(dpyMcu::i2c_handler_function handler, unsigned char busid, unsigned char deviceid, std::list<unsigned char> address, int lenght);
535 void asyncSetI2CValue(dpyMcu::i2c_handler_function handler, unsigned char busid, unsigned char deviceid, std::list<unsigned char> address, std::list<unsigned char> values);
560 boost::system::error_code setI2CValue(unsigned char busid, unsigned char deviceid, std::list<unsigned char> address, std::list<unsigned char> values,dpyMcu::I2CValue& result);
572 boost::system::error_code getI2CValue(unsigned char busid, unsigned char deviceid, std::list<unsigned char> address, int length,dpyMcu::I2CValue& result);
584 virtual void asyncSetLedsConfig(dpyMcu::leds_handler_function handler, dpyMcu::LedsColor color, std::uint32_t period, std::uint32_t duty_cycle);
585 virtual void asyncSetBatteryProtectionConfig(dpyMcu::battery_protection_handler_function handler, float idle_voltage, float voltage_percentage_threshold, float hysteresis_percentage, std::uint32_t grace_period_minutes);
586 virtual void asyncGetBatteryProtectionConfig(dpyMcu::battery_protection_handler_function handler);
599 virtual void asyncGetGpioValue(dpyMcu::gpio_handler_function handler, std::uint32_t gpio_number);
600 virtual void asyncSetGpioValue(dpyMcu::gpio_handler_function handler, std::uint32_t gpio_number, bool gpio_value);
604 virtual boost::system::error_code setI2CValue(unsigned char busid, unsigned char deviceid, std::list<unsigned char> address, std::list<unsigned char> values,dpyMcu::I2CValue& value);
605 virtual boost::system::error_code getI2CValue(unsigned char busid, unsigned char deviceid, std::list<unsigned char> address, int lenght,dpyMcu::I2CValue& value);
boost::function< void(boost::system::error_code error_code)> result_handler_function
Prototype of the handler function for obtaining the result of the operations status.
Definition: mcuApi.h:344
I2C Struct which contains the response received from the service.
Definition: mcuApi.h:117
std::string serial_number
Serial Number of the equipment.
Definition: mcuApi.h:167
PowerInformation struct which contains the response received from the service.
Definition: mcuApi.h:146
float battery_inner_percent
battery inner percent
Definition: mcuApi.h:138
std::uint32_t hardware_exceptions
Hardware exceptions.
Definition: mcuApi.h:190
boost::function< void(boost::system::error_code error_code, dpyMcu::TimersConfig &)> timers_handler_function
Prototype of the handler function for obtaining the Timers Configuration.
Definition: mcuApi.h:246
std::uint32_t period
Period in seconds (range: 0 - 10)
Definition: mcuApi.h:104
std::uint32_t software_exceptions
Software exceptions.
Definition: mcuApi.h:191
GUID struct which contains the response received from the service.
Definition: mcuApi.h:163
DateConfig struct which contains the response received from the service.
Definition: mcuApi.h:205
boost::function< void(boost::system::error_code error_code, dpyMcu::MCUStatus &)> mcu_status_handler_function
Prototype of the handler function for obtaining the MCU Status.
Definition: mcuApi.h:277
Working Time struct which contains the response received from the service.
Definition: mcuApi.h:178
boost::function< void(boost::system::error_code error_code, const dpyFirmware::FirmwareVersionInfo &fw_version)> version_handler_function
Prototype of the handler function for obtaining the fw version.
Definition: mcuApi.h:313
std::uint32_t timer_halt_minutes
Halt Timer.
Definition: mcuApi.h:159
std::string part_number
Part Number of the equipment.
Definition: mcuApi.h:166
std::uint32_t timer_standby_minutes
Standby Timer.
Definition: mcuApi.h:158
boost::function< void(boost::system::error_code error_code, dpyMcu::GpioConfig &)> gpio_handler_function
Prototype of the handler function for obtaining the GPIO Configuration.
Definition: mcuApi.h:295
std::uint32_t grace_period_minutes
grace period in minutes used to enter in halt mode irrevocably
Definition: mcuApi.h:201
Battery Protection Config struct which contains the response received from the service.
Definition: mcuApi.h:195
boost::function< void(const bool &available)> service_availability_handler
Prototype of the handler function used to monitor service availability.
Definition: mcuApi.h:221
std::string partition_written
partition_written
Definition: mcuApi.h:129
std::uint32_t duty_cycle
duty_cycle in percentage (range: 0% - 100%)
Definition: mcuApi.h:105
float voltage_percentage_over_idle_voltage_threshold
voltage percentage threshold calculated over idle voltage
Definition: mcuApi.h:199
Defines a class for checking firmware binaries available for upgrading.
Rfs
Defines the possible root file systems where binaries are located.
Definition: firmware.h:54
boost::function< void(boost::system::error_code error_code, dpyMcu::CanStatusEvent &)> can_status_handler_function
Prototype of the handler function for obtaining the CAN Status Information.
Definition: mcuApi.h:319
std::uint32_t power_on_hours_working
Power-On hours working.
Definition: mcuApi.h:181
MCU Status struct which contains the response received from the service.
Definition: mcuApi.h:187
boost::function< void(boost::system::error_code error_code, dpyMcu::WorkingTimeConfig &)> working_time_handler_function
Prototype of the handler function for obtaining the Working Time Values.
Definition: mcuApi.h:271
Deepsy Mcu namespace that includes the different enums, structs or method signatures that should be u...
Definition: mcuApi.h:16
boost::function< void(boost::system::error_code error_code, dpyMcu::GpiosAvailable &)> gpios_events_handler_function
Prototype of the handler function for obtaining the GPIO Events.
Definition: mcuApi.h:301
boost::function< void(boost::system::error_code error_code, bool enabled)> get_power_button_state_handler_function
Prototype of the handler function for obtaining the result of power button.
Definition: mcuApi.h:338
boost::function< void(boost::system::error_code error_code, dpyMcu::I2CValue &)> i2c_handler_function
Prototype of the handler function for obtaining the I2C information.
Definition: mcuApi.h:307
PowerInformation struct which contains the response received from the service.
Definition: mcuApi.h:133
Update struct which contains the response received from the service.
Definition: mcuApi.h:126
Timers struct which contains the response received from the service.
Definition: mcuApi.h:155
boost::function< void(boost::system::error_code error_code, dpyMcu::GUIDConfigList &)> guid_handler_function
Prototype of the handler function for obtaining the GUIDs.
Definition: mcuApi.h:258
bool battery_protection_mode
battery protection mode
Definition: mcuApi.h:142
boost::function< void(boost::system::error_code error_code)> set_power_button_state_handler_function
Prototype of the handler function for obtaining the result of power button.
Definition: mcuApi.h:331
boost::function< void(boost::system::error_code error_code, dpyMcu::UpdateConfig &)> update_firmware_handler_function
Prototype of the handler function for obtaining the updated configuration.
Definition: mcuApi.h:252
float hysteresis_percentage_over_idle_voltage
hysteresis percentage calculated over idle voltage
Definition: mcuApi.h:200
boost::function< void(boost::system::error_code error_code, dpyMcu::BatteryProtectionConfig &)> battery_protection_handler_function
Prototype of the handler function for obtaining the Battery Protection Configuration.
Definition: mcuApi.h:283
Definition: mcuApi.h:100
boost::function< void(boost::system::error_code error_code, dpyMcu::DateConfig &)> rtc_date_handler_function
Prototype of the handler function for obtaining the RTC Date Configuration.
Definition: mcuApi.h:289
boost::function< void(boost::system::error_code error_code, dpyMcu::PowerStateConfig &)> power_states_handler_function
Prototype of the handler function for obtaining the Power State Configuration.
Definition: mcuApi.h:240
float battery_extern_voltage
battery extern voltage
Definition: mcuApi.h:137
float idle_voltage
idle voltage identified by ignition position off, engine off and stationary vehicle ...
Definition: mcuApi.h:198
bool battery_type
battery type: 1 –> 24V, 0 –> 12V
Definition: mcuApi.h:139
GUID list struct which contains the response received from the service.
Definition: mcuApi.h:172
std::list< struct GUIDConfig > guids
GUIDs elements.
Definition: mcuApi.h:174
std::string cidl_number
CIDL Number of the equipment.
Definition: mcuApi.h:168
std::uint32_t standby_hours_working
Standby hours working.
Definition: mcuApi.h:182
std::int32_t temperature
temperature
Definition: mcuApi.h:140
std::uint32_t halt_hours_working
Halt hours working.
Definition: mcuApi.h:183
boost::function< void(boost::system::error_code error_code)> test_misc_handler_function
Prototype of the handler function for obtaining the current MISC status.
Definition: mcuApi.h:325
std::uint32_t event_flags
set flags to enter in power state
Definition: mcuApi.h:150
boost::function< void(boost::system::error_code error_code, char &, char &)> eqvar_handler_function
Prototype of the handler function for obtaining the GUIDs.
Definition: mcuApi.h:265
boost::function< void(boost::system::error_code error_code, dpyMcu::LedsConfig &)> leds_handler_function
Prototype of the handler function for obtaining the LEDs configuration.
Definition: mcuApi.h:234
boost::shared_ptr< McuClient > mClient
Reference to an Client Object.
Definition: mcuApi.h:359
GPIO Struct which contains the response received from the service.
Definition: mcuApi.h:109
boost::function< void(boost::system::error_code error_code, dpyMcu::PowerInformationConfig &)> power_mng_handler_function
Prototype of the handler function for obtaining the Power Information.
Definition: mcuApi.h:228