LSM9DS1 Breakout Hookup Guide
The LSM9DS1 is one of only a handful of IC's that can measure three key properties of movement -- angular velocity, acceleration, and heading -- in a single IC.
The gyroscope can measure angular velocity -- that is "how fast, and along which axis, am I rotating?" Angular velocities are measured in degrees per second -- usually abbreviated to DPS or °/s. The LSM9DS1 can measure up to ± 2000 DPS, though that scale can also be set to either 245 or 500 DPS to get a finer resolution.
An accelerometer measures acceleration, which indicates how fast velocity is changing -- "how fast am I speeding up or slowing down?" Acceleration is usually either measured in m/s2 (meters per second per second) or g's (gravities [about 9.8 m/s2]). If an object is sitting motionless it feels about 1 g of acceleration towards the ground (assuming that ground is on earth, and the object is near sea-level). The LSM9DS1 measures its acceleration in g's, and its scale can be set to either ± 2, 4, 8, or 16 g.
Finally, there's the magnetometer, which measures the power and direction of magnetic fields. Though they're not easily visible, magnetic fields exist all around us -- whether you're holding a tiny ferromagnet or feeling an attraction to Earth's magnetic field. The LSM9DS1 measures magnetic fields in units of gauss (Gs), and can set its measurement scale to either ± 4, 8, 12, or 16 Gs.
By measuring these three properties, you can gain a great deal of knowledge about an object's movement and orientation. 9DOF's have tons and tons of applications. Measuring the force and direction of Earth's magnetic field with a magnetometer, you can approximate your heading. An accelerometer in your phone can measure the direction of the force of gravity, and estimate orientation (portrait, landscape, flat, etc.). Quadcopters with built-in gyroscopes can look out for sudden rolls or pitches, and correct their momentum before things get out of hand.
The LSM9DS1 measures each of these movement properties in three dimensions. That means it produces nine pieces of data: acceleration in x/y/z, angular rotation in x/y/z, and magnetic force in x/y/z. The LSM9DS1 Breakout has labels indicating the accelerometer and gyroscope axis orientations, which share a right-hand rule relationship with each other. Note that, according to the datasheet, the x and y axes of the magnetic sensor are flipped (the image above is copied from the datasheet).
The LSM9DS1 is, in a sense, two IC's smashed into one package -- like if you combined an LSM6DS3 accel/gryo with an LSM303DLMTR accel/mag. One half of the device takes care of all-things gyroscope and accelerometer, and the other half manages solely the magnetometer. In fact, a few of the control pins are dedicated to a single sensor -- there are two chip select pins (CS_AG for the accel/gyro and CS_M for the mag) and two serial data out pins (SDO_AG and SDO_M).
Choose Your Own Adventure: SPI or I2C
In addition to being able to measure a wide variety of movement vectors, the LSM9DS1 is also multi-featured on the communication interface end. It supports both SPI and I2C, so you should have no difficulty finding a microcontroller that can talk to it.
SPI is generally the easier of the two to implement, but it also requires more wires -- four versus I2C's two.
Because the LSM9DS1 supports both methods of communication, some pins have to pull double-duty. The Serial Data Out (SDO) pin for example, does just that for SPI mode, but if you're using the device over I2C it becomes an address selector. The chip select (CS_M and CS_AG) pins activate SPI mode when low, but if they're pulled high the device assumes I2C communication. In the section below we discuss each of the LSM9DS1's pins, watch out for those pins that support both interfaces.
For much more detailed information about the IC, we encourage you to check out the datasheet!