tutrcos
読み取り中…
検索中…
一致する文字列を見つけられません
tutrcos::module::BNO055 クラス

#include <bno055.hpp>

公開メンバ関数

 BNO055 (peripheral::UART &uart, uint32_t timeout=500)
 
bool init (uint32_t timeout)
 
bool update ()
 
void reset_euler ()
 
void reset_quat ()
 
float get_euler_x ()
 
float get_euler_y ()
 
float get_euler_z ()
 
float get_quat_w ()
 
float get_quat_x ()
 
float get_quat_y ()
 
float get_quat_z ()
 

詳解

#include <cstdio>
#include <tutrcos.hpp>
extern UART_HandleTypeDef huart2;
extern UART_HandleTypeDef huart3;
extern "C" void main_thread(void *) {
using namespace tutrcos::core;
using namespace tutrcos::peripheral;
using namespace tutrcos::module;
UART uart2(&huart2); // デバッグ出力用
uart2.enable_stdout();
UART uart3(&huart3);
BNO055 bno055(uart3);
bno055.init(500);
while (true) {
bno055.update();
// BNO055のオイラー角を出力
printf("%f %f %f\r\n", bno055.get_euler_x(), bno055.get_euler_y(),
bno055.get_euler_z());
Thread::delay(10);
}
}
Definition bno055.hpp:47
Definition uart.hpp:51
Definition kernel.hpp:8
Definition amt21.hpp:13
Definition can.hpp:15

構築子と解体子

◆ BNO055()

tutrcos::module::BNO055::BNO055 ( peripheral::UART & uart,
uint32_t timeout = 500 )
inline

関数詳解

◆ get_euler_x()

float tutrcos::module::BNO055::get_euler_x ( )
inline

◆ get_euler_y()

float tutrcos::module::BNO055::get_euler_y ( )
inline

◆ get_euler_z()

float tutrcos::module::BNO055::get_euler_z ( )
inline

◆ get_quat_w()

float tutrcos::module::BNO055::get_quat_w ( )
inline

◆ get_quat_x()

float tutrcos::module::BNO055::get_quat_x ( )
inline

◆ get_quat_y()

float tutrcos::module::BNO055::get_quat_y ( )
inline

◆ get_quat_z()

float tutrcos::module::BNO055::get_quat_z ( )
inline

◆ init()

bool tutrcos::module::BNO055::init ( uint32_t timeout)
inline

◆ reset_euler()

void tutrcos::module::BNO055::reset_euler ( )
inline

◆ reset_quat()

void tutrcos::module::BNO055::reset_quat ( )
inline

◆ update()

bool tutrcos::module::BNO055::update ( )
inline

このクラス詳解は次のファイルから抽出されました: