InertiaSDK

Loading...
Searching...
No Matches
GyroConfig.h
1#pragma once
2
3#include "data/config/InertialConfig.h"
4
5 namespace inertia
6{
7
9 enum GyroFilterBandwith { // low pass filter bandwidth in Hertz
10 GYRO_FILTER_256 = 0,
11 GYRO_FILTER_188,
12 GYRO_FILTER_98,
13 GYRO_FILTER_42,
14 GYRO_FILTER_20,
15 GYRO_FILTER_10,
16 GYRO_FILTER_5
17};
18
19 struct INERTIA_API GyroConfig
20 : InertialConfig
21{
22 uint8_t rateDivider; // sample rate divider, Fsample = Finternal / (divider+1))
23 GyroFilterBandwith filter; // low pass filter bandwidth
24 bool fullscale;
25
26 GyroConfig();
27 GyroConfig(uint8_t const* in);
28 GyroConfig(std::wstring const& argString);
29
30#ifdef WITH_BOOST_PROGRAM_OPTIONS
31 static const po::options_description GetOptionDescription();
32#endif
33
34 static unsigned GetLength();
35 void GetBytes(std::vector<uint8_t>& out) const override;
36 ConfigType GetConfigType() const override;
37 const std::wstring ToString() const override;
38 const std::wstring ToSimpleString(uint16_t const globalRate) const;
39 double GetRangeFactor() const override;
40 uint16_t GetMaxRate() const override;
41};
42
43}
inertia
Definition FlashCommands.h:6
inertia::ConfigType
ConfigType
Definition ConfigChannel.h:7
inertia::GyroFilterBandwith
GyroFilterBandwith
Definition GyroConfig.h:9