itg3200

A picture of FreeIMU v0.3.5_MS

Submitted by fabio on Mon, 2011-07-11 09:24.

This is one of the very first FreeIMU v0.3.5_MS I assembled during the past weekend. This is probably one of my best soldering work and PCB design.

FreeIMU v0.3.5_MS

Connecting Sparkfun ITG3200 breakout board to Arduino

Last updated on Thu, 2011-07-07 14:22. Originally submitted by fabio on 2011-06-22 13:07.

I've been asked how to connect a Sparkfun breakout board for the ITG3200 to an Arduino UNO. Here's a schematics of the connection. If you are using an Arduino Mega you'll have to use pins 20 (SDA) and 21 (SCL) instead of A4 and A5.

IMPORTANT: Remember that in order to use this setup you have to disable the internal pullups of the ATMEGA. Note that Wire will enable them by default.

Breakout boards for sale

Last updated on Mon, 2011-06-20 11:09. Originally submitted by fabio on 2011-06-05 11:11.

I'm cleaning my workshop and I do have some breakout boards which I'm not going to use so I'd like to sell them if someone is interested. All of them are new and tested.

Here is what I have:

  • 6 5 4 3 2 1 breakout boards for ITG3200 25 euro SOLD OUT! Thanks!
  • 6 5 4 3 2 breakout boards for ADXL345 20 euro
  • 2 1 breakout boards for HMC5843 25 euro SOLD OUT! Thanks!
  • 1 breakout board for HMC5843 by Sparkfun (used a couple of times with male headers soldered) 25 euro SOLD OUT! Thanks!

Prices includes shipping to EU. If interested please contact me.
Thanks!

p.s. I'll keep this post updated with availability.

Various breakout boards for sale

Preview of FreeIMU v0.3

Submitted by fabio on Fri, 2011-04-01 18:01.

Ok, I'm back hacking after a couple of months of hard work on the thesis which has been completed and submitted to the committee. 7 or 8 April degree! I still have to realize all of this..

Well, after a couple of days of relax I'm back to my regular hacking and I've been able to assemble the very first FreeIMU v0.3.

FreeIMU is my libre inertial measurement unit which I developed during my thesis. For all the informations please visit FreeIMU project page.

FreeIMU v0.3 is the latest version of FreeIMU which includes the ADXL346, the HMC5883L and the ITG3200. Initial test have been successful but I'm testing it.

So, here you have a couple of pictures:

FreeIMU v0.3 top view

FreeIMU v0.3 bottom view

I also made a quick video of FreeIMU v0.3

In this revision, I made some changes in the components used for the voltage level translation. It seems that the results are great. This is the signal quality of the SCL line running at 400KHz through the integrated logic level converter of FreeIMU v0.3.

FreeIMU v0.3 scope

FreeIMU is alive!

Submitted by fabio on Wed, 2011-01-26 19:18.

Yeah! I soldered everything and all went smooth.. only a little bug.. the connectors have a 0.032" drill hole while it should be 0.04".. so, regular squared pins array wont fit inside. You can use rounded pins, female thin pins (as the one shown in the video below) or wires directly.

But everything works great. Communication on I2C running at 400Khz directly from Arduino through the on board I2C level converter.. works great!

Next days more tests, I'm expecially interested in having a look at how the I2C signals looks on a scope with or without the I2C level converter.. I'll also try to simulate some noise and using long wires to check what happens..

Here is a short video on the progresses done these days.

FreeIMU: designing a free (as in speech) 9 DOM/DOF MARG IMU

Last updated on Wed, 2011-05-25 08:38. Originally submitted by fabio on 2010-12-09 10:53.

UPDATE 2011-02-10: Check out FreeIMU project page for all the informations about FreeIMU!

In the past months I worked a lot on accelerometers, gyroscopes and digital compasses. I'm now pretty intimate with the ADXL345, the ITG3200 and the HMC5843.

I've been able to design and construct homebrew DIY breakout board PCBs for all of them (ADXL345 and ITG3200) and to create a nice library to use them which also implement a great sensor fusion algorithm capable of running on the Arduino without problems.

I'm now making the next step. Let me introduce FreeIMU.

FreeIMU.png

FreeIMU is a 9 DOM/DOF MARG IMU based on the ADXL345, the ITG3200 and the HMC5843. As this is part of my Master of Science Project and that I completely share the openness of projects like Arduino, FreeIMU will be completely open: all the designs will be released under a Creative Commons Attribution-ShareAlike 3.0 Unported while all the software will be release under GNU GPL v3.

As my background is in computer science, I'm quite self-taught in PCB designs and in electronics in general. So, I'm now seeking review for FreeIMU's schematics and PCB designs. If you have experience working with IMUs, designing PCBs or circuits and you would like to contribute to a free project please have a look at the designs and feel free to comment it.

I'm using kicad as schematics and PCB editing software. It's free (as in speech) software and, once you get around its glitches, it works really well. Using non-libre software like EAGLE to design a free hardware like FreeIMU would have been simply senseless.
Note: I'm using a nightly updated version of Kicad, so if you have problems opening the files you might need to update your version of Kicad.

So, you'll find the current Kicad based sources of FreeIMU in the attachments to this page just below. You'll also need a library of components which I also attach here. For your convenience I attach also a pdf version of the schematics.

I plan to submit FreeIMU to DorkbotPDX PCB Order of the 13th December to have it constructed. I currently don't see this as a commercial project but if someone is interested in FreeIMU I could sell a couple of boards.

Ok, so.. looking forward to hear your comments. Thanks!

UPDATE 2010-12-13:

FreeIMU designs have been sent for fabrications. Looking forward to receive the PCBs soon! I have received some interesting advices on the board design so the design sent to production has been slightly modified: there's now space for an optional 10uF tantalum capacitor in package A and there's more clearance for the mounting holes. The original design would have been making almost impossible screw FreeIMU as there were some capacitor just near the mounting holes.

You find the final PCB design in the attachments below. I also attach below the Gerber and drill files sent for production.

I'd like to thanks everyone who helped in reviewing and advising on FreeIMU. I'd like to thank especially Greg Peek from dorkbotpdf-bladder mailing list who convinced me on adding the 10uF cap and adding more clearance on the mounting holes. I'd like also to thank James Neal for suggesting the addition of the mounting holes in the first place and for taking care of organizing the PCB group order.

UPDATE 2010-12-22:

The FreeIMU project is progressing nicely.

Yesterday Laen received FreeIMU's PCBs and they shuold have been
shipped to me today.

I've also been able to find cheap stencils from
http://www.smtstencil.co.uk/ .. They should have shipped the stencils
yesterday.

Meanwhile I ordered all the components to produce 10 copies of FreeIMU.

The code is now quite stable and I'm using it on my tangible user
interface prototype (basically it's a sphere capable of detecting
taps, double taps and its orientation - more on this on my blog soon).

I should be able to produce the first boards around the first week of
January.. I'm really looking forward to it!

UPDATE 2011-01-02:

The interest this project is getting is huge! Thanks to everybody who contacted me about FreeIMU and to the people who already reserved FreeIMU units.

For those who are interested in buying one or more FreeIMU units here are the prices:

  • Fully assembled FreeIMU v0.1: 80 euro 70 euro with international shipping and pre-soldered female or male headers (at your choice) included. For multiple orders I can offer a discount, just get in touch with me.
  • FreeIMU v0.1 raw PCB: 15 euro with international shipping included and non-soldered female or male headers. Note: You will have to buy the ICs sensors by yourself and be able to reflow solder them.

If you want to buy one or more units please get in touch with me and I'll reserve your units for you. The number of available units is limited and a strict first came first served policy will be followed so reserve your units as soon as you can to be sure to get one.

UPDATE 2011-01-14:

Still no signs of FreeIMU's PCBs. It looks like Lean will need a better shipping option for us in Europe. More than 3 weeks already passed from the shipping of the PCBs from the USA to Italy and still no signs of them. Of course, we had the holidays in the middle, but that's way too much!

UPDATE 2011-01-18:

Just created a FreeIMU project page on Launchpad. Using launchpad for FreeIMU development will give us some great advantages like: an high quality repository with bazaar, code and designs browsing, questions and answers, bug and features suggestions.. Moving the project to a public place was a step to be made.

So, from now on, you can download FreeIMU designs from it's repository using:

bzr co lp:freeimu

UPDATE 2011-01-20:

Still no signs of FreeIMU v0.1 .. fuc**in Italian customs. Anyway, FreeIMU version 0.2 has been sent for fabrication and today it has been shipped to me. This time of course using FedEX which shouldn't be so slow as regular mail. Let's hope so..

Following some picture of FreeIMU v0.2:
FreeIMU v0.2 top view

FreeIMU v0.2 bottom view

UPDATE 2011-01-26:

FreeIMU is alive! First units of FreeIMU have been produced and I'm currently testing everything. Stay tuned!

Initial implementation of a 9 DOM/DOF MARG IMU orientation filter with ADXL345, ITG3200 and HMC5843 on Arduino

Last updated on Tue, 2011-05-10 13:49. Originally submitted by fabio on 2010-12-04 16:15.

UPDATE 2011-05-10: The 9 DOM sensor fusion library presented in this article is now part of the FreeIMU library. Please consider the code in this page as outdated and just use the FreeIMU library.

I spent the last days creating an initial implementation of a 9 Degrees of Measurement (DOM) / Degrees of Freedom (DOF) AHRS sensor fusion orientation filter. I've created a library, called FreeIMU, which polls data from the ADXL345 accelerometer, the ITG3200 gyroscope and the HMC5843. Have a look at the attachments for my circuit schematics.

To access the ADXL345 accelerometer I used this nice Arduino library (based on this other one), while for the ITG3200 I used Filipe Vieira's ITG3200 Arduino library. To access the HMC5843 I used my library.

The sensor values are then pushed into Sebastian Madgwick's implementation of Mayhony's DCM filter incorporating Sebastian's magnetic distortion compensation (Algorithm available here - project here).

IMPORTANT: This code doesn't disable the ATMEGA internal pullups so a logic level converter/translator is needed if you don't want to fry your sensors. In the video I used a modified version of twi.c (inside of the Wire library) commenting out the pullup enabling in twi_init().

The result can be seen in the video below. Note that all the code published here is still very very young. You'll probably find lots of bugs and WTF but I think it can still be useful. Keep an eye on this website for the next developments. If you are working on this stuff get in touch with me if you want to share efforts.

My first 6 DOF IMU Sensors Fusion Implementation: ADXL345, ITG3200, Arduino and Processing

Last updated on Mon, 2012-07-23 09:09. Originally submitted by fabio on 2010-11-22 21:36.

When you have created two breakout boards for the ADXL345 accelerometer and the ITG3200 gyroscope and you have those two nice sensors what you can do? Simple: create an implementation of an Attitude sensor fusion which runs with those chips!

So, I started documenting myself and reading lot of stuff on IMUs (inertial measurement units - composed by an accelerometer and a gyroscope) and MARG sensor (an IMU which also has a magnetometer to sense heading).

One really good article you should read to get started with IMUs is A Guide To using IMU (Accelerometer and Gyroscope Devices) in Embedded Applications available on http://www.starlino.com/ . Also from the same website there is a nice implementation of the theory from the IMU guide: you can find it on Arduino code for simplified Kalman filter. Using a 5DOF IMU.

So, I took the algorithm above and converted it to be used with the ADXL345 and the ITG3200. I came out with two implementations both with parts in Arduino and Processing code (see the attachments to this page below).

IMPORTANT: If you use the IMU Digital Combo Board from Sparkfun you will need to change the address of the Gyroscope from 0x69 in my code to 0x68.

The first implementation simply reads the raw accelerometer and gyroscope values on the Arduino while the Processing code (running on the PC) will compute the sensor fusion algorithm, produce the orientation vector and siplay a nicely oriented cube.

In other implementation all the sensor fusion logic is implemented in Arduino code so it will run embedded in the microcontroller. Looks like Arduino can coupe with that without any problems! So, once the orientation is computed is all sent to the PC where the Processing application will display incoming data and the oriented cube.

You can see a demonstration in the following video:

All the code is available in the attachments below. You can see the circuit in the picture below. Note that these are custom made breakout boards, your pin configurations will vary depending on the schematics of your breakout board. If you have questions just leave a comment below.

The processing programs need to be executed on the Processing IDE, available for download from http://processing.org/
Remember to adjust the serial port configuration in the Processing code to match your connection to the Arduino in your system. Here I use /dev/ttyUSB9, if you are under windows you'll probably have to use something like COM3 or something like that. See in the Arduino IDE under Tools->Serial Port to get the exact value you have to use.

IMU6DOF_Arduino_connections.jpg

An homebrew DIY breakout board for the ITG3200 gyroscope: tested with Arduino and Processing

Last updated on Tue, 2012-01-31 12:57. Originally submitted by fabio on 2010-11-08 16:21.

Some days ago I posted about my first homebrew DIY breakout board for the ADXL345 accelerometer. That was pretty ugly but worked very good.

Today, after some other tests, I show you my new homebrew DIY breakout board: this time it is for an ITG3200 gyroscope. And you'll see that I really improved a lot!