EduArt Sensor Ring Library 4.0.0
Loading...
Searching...
No Matches
TMF8829_Params.hpp
Go to the documentation of this file.
1// Copyright (c) 2026 EduArt Robotik GmbH
2
9
10#pragma once
11
12#include <cstddef>
13#include <cstdint>
14
17#include "sensorring/platform/SensorringExport.hpp"
18
19namespace eduart {
20
21namespace sensorring {
22
23namespace device {
27enum class ResolutionMode : std::uint8_t {
28 Res8x8 = 0,
29 Res8x8LongRange = 1,
30 Res8x8HighAccuracy = 2,
31 Res16x16 = 3,
32 Res16x16HighAccuracy = 4,
33 Res32x32 = 5,
34 Res32x32HighAccuracy = 6,
35 Res48x32 = 7,
36 Res48x32HighAccuracy = 8
37};
38
44unsigned int getXResolution(ResolutionMode mode);
45
51unsigned int getYResolution(ResolutionMode mode);
52
58SENSORRING_EXPORT std::string toString(ResolutionMode mode) noexcept;
59
66SENSORRING_EXPORT std::ostream& operator<<(std::ostream& os, ResolutionMode mode) noexcept;
67
72struct SENSORRING_EXPORT TMF8829_Params : public DepthSensorParams {
73
76
79 : DepthSensorParams{ params } {
80 max_rate_hz = 30.0;
81 };
82
84 ResolutionMode resolution_mode = ResolutionMode::Res8x8;
85
87 std::uint16_t k_iterations = 0;
88
91
100 std::size_t calculateResultFrameSize() const;
101
111 bool isResultSizeValid() const;
112};
113
114} // namespace device
115
116} // namespace sensorring
117
118} // namespace eduart
Parameter structure for the DepthSensor.
unsigned int getXResolution(ResolutionMode mode)
Get the horizontal resolution (number of columns) for a given resolution mode.
SENSORRING_EXPORT std::ostream & operator<<(std::ostream &os, ResolutionMode mode) noexcept
Output stream operator for the ResolutionMode enum class members.
ResolutionMode
Supported resolution modes of the TMF8829 sensor.
Definition TMF8829_Params.hpp:27
unsigned int getYResolution(ResolutionMode mode)
Get the vertical resolution (number of rows) for a given resolution mode.
SENSORRING_EXPORT std::string toString(ResolutionMode mode) noexcept
Function to convert the ResolutionMode enum class members to string.
Result format structure for the TMF8829 Time-of-Flight sensor.
Parameter structure of the DepthSensor.
Definition DepthSensorParams.hpp:25
double max_rate_hz
Definition DeviceParams.hpp:39
bool isResultSizeValid() const
Check if the combination of the specified parameters is valid.
std::size_t calculateResultFrameSize() const
Calculate the resulting frame size of the current parameters.
TMF8829_Params()
Default constructor; sets the maximum measurement rate to 30 Hz.
Definition TMF8829_Params.hpp:75
TMF8829_ResultFormat result_format
Result format of the measurement. Specifies which additional values are included in each measurement.
Definition TMF8829_Params.hpp:90
std::uint16_t k_iterations
Iterations setting of the sensor in kilo iteration per measurement. Refer to the TMF8829 datasheet fo...
Definition TMF8829_Params.hpp:87
TMF8829_Params(const DepthSensorParams &params)
Initializes the TMF8829_Params from a DepthSensorParams instance.
Definition TMF8829_Params.hpp:78
ResolutionMode resolution_mode
Resolution mode of the sensor. See TMF8829 datasheet for details on the different modes.
Definition TMF8829_Params.hpp:84
Specifies which values are included in the TMF8829 measurement.
Definition TMF8829_ResultFormat.hpp:27