Initial tests with FreeIMU v0.4 and MPU6050
I've been playing with FreeIMU v0.4 and its MPU6050 for some initial testing. I used the code that Noah Zerkin shared on a previous post (thanks Noah!) which supports 6DOM accelerometer+gyroscope on chip DMP sensor fusion and changed it slightly to output quaternion data as expected by the FreeIMU_cube Processing sketch in the FreeIMU library. Programs used for this tests are attached at the end of this page.
The result (see video below) has been very successful. 6DOM sensor fusion looks pretty good. It remains to be tested the 9DOM sensor fusion and it's integration with the HMC5883L: I suspect this will be quite an headache.. I'll let you know.
Scoping SDA and SCL I2C signals showed pretty solid signals. I've been also testing the MS5611 barometer on FreeIMU without any issue (not on video).
| Attachment | Size |
|---|---|
| MPU6050_test.zip | 13.62 KB |
| FreeIMU_cube.zip | 40.77 KB |



concerning the processing again :)
Hi Fabio,
Yesterday, I wrote a comment on another blog of and thanks for your quick reply but unfortunately it wasn't what I exactly needed. I saw this blog of you this morning and this is exactly what I need to do. I wrote a code on Arduino. I could get pitch and roll angles and it seems to work perfectly. Now I want to simulate the motion of gyroscope and acc on processing. I downloaded processing and your free IMU cube code and tried it, it drew a cube with the angles written on the upper left but of course everything is still. Now all I need is how to use the code I made on Arduino in processing to get this cube moving with the movement of gyroscope and acc together. I know this seems to be a very silly question but forgive me this is the first time to deal with these things and it has been three days of trying and each time ends with a fail.
It's only a matter of sending
It's only a matter of sending the right data to the processing application.. you can study the code from the page, especially the serial communication stuff: what get transferred from arduino to processing via serial.
In this code, a quaternion encoded as hexadecimal numbers is transferred.. this is not the easier code to understand.. you'd better have a look at the source code in this previous blog post.
Good luck!
accelerometer/gyro raw data
Thanks for all the useful tips and code!!
I've been trying to figure out how to append raw accelerometer and gyro data on to the quaternion using the modified bzerk code you have. If you can see how this is done quickly, I'd greatly appreciate if you let me know how!!
cheers,
Krishna
IMU_cube
Nice project the FreeIMU.
I am new to this topic. I want to know a way to get the .pde code into executable code with MPU6050.pde and FreeIMU_cube.pde ?
thanks
YK
That looks great. Is mpu6050
That looks great.
Is mpu6050 give DMP fusion data with i2c magnetometer ? Or you calculate with your algorithm to fusion magnetometer data ?
did you try AK8975 Magnetometer ?
Is mpu6050's i2c buss address could change ?
At the moment, there is no
At the moment, there is no code/documentation from Invensense for using the 9DOM sensor fusion with MPU6050 and 3rd party magnetometers. So, AFAIK, is currently not possible to implement that.
No, I never tried the AK8975 magnetometer. I dug a bit into it and seemed a somehow undocumented chip.. probably only for huge numbers EOM developer/distributors.
Yes, the address of the MPU6050 on the I2C bus can be changed by grounding or tying to VCC. The upcoming FreeIMU v0.4 has a solder jumper on the bottom of the board which allows you to set its address. See MPU6050 datasheet for all the details.
Excellent
If mag is headache then why not just allow i2c access without connection to imu6050? this would be a useful option if possible and save you having to implement slave and master i2c.
You will know better than me but I am not sure how useful the fusion data will be for some applications. I heard that it is designed for hand held motion processing.
Maybe some solder jumpers for enable/disable mag>6050
But I will buy anyway whatever you do, thanks for the hardwork :)
By default, the MPU6050
By default, the MPU6050 starts in pass-through mode meaning that the master and aux I2C buses are directly connected. So, with FreeIMU v0.4 direct access to the magnetometer is possible and works by default: if you start you arduino with an HMC5883L code charged it will simply work on FreeIMU v0.4 without any additional steps.
Thanks
That sounds great!!
It looks very stable. Have
It looks very stable.
Have you tried to implement in MPU6050 the 6DOM MARG fusion Filter last used in ITG3200 in place of the DMP?
( To easy play with initialization parameters of MPU6050 and compare result with the DMP )
Moreover MARG algorythm is less memory than DMP ...
If so, can you provide an example ?
Congratulations.
I still did't compared the
I still did't compared the two algorithms.. but this looks quite difficult to do as the documentation on the DMP is still few. We would need access to accurate docs on it to implement it throughly for a test.
I'll surely post on the website as soon as I'm able to compare the two.
V0.4 availability
I am very excited about version 4 and I agree it has been a long time for Invensense to deliver this product. I am glad to hear testing is moving forward and wondered when the board will be available for purchase and what the estimated cost would be for the complete board.
Thanks,
Mike
I'm working with Jussi from
I'm working with Jussi from http://viacopter.eu/ on a factory assembled run of FreeIMU v0.4. Right now I'm still testing the prototypes and we are gathering informations on availability and quotes on the various components. At the moment we still aren't able to give you a price for the upcoming v0.4 units.
Post new comment