VMX-pi C++ HAL Library for Raspberry Pi
VMX-pi Robotics Controller & Vision/Motion Processor
|
Top-level Library Class providing access to all VMX-pi functionality. More...
#include <VMXPi.h>
Public Member Functions | |
VMXPi (bool realtime, uint8_t ahrs_update_rate_hz) | |
Constructs the VMXPi object using the specified parameters. More... | |
bool | IsOpen () |
Returns true if the communication with the VMX-pi firmware has been established. | |
vmx::AHRS & | getAHRS () |
Returns a reference to the singleton AHRS object providing access to VMX-pi IMU functionality. More... | |
VMXTime & | getTime () |
Returns a reference to the singleton VMXTime object providing access to VMX-pi Time functionality. More... | |
VMXIO & | getIO () |
Returns a reference to the singleton VMXIO object providing access to VMX-pi IO functionality. More... | |
VMXCAN & | getCAN () |
Returns a reference to the singleton VMXCAN object providing access to VMX-pi CAN functionality. More... | |
VMXPower & | getPower () |
Returns a reference to the singleton VMXPower object providing access to VMX-pi Power functionality. More... | |
VMXVersion & | getVersion () |
Returns a reference to the singleton VMXVersion object providing access to VMX-pi Version functionality. More... | |
VMXThread & | getThread () |
Returns a reference to the singleton VMXThread object providing access to VMX-pi Threading functionality. More... | |
bool | registerShutdownHandler (void(*termination_func)(void)) |
Registers a termination handler, invoked when VMXPi instance is terminated, but before resources are released. More... | |
bool | registerFinalShutdownHandler (void(*termination_func)(void)) |
Registers a termination handler, invoked when VMXPi instance is terminated, but only after all resources are released. More... | |
bool | getPerformanceLogging () |
Selective Enabling/Disabling of Summary Performance statistics. More... | |
void | setPerformanceLogging (bool enable) |
Sets the current state of Performance Logging. More... | |
Static Public Member Functions | |
static VMXPi * | getInstance () |
Public Attributes | |
vmx::AHRS | ahrs |
The AHRS object providing access to VMX-pi IMU functionality. More... | |
VMXTime | time |
The VMXTime object providing access to VMX-pi Time functionality. More... | |
VMXIO | io |
The VMXIO object providing access to VMX-pi IO functionality. More... | |
VMXCAN | can |
The VMXCAN object providing access to VMX-pi CAN functionality. More... | |
VMXPower | power |
The VMXPower object providing access to VMX-pi Power functionality. More... | |
VMXVersion | version |
The VMXVersion object providing access to VMX-pi Version functionality. More... | |
VMXThread | thread |
The VMXThread object providing access to VMX-pi Threading functionality. More... | |
Top-level Library Class providing access to all VMX-pi functionality.
VMXPi::VMXPi | ( | bool | realtime, |
uint8_t | ahrs_update_rate_hz | ||
) |
Constructs the VMXPi object using the specified parameters.
This constructor initializes the VMX-pi HAL.
realtime | true if the VMX-pi host Linux operating system supports real-time priorities, as implemented via a fully-preemptible Real-time Linux Kernel. |
ahrs_update_rate_hz | The update rate to use for the VMX-pi AHRS/IMU interface. Default is 50 hz. Valid range: 4-200Hz. |
|
inline |
Returns a reference to the singleton AHRS object providing access to VMX-pi IMU functionality.
|
inline |
Returns a reference to the singleton VMXCAN object providing access to VMX-pi CAN functionality.
|
inline |
Returns a reference to the singleton VMXIO object providing access to VMX-pi IO functionality.
bool VMXPi::getPerformanceLogging | ( | ) |
Selective Enabling/Disabling of Summary Performance statistics.
Returns the current state of Performance Logging.
|
inline |
Returns a reference to the singleton VMXPower object providing access to VMX-pi Power functionality.
|
inline |
Returns a reference to the singleton VMXThread object providing access to VMX-pi Threading functionality.
|
inline |
Returns a reference to the singleton VMXTime object providing access to VMX-pi Time functionality.
|
inline |
Returns a reference to the singleton VMXVersion object providing access to VMX-pi Version functionality.
bool VMXPi::registerFinalShutdownHandler | ( | void(*)(void) | termination_func | ) |
Registers a termination handler, invoked when VMXPi instance is terminated, but only after all resources are released.
Only a single final shutdown handler may be registered.
bool VMXPi::registerShutdownHandler | ( | void(*)(void) | termination_func | ) |
Registers a termination handler, invoked when VMXPi instance is terminated, but before resources are released.
Termination functions are invoked in the reverse order of registration.
void VMXPi::setPerformanceLogging | ( | bool | enable | ) |
Sets the current state of Performance Logging.
VMXVersion VMXPi::version |
The VMXVersion object providing access to VMX-pi Version functionality.