Component guide · Intermediate · 3 min read
Bosch BMI270, BMI260, BMI160 (GY-BMI160) 6-Axis and BMX160 9-Axis IMUs

Pinout, Wiring and Code
By Geekobot Learning Team · Updated 29 Oct 2026
On this page
The Bosch BMI160 and its successors BMI260 and BMI270 are low-power 6-axis IMUs used in wearables, phones and robots. They pair a ±16 g accelerometer with a ±2000 °/s gyroscope and add step counting, tap, and wrist gestures in hardware. The BMX160 adds a magnetometer for 9 axes. They use I2C or SPI and draw under 1 mA.
Key specs at a glance
- Sensors
- 3-axis accel and gyro (BMX160 adds magnetometer)
- Ranges
- ±2 to ±16 g; ±125 to ±2000 °/s
- Data rate
- Up to 1.6 kHz accel, 6.4 kHz gyro
- Interface
- I2C (0x68 or 0x69) or SPI
- Supply
- 1.71 to 3.6 V (GY-BMI160 module 3 to 5 V)
- Features
- Step counter, tap, any-motion, wrist gestures (BMI270)
Models in this guide
These are alternatives. Pick the one that fits your project; you only need one.
Option 1Bosch BMI270 6-Axis IMU Motion Sensor, 16-Bit Accelerometer & Gyroscope, ±2/4/8/16g, ±125–2000°/s, I²C/SPI₹569
Option 2Bosch BMI260 6-Axis IMU | ±16g Accel + ±2000 dps Gyro | Low Power | I²C/SPI | LGA-14₹259
Option 3Bosch BMI160 6-Axis IMU Sensor, 16-bit Accelerometer & Gyroscope, I2C/SPI Interface, 1.2V-3.6V, -40°C to 85°C₹519
Option 4GY-BMI160 6DOF 6-Axis IMU Module – I2C/SPI Interface₹156
Option 5Bosch BMX160 9-Axis IMU Sensor, 16-bit Accelerometer, Gyroscope & Magnetometer, I²C/SPI, 1.71V~3.6V₹3,189
What the BMI160, BMI260, BMI270 and BMX160 IMUs is
The Bosch BMI270, BMI260 and BMI160 are low-power 6-axis IMUs with an accelerometer and gyro, used in wearables, phones and small robots.
The BMI270 needs a configuration file uploaded at start-up; the libraries do this for you. Without it, the gyro and features will not work.
These parts use much less power than the MPU6050, so they suit battery projects that wake on motion.
BMI160, BMI260, BMI270 and BMX160 IMUs pinout
The pins on the BMI160, BMI260, BMI270 and BMX160 IMUs and what each one does.
| Pin | Function |
|---|---|
| VIN / 3V3 | Supply |
| GND | Ground |
| SCL / SDA | I2C |
| SAO / SDO | Address select or SPI MISO |
| CS | SPI chip select |
| INT1 / INT2 | Interrupts |
- VIN / 3V3
- Supply
- GND
- Ground
- SCL / SDA
- I2C
- SAO / SDO
- Address select or SPI MISO
- CS
- SPI chip select
- INT1 / INT2
- Interrupts
Wiring the BMI160, BMI260, BMI270 and BMX160 IMUs
Modules with a regulator run from 3.3 V or 5 V. Bare chips (LGA or QFN parts) are 1.8 to 3.6 V only: mount them on a breakout and use a level shifter with 5 V boards.
| BMI160, BMI260, BMI270 and BMX160 IMUs pin | Arduino Uno | ESP32 |
|---|---|---|
| VCC | 5V (or 3.3V) | 3V3 |
| GND | GND | GND |
| SDA | A4 | GPIO 21 |
| SCL | A5 | GPIO 22 |
- VCC
- Arduino Uno:
- 5V (or 3.3V)
- ESP32:
- 3V3
- GND
- Arduino Uno:
- GND
- ESP32:
- GND
- SDA
- Arduino Uno:
- A4
- ESP32:
- GPIO 21
- SCL
- Arduino Uno:
- A5
- ESP32:
- GPIO 22
Example code
For the BMI160 use the DFRobot_BMI160 or BMI160-Arduino library; for the BMX160 use DFRobot_BMX160.
#include <SparkFun_BMI270_Arduino_Library.h>
BMI270 imu;
void setup() {
Serial.begin(115200);
Wire.begin();
while (imu.beginI2C(0x68) != BMI2_OK) { Serial.println("BMI270 not found"); delay(1000); }
}
void loop() {
imu.getSensorData();
Serial.printf("acc g %.2f %.2f %.2f gyro dps %.1f %.1f %.1f\n",
imu.data.accelX, imu.data.accelY, imu.data.accelZ,
imu.data.gyroX, imu.data.gyroY, imu.data.gyroZ);
delay(100);
}Setup and tuning
the I2C address is 0x68 or 0x69 depending on the SDO pin; match it in code.
the BMI270 needs a configuration blob uploaded at start-up; use a library that does this.
run the chip at 3.3 V; GY-BMI160 boards have a regulator for 5 V supply.
keep the board still and level at start-up and store the gyro offsets.
use the built-in motion and step interrupts to wake your board.
What you need
Shop this list7 of 9 found in our store · ₹5,250
Bosch BMI270 6-Axis IMU Motion Sensor, 16-Bit Accelerometer & Gyroscope, ±2/4/8/16g, ±125–2000°/s, I²C/SPI: the part this guide coversBosch BMI270 6-Axis IMU Motion Sensor, 16-Bit Accelerometer & Gyroscope, ±2/4/8/16g, ±125–2000°/s, I²C/SPI₹569
Bosch BMI260 6-Axis IMU | ±16g Accel + ±2000 dps Gyro | Low Power | I²C/SPI | LGA-14: another version this guide coversBosch BMI260 6-Axis IMU | ±16g Accel + ±2000 dps Gyro | Low Power | I²C/SPI | LGA-14₹259
Bosch BMI160 6-Axis IMU Sensor, 16-bit Accelerometer & Gyroscope, I2C/SPI Interface, 1.2V-3.6V, -40°C to 85°C: another version this guide coversBosch BMI160 6-Axis IMU Sensor, 16-bit Accelerometer & Gyroscope, I2C/SPI Interface, 1.2V-3.6V, -40°C to 85°C₹519
Generic GY-BMI160 6DOF 6-Axis IMU Module – I2C/SPI Interface: another version this guide coversGY-BMI160 6DOF 6-Axis IMU Module – I2C/SPI Interface₹156
Bosch BMX160 9-Axis IMU Sensor, 16-bit Accelerometer, Gyroscope & Magnetometer, I²C/SPI, 1.71V~3.6V: another version this guide coversBosch BMX160 9-Axis IMU Sensor, 16-bit Accelerometer, Gyroscope & Magnetometer, I²C/SPI, 1.71V~3.6V₹3,189
ESP32-WROOM-32 38-pin development board: for Wi-Fi logging and dashboardsESP32-WROOM-32 38-Pin Development Board₹389- Uno R3 development board: the controller used in the wiring tableFind this part
GY-521 MPU6050 6-axis module: the classic low-cost IMUGY-521 MPU6050 6-Axis Gyro and Accelerometer Module₹169Closest match, check the specs- BNO085 IMU module: gives ready-made orientationFind this part
Alternatives and when to choose them
Common mistakes to avoid
- Skipping the BMI270 configuration upload.
- Using the wrong I2C address for the SDO setting.
- Running a bare chip at 5 V.
- Moving the board during offset calibration.
Frequently asked questions
Why does my BMI270 return zeros?
It needs its configuration file loaded at start-up. Use a library such as SparkFun BMI270 that handles it.
What is the BMX160?
It is a 9-axis version with a magnetometer added, for heading as well as motion.
Is the BMI160 still a good choice?
It works well, but the BMI270 is newer with better gyro performance and low-power features.
Can it count steps?
Yes. The BMI270 and BMI160 have built-in step detectors and counters.
Can I use two on one I2C bus?
Yes. Set one to 0x68 and the other to 0x69 with the SDO pin.
Parts for this guide
Keep learning
Sources
Written by the Geekobot team from manufacturer datasheets. Always check the datasheet for the exact part and variant you buy.


