Online data sets for inertial and magnetic sensors (part 1)

By Mike Stanley

Originally posted on Freescale’s The Embedded Beat Blog

When I first joined Freescale’s Sensors team, I did what I usually do when I start working in an area of technology that’s new to me: ask lots of questions, do lots of reading and tinker with the technology. I got a lot of use out of my DEMOQE128 development board, which included an MMA7260Qaccelerometer on the PCB. There’s nothing like looking at the raw data, running it through an algorithm and viewing the results to cement an understanding of the technology.

Later, I gathered an appreciation for the need to be able to reproduce my results from one run to the next.  I needed to be able to clearly differentiate the effects of a subtle software change versus simple random input variation of one experiment to the next.  I started caching experimentally captured data sets onto my hard drive.   I invested in a 3rd party inertial measurement unit and the data sets started piling up.   Eventually, I developed a standard set of Matlab scripts and consistent ways to view my data.   I showed my data set to my immediate manager, and his reaction was “we should share this.”

Today, we are doing just that:  “Sample Data Sets for Inertial and Magnetic Sensors” is now available on Freescale’s web site. The company is releasing raw data files, Matlab scripts, and full report under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.  You can download the entire package as a zip file here.

Sample Data Sets for Inertial and Magnetic Sensors – View 1

I’ll be using various data sets from this collection in future blog discussions.  Today, I would simply like to walk you through the organization of the data.  I’ve annotated a screen dump of the collection web page in the “View 1″ graphic above. Items labeled in the figure include:

  1. Data sets are groupled into one of five categories:
    • Actions – example: picking up an object
    • Environment – examples: freefall, orientation
    • Events – example: laptop falling from desk
    • Gestures – examples: tap, double tap
    • Locomotion – example: pedometry
  2. Click on any of the five tabs to see the specific data sets in that category.
  3. Each summary includes a link to the source data.  The data is in the form of a human readable, Matlab readable, text file.  The format of the file is documented via the “Data File Format” link (5).  Measurements were taken at 125 samples/second, where a “sample” is defined as 1 value for each of the IMU sensors.  That is: 1 sample = X,Y & Z for each of acceleration, magnetic and angular velocity plus 2 boolean values corresponding to the state of two push buttons on the IMU.
  4. The “Inertial Measurement Unit Used for Study”  link describes the 3rd party IMU used for this study.  The page documents units/LSB for each sensor.  Allan Variance charts are presented for each of acceleration, angular velocity and magnetic sensors.
  5. Each raw data fle is in a format that can be read using Matlab’s “load” command.  The custom data logger program used to collect data also calculates some basic statistics on the data set.  Statistics are included at the bottom of each file.
  6. Matlab scripts used to generate various report figures are included.  You should be able to use these as templates to read and process data files any way you like.
  7. We are making the entire data set available under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.  This link provides details of the usage agreement and a pointer for you to download the full data set in .zip file format.

Sample Data Sets for Inertial and Magnetic Sensors – View 2

View 2 above illustrates a few more features present in reports:

  1. We’ve calculated minimum, maximum and range (= maximum – minimum) for X, Y & Z orientations for acceleration, angular velocity and magnetic sensors.
  2. Some brief notes are included that describe what was being measured.
  3. Some of the data sets will include one or more illustrations to further elaborate on the measurements.  In the example above, the IMU was lying stationary in the back seat of my car while my wife and I ran some errands.  The figure gives an indication of the route we traveled.

Sample Data Sets for Inertial and Magnetic Sensors – View 3

And finally, we get to the data plots:

  1. Acceleration versus time
  2. Power spectral density plot of acceleration readings
  3. Magnetic sensor readings versus time
  4. Power spectral density plot of magnetic sensor readings
  5. (not shown) Angular velocity versus time
  6. (not shown) Power spectral density plot of angular velocity readings

Future postings will explore the various data sets in this collection. A lot of people know what accelerometers, gyros and/or magnetometers are in theory. But many of you haven’t had the chance to actually see what the sensor output signals look like.   So let’s address that!  Please use and share the information you find here.  Play with the data, apply your own filters, and let your imagination run wild with ideas for new applications.

Original post:

Leave a Reply

Your email address will not be published. Required fields are marked *