Topics covered in the BerryGPS and BerryGPS-IMU Quick Start Guide;
- BerryGPS-IMU PCB overview
- BerryGPS-IMU Schematic
- How to Assemble BerryGPS-IMU
- Connecting BerryGPS-IMU to a Raspberry Pi
- BerryGPS-IMU datasheets.
- BerryGPS-IMU i2c addresses.
- Sample code for IMU
- BerryGPS-IMU Guides and tutorials
PCB Overview BerryIMUv4
BerryGPS-IMUv4

GPS related
uFL connector - This is where an external antenna can be connected, using a uFL to SMA adapter.
Switch for external antenna- If an external antenna is connected, this switch should be in the Ext position. When using the internal antenna, it should be in the Int Position.
Super Cap - This super capacitor stores enough energy to keep ephemeris data stored in battery backup RAM for up to 4hrs. This allows for very fast acquisition during power cycles .
GPS Reset (RST_N) Driving this pin low will activate a hardware reset of the GPS module.
GPS T_Pulse/PPS(T_PULSE) A configurable time pulse signal. By default, the time pulse signal is configured to one pulse per second (1 PPS)
IMU Related
The pin descriptions are documented on the back of the PCB.
I2C pins
When not using the female header to connect the BerryGPS-IMUv4 ,you can access the I2C pins below. For a Raspberry Pi you would use the I2C 3.3v pins and for an Arduino you would need to use the I2C 5v pins

3.3v SPI and interrupt pins
The 3.3v IMU SPI pins are shown bellow as well as the IMU Interrupt pins.
To enable SPI communication for the accelerometer and gyroscope, you need to close jumpers JP9 and JP13 by placing a solder blob on the jumper.

5v SPI pins
The 5V SPI pins for the accelerometer and gyroscope of highlighted below. This is where you would connect an Arduino via SPI. you need to close jumpers JP9 and JP13 by placing a solder blob on the jumper.

Schematic for BerryGPS-IMUv4
PCB Overview BerryIMUv3
GPS related
uFL connector - This is where an external antenna can be connected, using a uFL to SMA adapter.
Switch for external antenna- If an external antenna is connected, this switch should be in the Ext position. When using the internal antenna, it should be in the Int Position.
Super Cap - This super capacitor stores enough energy to keep ephemeris data stored in battery backup RAM for up to 4hrs. This allows for very fast acquisition during power cycles .
Interface Select(DSEL) Determines which data interfaces are used for communication.
RESET_N(RST_N) Driving this pin low will activate a hardware reset of the GPS module.
Time Pulse(T_PULSE) A configurable time pulse signal. By default, the time pulse signal is configured to one pulse per second (1 PPS)
GPS External Interrupt(EXTINT) An external interrupt pin which can be used for wake-up functions in Power Save Mode and for aiding.
uSCL and uSDA uBlox GPS Display Data Channel (DDC).
Antenna LNA Control(LNA_EN) This pin is used to turn on/off an optional external LNA using the LNA_EN signal in order to optimize power consumption. Drive low to turn LNA off.
IMU Related
The IMU extra Pins have been broken out onto the PCB, these are;
- INT2_XM - Accelerometer and magnetometer interrupt 1.
- INT1_XM - Accelerometer and magnetometer interrupt 2.
- DRDY_G - Gyroscope data ready.
- INT_G - Gyroscope interrupt.
- DEN_G - Gyroscope data enable.
How to Assemble BerryGPS-IMU
BerryGPS-IMU comes with one 5x2 female header.
This header needs to be soldered onto the back of the PCB. The image below shows where it is placed;
Connecting BerryGPS and BerryGPS-IMU to a Raspberry Pi
BerryGPS and BerryGPS-IMU sit on top of the raspberry Pi GPIO as shown in the images below.


The BerryGPS-IMUv4 can also be connected to a Raspberry Pi using a QWIIC connector and cable
When connecting via QWIIC connector only, the GPS module can only be accessed via I2C
Datasheets for BerryGPS-IMU
BerryGPS-IMUv4
GPS specific
- CAM-M8-FW3_DataSheet_(UBX-15031574)
- CAM-M8-FW3_HardwareIntegrationManual_(UBX-15030063)
- uBlox M8 Receiver Description and protocol manual
Datasheets for IMU
- LSM6DSL - Accelerometer and gyroscope datasheet
- LIS3MDL - Magnetometer datasheet
- BM388 - Pressure sensor datasheet
BerryGPS-IMUv3
GPS specific
- CAM-M8-FW3_DataSheet_(UBX-15031574)
- CAM-M8-FW3_HardwareIntegrationManual_(UBX-15030063)
- uBlox M8 Receiver Description and protocol manual
Datasheets for IMU
BerryGPS-IMU I2C Addresses
BerryGPS-IMUv3
- 0x6A for the gyroscope and accelerometer
- 0x1C for the magnetometer
- 0x77 for the pressure sensor
- 0x42 for GPS

Gyroscope and accelerometer I2C address - JP5 - By default, this jumper is open, which gives the gyroscope and accelerometer an address of 0x6A. When closed, the address will change to 0x6B. The jumper can be closed by placing a blob of solder on the jumper
Magnetometer I2C address - JP12 - By default, this jumper is open, which gives the accelerometer and magnetometer an address of 0x1C. When closed, the address will change to 0x1E. The jumper can be closed by placing a blob of solder on the jumper.
BerryGPS-IMUv3
- 0x6A for the gyroscope and accelerometer
- 0x1C for the magnetometer
- 0x77 for the pressure sensor

Gyroscope and accelerometer I2C address - JP5 - By default, this jumper is open, which gives the gyroscope and accelerometer an address of 0x6A. When closed, the address will change to 0x6B. The jumper can be closed by placing a blob of solder on the jumper
Magnetometer I2C address - JP1 - By default, this jumper is open, which gives the accelerometer and magnetometer an address of 0x1C. When closed, the address will change to 0x1E. The jumper can be closed by placing a blob of solder on the jumper.
Pressure senor I2C address - JP3 - By default, this jumper is closed, which gives the pressure sensor an I2C address of 0x77. Opening this jumper will change the I2C address to 0x76. This can be opened by cutting the trace in between the jumper pads with a knife.
BerryGPS-IMU Extra information
The BerryGPS-IMU uses the same sensors found on the BerryIMU. These means that all of the guides and code used for the BerryIMU can also be used with the BerryGPS-IMU.
Sample Code for IMU
Git repository here
The code can be pulled down to your Raspberry Pi with;
BerryGPS-IMU Guides and Tutorials
For the GPS:
- BerryGPS setup Guide for Raspberry PI
- BerryGPS Data logger using a BerryGPS
- Navigating with Navit on the Raspberry Pi
- Use u-Center graphical interface to control GPS
- Accessing GPS via I2C
- BerryGPS-IMU FAQ
For the IMU:
- 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”
- How to Create an Inclinometer using a Raspberry Pi and an IMU
- Raspberry Pi Digital Spirit Level
- Double tap detection with BerryIMUv3
- Using SPI on the BerryIMUv3