Parallax LSM9DS1 9-axis IMU Module (#28065)

Similar documents
Compass Module 3-Axis HMC5883L (#29133)

Gyroscope Module 3-Axis L3G4200D (#27911)

Modern Robotics Inc. Sensor Documentation

Web Site: Forums: forums.parallax.com Sales: Technical:

Description. Table 1. Device summary. Part number Temperature range [ C] Package Packing

Me 3-Axis Accelerometer and Gyro Sensor

Web Site: Forums: forums.parallax.com Sales: Technical:

BNO055 Quick start guide

Propeller Project Board USB (#32810)

Propeller Activity Board (#32910)

Web Site: Forums: forums.parallax.com Sales: Technical:

Table of Contents 1 Typical Applications General Description Block Diagram Pinout System Connections Typical A

Fully Integrated Thermal Accelerometer MXC6225XU

Sensor Toolbox (Part 2): Inertial Sensors

XS S ERIES TM PMB US TM O PTION C ARD

2011 FIRST Robotics Competition Sensor Manual

ELEV-8 Flight Controller (#80204)

GRAVITECH GROUP

Parallax WX ESP8266 Wi-Fi Modules

DIGITAL COMPASS SOLUTION

Adafruit HMC5883L Breakout - Triple-Axis Magnetometer Compass Sensor

IST8301C 3D Magnetometer Sensor. Datasheet

ASM330LHH. Automotive 6-axis inertial module: 3D accelerometer and 3D gyroscope. Data brief. Features. Applications. Description

Gumstix Pi HAT Sensor board

Inertial Measurement Units I!

IMU Axis Gyro Evaluation Board Application Note

Using Sensors with the RoboRIO

Web Site: Forums: forums.parallax.com Sales: Technical:

Adafruit LSM9DS1 Accelerometer + Gyro + Magnetometer 9-DOF Breakout

AN055. Replacing KX023, KX123, KX124 with KXG07. Introduction

AN 038. Getting Started with the KXTJ2. Introduction

Proto-DB (#28310): Prototyping Daughterboard

Manual iaq-engine Indoor Air Quality sensor

ECV ecompass Series. Technical Brief. Rev A. Page 1 of 8. Making Sense out of Motion

Web Site: Forums: forums.parallax.com Sales: Technical:

Cross-Domain Development Kit XDK110 Platform for Application Development

Navigational Aids 1 st Semester/2007/TF 7:30 PM -9:00 PM

RoBoard Module RM-G146 Manual V1.01 The Heart of Robotics. Jan 2011 DMP Electronics Inc

KXCJK AN 039. Getting Started with the KXCJK. Introduction

17. I 2 C communication channel

Hitachi H48C 3-Axis Accelerometer Module (#28026)

Serial Peripheral Interface Bus SPI

PWR-I/O-DB Power and I/O Daughterboard (#28301)

ARDUINO MICRO WITHOUT HEADERS Code: A000093

MPU-6000/MPU Axis Evaluation Board User Guide

PAT9125EL: Optical Tracking Miniature Chip

MAG3110 Magnetometer Hookup Guide

Using the MPU Inertia Measurement Systems Gyroscopes & Accelerometers Sensor fusion I2C MPU-6050

XDK HARDWARE OVERVIEW

Mio- x AHRS. Attitude and Heading Reference System. Engineering Specifications

CW2013. Low-Cost 1s Fuel Gauge IC with Low-SOC Alert. General Description. Features. Applications. Order Information

Pedometer 3 Click. PID: MIKROE 3259 Weight: 24 g

SP-7 AHRS. Firmware upgrade instructions. Installation and calibration

AN-1025 APPLICATION NOTE

DS75 Digital Thermometer and Thermostat

LIS3DH Hookup Guide. Introduction. SparkFun Triple Axis Accelerometer Breakout - LIS3DH SEN Required Materials

Arduino Uno. Arduino Uno R3 Front. Arduino Uno R2 Front

Embedded Navigation Solutions. VN-100 User Manual. Firmware v Document Revision UM001 Introduction 1

Applications: Industrial Automation, Cranes, Hoists, Utility Vehicles, Off-highway, Ag, and Forestry Equipment

Propeller Board of Education (#32900)

Arduino Uno R3 INTRODUCTION

USB Virtual Reality HID. by Weston Taylor and Chris Budzynski Advisor: Dr. Malinowski

Sensing our world PRODUCT OVERVIEW

MAG3110 Frequently Asked Questions

User-configurable Resolution. 9 to 12 bits (0.5 C to C)

SparkFun Blocks for Intel Edison - 9 Degrees of Freedom Block

I2C-AO112DIx I2C-Bus 4-20mA Analog Output Boards Din-Rail supports

GENERAL DESCRIPTION MC3635 FEATURES

mcube Proprietary APS v1.0 1 / mcube Inc. All rights reserved.

GSDM110 Three-Axis Digital Magnetometer

DS Wire Digital Thermometer and Thermostat

Application Guidelines for MEMS Compass

XBee USB Adapter Board (#32400)

User-configurable Resolution. 9 to 12 bits (0.5 C to C)

navigation Isaac Skog

CSE 466 Exam 1 Winter, 2010

Camera Drones Lecture 2 Control and Sensors

DS1870 LDMOS BIAS CONTROLLER EV KIT

GRAVITECH GROUP

ARDUINO MEGA ADK REV3 Code: A000069

HZX N03 Bluetooth 4.0 Low Energy Module Datasheet

Display Real Time Clock (RTC) On LCD. Version 1.2. Aug Cytron Technologies Sdn. Bhd.

IOX-16 User s Manual. Version 1.00 April Overview

GPIO-MM User Manual. FPGA-based PC/104 Counter/Timer and Digital I/O Module. User Manual v1.0 Personality 0x22

Inertial Navigation Static Calibration

QUICK START GUIDE FOR DEMONSTRATION CIRCUIT DC BIT MICROPOWER NO LATENCY DELTA SIGMA ADC LTC2400 DESCRIPTION

USB-I2C USB to I2C Communications Module Technical Specification

KNJN I2C bus development boards

Arduino ADK Rev.3 Board A000069

keyestudio Keyestudio MEGA 2560 R3 Board

DS1676 Total Elapsed Time Recorder, Erasable

3DM-GX1 Data Communications Protocol

Propeller Proto Board (#32212) Propeller Proto Board USB (#32812) Proto Board Accessory Kit (# )

Using an Analog Devices AD774X Capacitance-to-Digital Converter for Differential Button Sensor Operation

ARDUINO MEGA 2560 REV3 Code: A000067

OEM-ORP ORP. Reads mV mV. Range. 1 reading every 420ms. Response time. Any type & brand. Supported probes. Single point.

VLSI AppNote: VSx053 Simple DSP Board

Emulating I2C Bus Master by using FlexIO

Pmod modules are powered by the host via the interface s power and ground pins.

DS1625. Digital Thermometer and Thermostat FEATURES PIN ASSIGNMENT

Transcription:

Web Site: www.parallax.com Forums: forums.parallax.com Sales: sales@parallax.com Technical:support@parallax.com Office: (916) 624-8333 Fax: (916) 624-8003 Sales: (888) 512-1024 Tech Support: (888) 997-8267 Parallax LSM9DS1 9-axis IMU Module (#28065) With the LSM9DS1 9-axis motion sensor module, your projects can measure direction, orientation, and motion. The LSM9DS1 sensor, used on our ELEV-8 v3 Quadcopter's Flight Controller, is now available in a SIP module for easy prototyping or conveniently studying the physics involved in motion tracking. This LSM9DS1 sensor is a system-on-a-chip that takes 4 kinds of measurements, using: a 3-axis accelerometer (for measuring gravity or acceleration in 3D space), a 3-axis gyroscope (for measuring rotation), a 3-axis magnetometer (for measuring magnetic field strength - used to find Magnetic North), and a temperature sensor. The LSM9DS1 9-axis motion sensor module can be used with nearly any microcontroller. It can be powered by 2.8, 3.3 or 5 volts and it uses either a 3-pin SPI interface or an I2C bus. Use it as a single sensor accelerometer, a gyroscope, a magnetometer, or a temperature sensor or all of the measurements can be read together for use in inertial measurement or dead-reckoning applications. It can also be configured to drive an interrupt when detecting impacts, free-fall, or magnetic field ranges. Features Measures linear acceleration, angular velocity, and magnetic field strength on three axes Measures the temperature, and internally temperature compensates all readings Low power usage great for battery-powered applications 16-bit precision with selectable sensitivity, adaptable to many project's needs Breadboard friendly SIP form-factor Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 1 of 11

Application Ideas Physics studies Stall, tilt, and collision sensing Free-fall detection UAV control systems Platform level/balance Compass navigation Gesture-based game controller Key Specifications 3 acceleration channels, 3 angular rate channels, 3 magnetic field channels ±2/±4/±8/±16 g linear acceleration full scale ±4/±8/±12/±16 gauss magnetic full scale ±245/±500/±2000 dps angular rate full scale 16-bit data output Up to 952 Hz refresh rate for accelerometer and gyro Up to 80 Hz refresh rate for magnetometer Programmable interrupt generators Embedded temperature sensor Voltage requirements: 2.6 to 6.5 VDC Current requirements: 5 ma Communication: 3-wire SPI, I2C Dimensions: 0.87 x 1.19 in (22 x 30.15 cm) Operating temperature range: -40 to +185 F (-40 to +85 C) Functional Description The LSM9DS1 is a system-in-package featuring a 3D digital linear acceleration sensor, a 3D digital angular rate sensor, and a 3D digital magnetic sensor. This module has a linear acceleration full scale of ±2g/±4g/±8/±16 g, a magnetic field full scale of ±4/±8/±12/±16 gauss and an angular rate of ±245/±500/±2000 dps. The LSM9DS1 includes an SPI serial standard interface. Magnetic, accelerometer and gyroscope sensing can be enabled or set in power-down mode separately for smart power management. The logic level shifters ensure that the I/O connections operate at the same voltage supplied to the VIN pin. This means the module is compatible with 2.8V, 3.3V, and 5V microcontrollers. Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 2 of 11

Reverse polarity protection will protect your IMU module in-case the connections to VIN and GND are accidentally reversed. The onboard 2.5V Low Dropout (LDO) regulator ensures the correct operating voltage for the LSM9DS1 IC and level shifters. Getting Started Propeller Microcontroller and BlocklyProp Resources If you are using the Propeller microcontroller and are new to using sensors of this type, the simplest way to get started is by using the BlocklyProp graphical programming language ( http://blockly.parallax.com ). It has a set of blocks dedicated to this LSM9DS1 9-axis IMU Module. The block reference is avilable from http://learn.parallax.com/ab-blocks/lsm9ds1. For C programming, the library lsm9ds1.h is included in the Propeller C Learn folder as of 1/18/2017. That folder is included in the SimpleIDE programming tool beginning with version 1.1. The latest versions of both are free downloads from www.parallax.com. General Instructions for Use with Microcontrollers Connect the LSM9DS1 9-axis motion sensor module to the same power (2.6 to 6.5 VDC) and ground supplies as the microcontroller, and connect either a 3-wire Serial Peripheral Bus (SPI) or Inter-IC Control Interface (I2C) as outlined in those sections below. If using the accelerometer, gyroscope, or temperature sensor with a 3-wire SPI bus, on power-up write a hexadecimal value of 0x0C to the CTRL_REG8 register, at a hexadecimal address of 0x22, to enable return communications on the three-wire bus. When reading or writing accelerometer, gyroscope, or temperature sensor registers, use the CS_A/G select line in the 3-wire SPI bus or the hex 0x6A 7-bit address on the I2C bus. If using the magnetometer with a 3-wire SPI bus, on power-up write a hexadecimal value of 0x07 to the CTRL_REG3_M register, at a hexadecimal address of 0x22, to enable return communications on the three-wire bus. When reading or writing accelerometer, gyroscope, or temperature sensor registers, use the CS_M select line in the 3-wire SPI bus or the hex 0x1C 7-bit address on the I2C bus. To enable the accelerometer, write the desired output data rate, scale, and bandwidth limit to the CTRL_REG6_XL register, at a hexadecimal address of 0x20, using the format given in section Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 3 of 11

7.24 of the LSM9DS1 datasheet. For example, a write a hex value of 0xD8 to set an output data rate of 952 Hz, with a scale of ±8 g, and a bandwidth of 408 Hz. The temperature sensor is enabled whenever the accelerometer is enabled. To enable the gyroscope, first enable the accelerometer, then write the desired output data rate, scale, and bandwidth limit to the CTRL_REG1_G register, at a hexadecimal address of 0x10, using the format given in section 7.12 of the LSM9DS1 datasheet. For example, a write a hex value of 0xDB to set an output data rate of 952 Hz, with a scale of ±2000 degrees per second, and a bandwidth cut-off of 100 Hz. To enable the magnetometer, set the power mode in the CTRL_REG3_M register, at a hexadecimal address of 0x22, using the format given in section 8.7 of the LSM9DS1 datasheet. For example, a write a hex value of 0x24 to use continuous conversion mode. To read from any of the sensors, once enabled, use the register listed in the the Register Functionality section below. Sensors Gyroscope The gyroscope output matches a polar coordinate system, with a positive output for counterclockwise rotation, and a negative output for a clockwise rotation, pivoting around the indicated axis. The output indicates a rate of rotation, in degrees per second. It is possible to accumulate the rotation over time, to calculate an angular position, but small inaccuracies in the rate readings will accumulate as well, causing the the angular position to drift. Reading the earth s gravity, using the accelerometer, and magnetic field, using the magnetometer, can provide additional data to detect, and compensate for, drift in the calculated angular position. When enabled, the gyroscope can operate at six different refresh rates: 14.9, 59.5, 119, 238, 476, or 952 Hz. The 16-bit signed output covers a selectable scale of ± 245, 500, or 2000 degrees per second. Accelerometer The accelerometer measures acceleration, as well gravity, in units of gravity (g). When no acceleration is applied, the accelerometer can measure the direction of the pull of gravity to determine the module s spacial orientation. Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 4 of 11

The accelerometer must be enabled when the gyroscope is enabled. When enabled, the accelerometer can operate at six different refresh rates: 14.9, 59.5, 119, 238, 476, or 952 Hz. The 16-bit signed output covers a selectable scale of ± 2, 4, 8, or 16 g. Magnetometer (Compass) The magnetometer measures magnetic fields, including the earth s magnetic field. When enabled, the magnetometer can operate at eight different refresh rates: 0.625, 1.25, 2.5, 5, 10, 20, 40, or 80 Hz. The 16-bit signed output covers a selectable scale of ± 4, 8, 12, or 16 gauss. Calibration Nearby metallic objects, including the header pins and other portions of the module itself, as well as any hardware the 9-axis IMU module is attached to, have a measurable effect on weak magnetic fields, such as the earth s magnetic field. The magnetometer stores an internal 16-bit offset for each axis, to compensate for the effects. After installing the 9-axis IMU module into a device, perform the following calibration procedure, to determine the offsets: Locate the device in an area clear from large metal objects. Continuously read the magnetometer outputs on all three axes, and store the most positive and most negative readings, for each axis. For a device that can rotate freely in 3D space, such as anything hand-held, or an aerobatic aircraft of any scale: At a slow consistent rate, preferably less than 15 degrees per second, rotate the device around all three axes, so that each axis includes a 360 rotation. A figure-eight pattern, similar to the pattern a marshal would use while waving a racing flag, meets the rotation requirements in a few wrist movements. Google s Calibrate your compass page includes an animation of an effective figure-8 pattern: https://support.google.com/maps/answer/6145351. For a device that rotates on a single plane, such as a vehicle : At a slow consistent rate, preferably less than 15 degrees per second, rotate the device at least 360, keeping it level on the intended plane. For each axis, average its highest and lowest readings, and negate the result, to determine the offset for that axis, and write the offset to the magnetometer offset register for that axis. The magnetometer offsets are non-volatile, so the calibration will stay valid indefinitely. When moving the module to a new device, perform the calibration procedure again. Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 5 of 11

Temperature Sensor If the gyroscope is enabled, the temperature output refreshes at 59.5 Hz, otherwise it refreshes at 50 Hz. The reading is in sixteenths of a degrees Celsius. Communication Protocols I/O voltages All I/O pins are open-collector outputs, pulled to VIN, through a 100 kilo-ohm resistor. All other pins have a maximum input voltage of 6.5 VDC, regardless of the voltage at VIN. The interrupt pins, INT_A/G and INT_M, are output-only and have no input functionality. Serial Peripheral Interface (SPI) The accelerometer, gyroscope, and temperature sensor share a three-wire SPI interface, initiating communications by driving CS_AG low, transmitting and receiving data on SDIO, clocking data on SCL, and ending communications by driving or letting CS_AG float high. The magnetometer shares the SPI data and clock pins, but uses the CS_M pin to start and end communications. The SPI bus operates in 3-wire mode, so on power-up the SIM bits in the CTRL_REG8 and CTRL_REG3_M registers must be set to 1, before reading data from the module. The INT_A/G and INT_M are optional interrupt outputs. The SPI bus can read and write data with a clock rate up to 10 MHz. For timing information, see sections 2.4.1, 5.2 and 5.3 of the LSM9DS1 datasheet. Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 6 of 11

Inter-IC Control Interface (I2C) The SDIO and SCL pins also support I2C communications. The pins have internal 100 kilo-ohm pull-up resistors, but external resistors may optionally be used for longer runs or higher speeds. The accelerometer, gyroscope, and temperature sensor have a 7-bit I2C slave address, in hexadecimal, of 0x6A, and the magnetometer has a7-bit I2C slave address, in hexadecimal, of 0x1C. The INT_A/G and INT_M are optional interrupt outputs. The I2C bus can read and write data with a clock rate up to 400 khz. For timing and command information, see sections 2.4.2 and 5.1 of the LSM9DS1 datasheet. Register Functionality All of the sensor outputs are 16-bit values, and all registers are eight bits wide, so each output includes a high and low register. The following registers are especially useful for basic usage of the 9-axis IMU module: Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 7 of 11

Accelerometer, Gyroscope, and Temperature Sensor Register Address (in hexadecimal) Function CTRL_REG1_G 10 Gyroscope operating mode OUT_TEMP_L 15 Low byte of temperature reading OUT_TEMP_H 16 High byte of temperature reading OUT_X_L_G 18 Low byte of X gyroscope axis OUT_X_H_G 19 High byte of X gyroscope axis OUT_Y_L_G 1A Low byte of Y gyroscope axis OUT_Y_H_G 1B High byte of Y gyroscope axis OUT_Z_L_G 1C Low byte of Z gyroscope axis OUT_Z_H_G 1D High byte of Z gyroscope axis CTRL_REG6_XL 20 Accelerometer operating mode CTRL_REG8 22 Configuration register including 3-wire SPI mode OUT_X_L_XL 28 Low byte of X accelerometer axis OUT_X_H_XL 29 High byte of X accelerometer axis OUT_Y_L_XL 2A Low byte of Y accelerometer axis OUT_Y_H_XL 2B High byte of Y accelerometer axis OUT_Z_L_XL 2C Low byte of Z accelerometer axis OUT_Z_H_XL 2D High byte of Z accelerometer axis Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 8 of 11

Magnetometer Register Address (in hexadecimal) Function OFFSET_X_REG_L_M 05 Low byte of X axis calibration offset OFFSET_X_REG_H_M 06 High byte of X axis calibration offset OFFSET_Y_REG_L_M 07 Low byte of Y axis calibration offset OFFSET_Y_REG_H_M 08 High byte of Y axis calibration offset OFFSET_Z_REG_L_M 09 Low byte of Z axis calibration offset OFFSET_Z_REG_H_M 0A High byte of Z axis calibration offset CTRL_REG3_M 22 Configuration register including 3-wire SPI mode OUT_X_L_M 28 Low byte of X axis OUT_X_H_M 29 High byte of X axis OUT_Y_L_M 2A Low byte of Y axis OUT_Y_H_M 2B High byte of Y axis OUT_Z_L_M 2C Low byte of Z axis OUT_Z_H_M 2D High byte of Z axis For a complete list of all registers and their functions, see sections 6 through 8 of the LSM9DS1 datasheet. First-In First-Out (FIFO) Buffer The accelerometer and gyroscope have a 32-entry first-in-first-out buffer to facilitate readings at regular intervals, when isochronous positional data is necessary. When using the buffer, the time between each reading is constant, which reduces error in accumulation calculations, for example when using the gyroscope to determine an angular position. Should the buffer overflow, it can either reject new data or overwrite old data, depending on the configuration stored to the FIFO_CTRL register. Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 9 of 11

Interrupts The 9-axis IMU module has two interrupt pins, one for the accelerometer, gyroscope, and temperature sensor, and another for the magnetometer. It can trigger an output signal from any of the following events: The FIFO buffer has reached a specific threshold and should be read Unbuffered data is ready to read The accelerometer data is above or below a set threshold on the specified axes The gyroscope data is above or below a set threshold on the specified axes The magnetometer data is above or below a set threshold on the specified axes The accelerometer interrupt is especially useful for detecting freefall, by selecting a threshold significantly lower than one g, then generating an interrupt when all three axes are below that threshold. The accelerometer, gyroscope, and magnetometer sensors each have a single interrupt threshold. Each axis on any of those sensors can trigger when either above or below the threshold. If an interrupt is set on multiple axes of the same sensor, the output can either trigger when a single selected axis is beyond the threshold, or when all selected axes are beyond their thresholds Interrupts output on either the INT1_A/G or INT2_A/G will drive the INT_A/G output on the 9-axis IMU module. Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 10 of 11

PCB Dimensions Pin Descriptions Pin Type Function VIN Power Connect to the same power supply as the SPI master device. The module is capable of operation on SPI busses running between 2.6V to 6.5V DC. GND Power Ground (0 V supply) SCL Open collector Clock for SPI (SPC) and I2C (SCL) SDIO Open collector Serial data input/output for SPI (SDIO) and I2C (SDA) CS_AG Open collector SPI mode selection for the accelerometer and gyroscope 1: SPI idle mode, I2C enabled 0: SPI communication mode, I2C disabled CS_M Open collector SPI mode selection for the magnetometer 1: SPI idle mode, I2C enabled 0: SPI communication mode, I2C disabled INT_A/G Open collector Accelerometer and gyroscope interrupt 1 & 2 INT_M Open collector Magnetic sensor interrupt Copyright Parallax Inc. LSM9DS1 9-axis IMU (#28065) v1.0 2/17/2017 Page 11 of 11