资源简介
BMI160 6轴惯性运动传
感器
代码片段和文件信息
#include“DFRobot_BMI160.h“
const uint8_t int_mask_lookup_table[13] = {
BMI160_INT1_SLOPE_MASK
BMI160_INT1_SLOPE_MASK
BMI160_INT2_LOW_STEP_DETECT_MASK
BMI160_INT1_DOUBLE_TAP_MASK
BMI160_INT1_SINGLE_TAP_MASK
BMI160_INT1_ORIENT_MASK
BMI160_INT1_FLAT_MASK
BMI160_INT1_HIGH_G_MASK
BMI160_INT1_LOW_G_MASK
BMI160_INT1_NO_MOTION_MASK
BMI160_INT2_DATA_READY_MASK
BMI160_INT2_FIFO_FULL_MASK
BMI160_INT2_FIFO_WM_MASK
};
DFRobot_BMI160::DFRobot_BMI160()
{
Wire.begin();
Obmi160=(struct bmi160Dev *)malloc(sizeof(struct bmi160Dev));
//Obmi160->id = BMI160_I2C_ADDR;
//Obmi160->interface = BMI160_I2C_INTF;
Oaccel= (struct bmi160SensorData*)malloc(sizeof(struct bmi160SensorData));
Ogyro = (struct bmi160SensorData*)malloc(sizeof(struct bmi160SensorData));
}
int8_t DFRobot_BMI160::I2cInit(int8_t i2c_addr)
{
Obmi160->id = i2c_addr;
Obmi160->interface = BMI160_I2C_INTF;
return DFRobot_BMI160::I2cInit(Obmi160);
}
int8_t DFRob
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2018-04-20 10:32 DFRobot_BMI160-master\
文件 37899 2018-04-20 10:32 DFRobot_BMI160-master\DFRobot_BMI160.cpp
文件 49223 2018-04-20 10:32 DFRobot_BMI160-master\DFRobot_BMI160.h
目录 0 2018-04-20 10:32 DFRobot_BMI160-master\examples\
目录 0 2018-04-20 10:32 DFRobot_BMI160-master\examples\accelGyro\
文件 1859 2018-04-20 10:32 DFRobot_BMI160-master\examples\accelGyro\accelGyro.ino
目录 0 2018-04-20 10:32 DFRobot_BMI160-master\examples\stepCounterLowPower\
文件 2526 2018-04-20 10:32 DFRobot_BMI160-master\examples\stepCounterLowPower\stepCounterLowPower.ino
目录 0 2018-04-20 10:32 DFRobot_BMI160-master\examples\stepCounterNormal\
文件 2528 2018-04-20 10:32 DFRobot_BMI160-master\examples\stepCounterNormal\stepCounterNormal.ino
文件 819 2018-04-20 10:32 DFRobot_BMI160-master\keywords.txt
文件 3457 2018-04-20 10:32 DFRobot_BMI160-master\readme.md
评论
共有 条评论