libvisiontransfer  8.0.0
Classes | Public Member Functions | List of all members
visiontransfer::DataChannelService Class Reference

#include <visiontransfer/datachannelservice.h>

Classes

class  Pimpl
 

Public Member Functions

 DataChannelService (DeviceInfo deviceInfo, unsigned long pollDelayUSec=1000)
 
bool imuAvailable ()
 Return whether the device will provide data from an Inertial Measurement Unit. More...
 
TimestampedQuaternion imuGetRotationQuaternion ()
 Return the most recent rotation quaternion, relative to gravity and magnetic north. More...
 
std::vector< TimestampedQuaternionimuGetRotationQuaternionSeries (int fromSec=0, int fromUSec=0, int untilSec=0x7FFFffffl, int untilUSec=0x7FFFffffl)
 Return the current contents of the rotation quaternion data buffer, optionally between specified timestamps. More...
 
TimestampedVector imuGetAcceleration ()
 Return the most recent calibrated accelerometer reading. More...
 
std::vector< TimestampedVectorimuGetAccelerationSeries (int fromSec=0, int fromUSec=0, int untilSec=0x7FFFffffl, int untilUSec=0x7FFFffffl)
 Return the current contents of the calibrated accelerometer data buffer, optionally between specified timestamps. More...
 
TimestampedVector imuGetGyroscope ()
 Return the most recent calibrated angular accelerations from the gyroscope. More...
 
std::vector< TimestampedVectorimuGetGyroscopeSeries (int fromSec=0, int fromUSec=0, int untilSec=0x7FFFffffl, int untilUSec=0x7FFFffffl)
 Return the current contents of the gyroscope data buffer, optionally between specified timestamps. More...
 
TimestampedVector imuGetMagnetometer ()
 Return the most recent magnetometer readings. More...
 
std::vector< TimestampedVectorimuGetMagnetometerSeries (int fromSec=0, int fromUSec=0, int untilSec=0x7FFFffffl, int untilUSec=0x7FFFffffl)
 Return the current contents of the magnetometer data buffer, optionally between specified timestamps. More...
 
TimestampedVector imuGetLinearAcceleration ()
 Return the most recent linear acceleration, i.e. with gravity factored out. More...
 
std::vector< TimestampedVectorimuGetLinearAccelerationSeries (int fromSec=0, int fromUSec=0, int untilSec=0x7FFFffffl, int untilUSec=0x7FFFffffl)
 Return the current contents of the linear acceleration (without gravity) data buffer, optionally between specified timestamps. More...
 
TimestampedVector imuGetGravity ()
 Return the most recent gravity measurement. More...
 
std::vector< TimestampedVectorimuGetGravitySeries (int fromSec=0, int fromUSec=0, int untilSec=0x7FFFffffl, int untilUSec=0x7FFFffffl)
 Return the current contents of the gravity data buffer, optionally between specified timestamps. More...
 

Detailed Description

This is the DataChannelServer public API, backwards compatible with C++-98

The DataChannelService encapsulates miscellaneous device services, which are not implemented on all Nerian devices. Availability can be queried; access to unavailable elements will normally return default values or silently execute nothing.

The imuGet...() and envGet...() functions access an inertial measurement unit with attached environmental sensor, realized with the Hillcrest BNO080 and Bosch BME280, respectively, on supported devices.

Definition at line 40 of file datachannelservice.h.

Constructor & Destructor Documentation

◆ DataChannelService()

visiontransfer::DataChannelService::DataChannelService ( DeviceInfo  deviceInfo,
unsigned long  pollDelayUSec = 1000 
)

Initialize a new background data channel service, connecting to the specified device. The optional argument pollDelayUSec is used in the background receive/update loop, the default of 1000us can be overridden for the sake of efficiency or if minimum latency requirements differ.

Definition at line 165 of file datachannelservice.cpp.

Member Function Documentation

◆ imuAvailable()

bool visiontransfer::DataChannelService::imuAvailable ( )

Return whether the device will provide data from an Inertial Measurement Unit.

Definition at line 175 of file datachannelservice.cpp.

◆ imuGetAcceleration()

TimestampedVector visiontransfer::DataChannelService::imuGetAcceleration ( )

Return the most recent calibrated accelerometer reading.

Definition at line 190 of file datachannelservice.cpp.

◆ imuGetAccelerationSeries()

std::vector< TimestampedVector > visiontransfer::DataChannelService::imuGetAccelerationSeries ( int  fromSec = 0,
int  fromUSec = 0,
int  untilSec = 0x7FFFffffl,
int  untilUSec = 0x7FFFffffl 
)

Return the current contents of the calibrated accelerometer data buffer, optionally between specified timestamps.

This operation consumes an internal ring buffer up to the desired end stamp, data older than the desired window is silently discarded.

Definition at line 193 of file datachannelservice.cpp.

◆ imuGetGravity()

TimestampedVector visiontransfer::DataChannelService::imuGetGravity ( )

Return the most recent gravity measurement.

Definition at line 218 of file datachannelservice.cpp.

◆ imuGetGravitySeries()

std::vector< TimestampedVector > visiontransfer::DataChannelService::imuGetGravitySeries ( int  fromSec = 0,
int  fromUSec = 0,
int  untilSec = 0x7FFFffffl,
int  untilUSec = 0x7FFFffffl 
)

Return the current contents of the gravity data buffer, optionally between specified timestamps.

This operation consumes an internal ring buffer up to the desired end stamp, data older than the desired window is silently discarded.

Definition at line 221 of file datachannelservice.cpp.

◆ imuGetGyroscope()

TimestampedVector visiontransfer::DataChannelService::imuGetGyroscope ( )

Return the most recent calibrated angular accelerations from the gyroscope.

Definition at line 197 of file datachannelservice.cpp.

◆ imuGetGyroscopeSeries()

std::vector< TimestampedVector > visiontransfer::DataChannelService::imuGetGyroscopeSeries ( int  fromSec = 0,
int  fromUSec = 0,
int  untilSec = 0x7FFFffffl,
int  untilUSec = 0x7FFFffffl 
)

Return the current contents of the gyroscope data buffer, optionally between specified timestamps.

This operation consumes an internal ring buffer up to the desired end stamp, data older than the desired window is silently discarded.

Definition at line 200 of file datachannelservice.cpp.

◆ imuGetLinearAcceleration()

TimestampedVector visiontransfer::DataChannelService::imuGetLinearAcceleration ( )

Return the most recent linear acceleration, i.e. with gravity factored out.

Definition at line 211 of file datachannelservice.cpp.

◆ imuGetLinearAccelerationSeries()

std::vector< TimestampedVector > visiontransfer::DataChannelService::imuGetLinearAccelerationSeries ( int  fromSec = 0,
int  fromUSec = 0,
int  untilSec = 0x7FFFffffl,
int  untilUSec = 0x7FFFffffl 
)

Return the current contents of the linear acceleration (without gravity) data buffer, optionally between specified timestamps.

This operation consumes an internal ring buffer up to the desired end stamp, data older than the desired window is silently discarded.

Definition at line 214 of file datachannelservice.cpp.

◆ imuGetMagnetometer()

TimestampedVector visiontransfer::DataChannelService::imuGetMagnetometer ( )

Return the most recent magnetometer readings.

Definition at line 204 of file datachannelservice.cpp.

◆ imuGetMagnetometerSeries()

std::vector< TimestampedVector > visiontransfer::DataChannelService::imuGetMagnetometerSeries ( int  fromSec = 0,
int  fromUSec = 0,
int  untilSec = 0x7FFFffffl,
int  untilUSec = 0x7FFFffffl 
)

Return the current contents of the magnetometer data buffer, optionally between specified timestamps.

This operation consumes an internal ring buffer up to the desired end stamp, data older than the desired window is silently discarded.

Definition at line 207 of file datachannelservice.cpp.

◆ imuGetRotationQuaternion()

TimestampedQuaternion visiontransfer::DataChannelService::imuGetRotationQuaternion ( )

Return the most recent rotation quaternion, relative to gravity and magnetic north.

Definition at line 183 of file datachannelservice.cpp.

◆ imuGetRotationQuaternionSeries()

std::vector< TimestampedQuaternion > visiontransfer::DataChannelService::imuGetRotationQuaternionSeries ( int  fromSec = 0,
int  fromUSec = 0,
int  untilSec = 0x7FFFffffl,
int  untilUSec = 0x7FFFffffl 
)

Return the current contents of the rotation quaternion data buffer, optionally between specified timestamps.

This operation consumes an internal ring buffer up to the desired end stamp, data older than the desired window is silently discarded.

Definition at line 186 of file datachannelservice.cpp.


The documentation for this class was generated from the following files:
Nerian Vision Technologies