BerryGPS and BerryGPS-IMU Quick Start Guide

Topics covered in the BerryGPS and BerryGPS-IMU Quick Start Guide;

PCB Overview

BerryGPS-IMUv3

BerryGPS-IMUv3 pinout

 

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.

BerryGPS-IMUv2

Raspberry Pi GPS IMU

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 .

Packet Per Second pin and LED – The PPS LED will flash every 1 second and the PPS signal is broken out here. This pin can be used for time syncing of a microcontroller.

Fix pin and LED – The fix LED will flash every 1 seconds when the GPS module has a 3D fix. It is also broken out on a pin, which can be used by a microcontroller to to detect if a 3D fix has been obtained.

GPS Hardware Standby  – This pin is used to place the GPS module in a standby state. When set to a LOW state, the GPS module is placed in standby mode and uses <200uA of power. To re-enable, the pin needs to be set to a HIGH state.

This can also be done in software by sending $PMTK161,0*28 to the GPS module. Any other character can be used to wake up from standby mode.

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 and BerryGPS-IMU

BerryGPS and BerryGPS-IMU come with one 5×2 female header.
Female header 5x2

This header needs to be soldered onto the back of the PCB. The image below shows where it is placed;
BerryGPS Raspberry Pi Zero

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.

BerryGPS-IMU on Pi 3
BerryGPS-IMU on Pi Zero

Datasheets for BerryGPS and BerryGPS-IMU

LSM9DS0 – Magnetometer, accelerometer and gyroscope datasheet can be found here.
BMP280 – Pressure sensor datasheet can be found here.

GPS related Datasheets;
M10478-A2 – GPS module datasheet.
NMEA Sentence Output on the M10478-A2 
M10478-A2 NMEA Packet Manual

BerryGPS-IMU I2C Addresses

The default i2c addresses used by the IMU on BerryGPS-IMU are;

  • 0x1E for the magnetometer and accelerometer
  • 0x6A for the gyroscope
  • 0x77 for the pressure sensor
Raspberry Pi GPS I2C
I2C address jumpers on BerryGPS-IMU

The I2C addresses can be changed from their default be modifing the jumpers ADDR1ADDR2 and ADDR3 which are found on the back.

Gyroscope I2C address – ADDR1 –  By default, this jumper is open, which gives the gyroscope 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.

Accelerometer and magnetometer I2C address – ADDR2 –  By default, this jumper is open, which gives the accelerometer and magnetometer an address of 0xE1.  When closed, the address will change to 0x1D.  The jumper can be closed by placing a blob of solder on the jumper.

Pressure senor I2C address – ADDR – 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;

pi@raspberrypi ~ $ git clone http://github.com/ozzmaker/BerryIMU.git

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

For the IMU, In this order;

In this order;
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

Blip, blop, bloop…