skullc-peripherals/Peripherals/Inc/peripherals_imu.hpp
Erki 60bad24319
Some checks failed
continuous-integration/drone/push Build is failing
The great renaming, part 1
2021-06-08 23:18:56 +03:00

39 lines
665 B
C++

/*
* peripherals_imu.hpp
*
* Created on: Mar 5, 2021
* Author: erki
*/
#ifndef SKULLC_PERIPHERALS_IMU_HPP_
#define SKULLC_PERIPHERALS_IMU_HPP_
#include <cstdint>
namespace Peripherals
{
class IImu
{
public:
enum class Axis : std::uint32_t
{
X = 0,
Y,
Z
};
virtual void setup() = 0;
virtual void calibrate(const std::uint32_t samples) = 0;
virtual void readGyro(float* output) = 0;
virtual void readGyroRaw(std::int16_t* output) = 0;
virtual void readAccelerometer(float* output) = 0;
virtual void readAccelerometerRaw(std::int16_t* output) = 0;
};
}// namespace Peripherals
#endif /* SKULLC_PERIPHERALS_IMU_HPP_ */