A structure for storing device modes using period and skip factor (new default). More...
#include <Robots/SeaBeeIII/IMUDataServer/cmtdef.h>
Public Member Functions | |
CmtDeviceMode2 (const CmtOutputMode mode=CMT_DEFAULT_OUTPUT_MODE, const CmtOutputSettings settings=CMT_DEFAULT_OUTPUT_SETTINGS, const uint16_t period=CMT_DEFAULT_PERIOD, const uint16_t skip=CMT_DEFAULT_SKIP) | |
default constructor, initializes to the given (default) MT settings | |
double | getRealSampleFrequency (void) const |
Return the real sample frequency in Hz. | |
uint16_t | getSampleFrequency (void) const |
Return the sample frequency in Hz. | |
void | setSampleFrequency (uint16_t freq) |
Compute the period and skip factor from a sample frequency. | |
bool | operator== (const CmtDeviceMode2 &dev) const |
Check if all fields of the two structures are equal. | |
Public Attributes | |
CmtOutputMode | m_outputMode |
CmtOutputSettings | m_outputSettings |
uint16_t | m_period |
uint16_t | m_skip |
A structure for storing device modes using period and skip factor (new default).
Definition at line 1068 of file cmtdef.h.
CmtDeviceMode2::CmtDeviceMode2 | ( | const CmtOutputMode | mode = CMT_DEFAULT_OUTPUT_MODE , |
|
const CmtOutputSettings | settings = CMT_DEFAULT_OUTPUT_SETTINGS , |
|||
const uint16_t | period = CMT_DEFAULT_PERIOD , |
|||
const uint16_t | skip = CMT_DEFAULT_SKIP | |||
) | [inline] |
double CmtDeviceMode2::getRealSampleFrequency | ( | void | ) | const |
Return the real sample frequency in Hz.
This may be up to 2Hz different from the value that is set.
Definition at line 144 of file cmt3.cpp.
Referenced by xsens::Cmt3::fillRtc().
uint16_t CmtDeviceMode2::getSampleFrequency | ( | void | ) | const |
Return the sample frequency in Hz.
This may be up to 2Hz different from the value that is set.
Definition at line 154 of file cmt3.cpp.
Referenced by xsens::Cmt3::getDeviceMode(), and xsens::Cmt3::getSampleFrequency().
bool CmtDeviceMode2::operator== | ( | const CmtDeviceMode2 & | dev | ) | const |
void CmtDeviceMode2::setSampleFrequency | ( | uint16_t | freq | ) |
Compute the period and skip factor from a sample frequency.
This function does the reverse of the getPeriodAndSkipFactor function, storing the value in the m_period and m_skip field.
Definition at line 162 of file cmt3.cpp.
Referenced by xsens::Cmt3::setDeviceMode().