01-13-2023 11:06 AM
Hi,
We currently developing the software for bno085, we find that the accelearation is giving stable output but the gyro reading is floating around. Here is our initialization code. We use the bno08x driver as the baseline.
/*******************************************************************************
* Copyright(c) <2021>, Along
*
* Description:
* @file imu_test.c
*
* @brief
*
* This file contains the Test Application for imu
*
* Author - Along
*
*******************************************************************************
*
* History
*
* Dec/13/2022, Along, Created
*
*
******************************************************************************/
/*******************
* Includes
*******************/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <unistd.h>
#include <sys/ioctl.h>
#define IOCTL_MODULE "/dev/app_ioctl"
#define IMU_SENSOR_DATA _IOR('a',12,int32_t*)
struct bmi_sensor_data {
int16_t accel_x;
int16_t accel_y;
int16_t accel_z;
int16_t gyro_x;
int16_t gyro_y;
int16_t gyro_z;
};
int main()
{
int ret = 0;
struct bmi_sensor_data sensor_data = {0};
int fd = open(IOCTL_MODULE, O_RDWR);
if(fd < 0) {
printf("zxj ============open %s fail!\n", IOCTL_MODULE);
return -1;
}
while(1) {
ret = ioctl(fd, IMU_SENSOR_DATA, &sensor_data);
printf("App Acc_Raw_X : %d Acc_Raw_Y : %d Acc_Raw_Z : %d \n",
sensor_data.accel_x,
sensor_data.accel_y,
sensor_data.accel_z);
printf("Gyr_Raw_X : %d Gyr_Raw_Y : %d Gyr_Raw_Z : %d \n",
sensor_data.gyro_x,
sensor_data.gyro_y,
sensor_data.gyro_z);
}
close(fd);
return 0;
}
01-13-2023 12:17 PM
Hi MartinShi,
We are Bosch, and don't have the product BNO085. You could refer our product selector guide from https://www.bosch-sensortec.com/media/boschsensortec/downloads/promotion_material/product-selector-e...
BNO085 is the product of CEVA Technologies, Inc. You can get support from CEVA.
01-13-2023 12:48 PM
Hi RObin, sorry for the name, it shall be bmi085, we also having problem with reading the magnetic value with floating value, not stable. we use the reference code https://github.com/BoschSensortec/BMI08x-Sensor-API
01-31-2023 08:19 AM
Hi MartinShi,
For BMI085, you could run this example https://github.com/boschsensortec/BMI08x-Sensor-API/blob/master/examples/read_sensor_data/read_senso... and see the test result.
02-08-2023 10:53 PM