Topics covered in the BerryIMU Quick Start Guide;
- Connecting BerryIMU to a Raspberry Pi.
- Connecting BerryIMU to an Arduino
- BerryIMU sensor datasheets.
- BerryIMU i2c addresses.
- Mechanical dimensions.
- Sample code.
- Guides and tutorials
Connecting BerryIMU to a Raspberry Pi
BerryIMUv2 only supports I2C and connects as shown below.
BerryIMUv3 supports I2C and SPI.
The BerryIMUv3 also works with the Raspberry Pi Pico
By default, the BerryIMUv3 is configured to work with I2C. To use SPI, you will need to close jumper JP7 (shown below) to complete the SPI connection. This can be done by placing a solder blob on the jumper.
Connecting BerryIMU to an Arduino
BerryIMUv2 only supports I2C and connects as shown below.
BerryIMUv3 supports I2C and SPI.
By default, the BerryIMUv3 is configured to work with I2C. To use SPI, you will need to close jumper JP7 (shown below) to complete the SPI connection. This can be done by placing a solder blob on the jumper.

Datasheets for BerryIMU
Datasheets for BerryIMU v2
- LSM9DS1 - Magnetometer, accelerometer and gyroscope datasheet can be found here.
- BM280 - Pressure sensor datasheet can be found here.
Datasheets for BerryIMU v3
- LSM6DSL - Accelerometer and gyroscope datasheet can be found here.
- LIS3MDL - Magnetometer datasheet can be found here
- BM388 - Pressure sensor datasheet can be found here.
BerryIMU i2c Addresses
BerryIMUv2
The default i2c addresses on the BerryIMUv2 are;
- 0x6A for the gyroscope and accelerometer
- 0x1C for the magnetometer
- 0x77 for the pressure sensor
Solder the pads on JP2 together will change the address for the accelerometer and magnetometer from 0x1C to 0x1E.
Solder the pads on JP5 together will change the address for the gyroscope from 0x6A to 0x6B.
BerryIMUv3
The default i2c addresses on the BerryIMUv3 are;
- 0x6A for the gyroscope and accelerometer
- 0x1C for the magnetometer
- 0x77 for the pressure sensor

Solder the pads on JP12 together will change the address for the magnetometer from 0x1C to 0x1E.
Solder the pads on JP5 together will change the address for the accelerometer and gyroscope from 0x6A to 0x6B.
Mechanical Dimensions
BerryIMUv3
Sample Code
Git repository here
The code can be pulled down to your Raspberry Pi with;
Schematic

Guides and Tutorials
- Guide to interfacing a Gyro and Accelerometer with a Raspberry Pi
- Guide to interfacing a Gyro and Accelerometer with a Raspberry Pi - Kalman Filter
- Create a Digital Compass with the Raspberry Pi – Part 1 – “The Basics”
- Create a Digital Compass with the Raspberry Pi – Part 2 – “Tilt Compensation”
- Create a Digital Compass with the Raspberry Pi – Part 3 – “Calibration”
- Create a Digital Compass with the Raspberry Pi – Part 4- “Smartphone Replica”
- Converting values from an Accelerometer to Gs – “ Proper Acceleration”
- Using the BerryIMUv3 on a Raspberry Pi Pico
- Double tap detection with BerryIMUv3
- Connect BerryIMUv3 via SPI
How to Create an Inclinometer using a Raspberry Pi and an IMU
Raspberry Pi Digital Spirit Level