EduArt Sensor Ring Library 4.0.0
Loading...
Searching...
No Matches
eduart::sensorring::device::TMF8829_Params Struct Reference

Parameter structure of the TMF8829 sensor of a sensor board. More...

#include <TMF8829_Params.hpp>

Inheritance diagram for eduart::sensorring::device::TMF8829_Params:
[legend]
Collaboration diagram for eduart::sensorring::device::TMF8829_Params:
[legend]

Public Member Functions

 TMF8829_Params ()
 Default constructor; sets the maximum measurement rate to 30 Hz.
 TMF8829_Params (const DepthSensorParams &params)
 Initializes the TMF8829_Params from a DepthSensorParams instance.
std::size_t calculateResultFrameSize () const
 Calculate the resulting frame size of the current parameters.
bool isResultSizeValid () const
 Check if the combination of the specified parameters is valid.
Public Member Functions inherited from eduart::sensorring::device::DepthSensorParams
virtual ~DepthSensorParams ()=default
 Destructor.

Public Attributes

ResolutionMode resolution_mode = ResolutionMode::Res8x8
 Resolution mode of the sensor. See TMF8829 datasheet for details on the different modes.
std::uint16_t k_iterations = 0
 Iterations setting of the sensor in kilo iteration per measurement. Refer to the TMF8829 datasheet for more details about this setting. Set to 0 for sensor default value.
TMF8829_ResultFormat result_format
 Result format of the measurement. Specifies which additional values are included in each measurement.
Public Attributes inherited from eduart::sensorring::device::DeviceParams
DeviceID id
 Device identifier (type, name, index).
bool enable = true
 Whether the device is enabled at creation.
double max_rate_hz = 15.0

Detailed Description

Parameter structure of the TMF8829 sensor of a sensor board.

Member Function Documentation

◆ calculateResultFrameSize()

std::size_t eduart::sensorring::device::TMF8829_Params::calculateResultFrameSize ( ) const

Calculate the resulting frame size of the current parameters.

In high resolution modes, the measurement is split across two frames. This method returns the per-frame size.

Returns
The size of the result frame in bytes.

◆ isResultSizeValid()

bool eduart::sensorring::device::TMF8829_Params::isResultSizeValid ( ) const

Check if the combination of the specified parameters is valid.

The maximum result size per frame is limited to 8192 bytes. The result size is a function of the resolution mode (point count) and the result format (point size).

Returns
True if the parameters are valid, false otherwise.

The documentation for this struct was generated from the following file: