xref: /linux/Documentation/iio/bno055.rst (revision 4b132aacb0768ac1e652cf517097ea6f237214b9)
1.. SPDX-License-Identifier: GPL-2.0
2
3==============================
4BNO055 driver
5==============================
6
71. Overview
8===========
9
10This driver supports Bosch BNO055 IMUs (on both serial and I2C busses).
11
12Accelerometer, magnetometer and gyroscope measures are always provided.
13When "fusion_enable" sysfs attribute is set to 1, orientation (both Euler
14angles and quaternion), linear velocity and gravity vector are also
15provided, but some sensor settings (e.g. low pass filtering and range)
16became locked (the IMU firmware controls them).
17
18This driver supports also IIO buffers.
19
202. Calibration
21==============
22
23The IMU continuously performs an autocalibration procedure if (and only if)
24operating in fusion mode. The magnetometer autocalibration can however be
25disabled writing 0 in the sysfs in_magn_calibration_fast_enable attribute.
26
27The driver provides access to autocalibration flags (i.e. you can known if
28the IMU has successfully autocalibrated) and to the calibration data blob.
29
30The user can save this blob in a firmware file (i.e. in /lib/firmware) that
31the driver looks for at probe time. If found, then the IMU is initialized
32with this calibration data. This saves the user from performing the
33calibration procedure every time (which consist of moving the IMU in
34various way).
35
36The driver looks for calibration data file using two different names: first
37a file whose name is suffixed with the IMU unique ID (exposed in sysfs as
38serial_number) is searched for; this is useful when there is more than one
39IMU instance. If this file is not found, then a "generic" calibration file
40is searched for (which can be used when only one IMU is present, without
41struggling with fancy names, that change on each device).
42
43Valid calibration file names would be e.g.
44 bno055-caldata-0e7c26a33541515120204a35342b04ff.dat
45 bno055-caldata.dat
46
47In non-fusion mode the IIO 'offset' attributes provide access to the
48offsets from calibration data (if any), so that the user can apply them to
49the accel, angvel and magn IIO attributes. In fusion mode they are not
50needed (the IMU firmware internally applies those corrections) and they
51read as zero.
52