Jump to content
Terenceang

Stellaris LaunchPad IMU.

Recommended Posts

This is a project for me to learn programming on the Stellaris,  with tons of materials, support from TI, this and other forums, I managed to get a working port going for this project.

 

I ported part of the FreeIMU library to the Stellaris Launchpad, just enough to support the GY-80 that I have in my "gadget box".

 

GY-80 consist of 4 sensors, L3G4200D (Gryo), ADXL345 (Acc), HMC5883L (Mag) and BMP085 (Baro). This is a cheap sensor board that is readily available on ebay or your favourite Chinese online store.

 

What is working?

 

Reading and writing to the sensors by i2c bus (thanks to the code from "aBUGSworstnightmare").

calibration routine works but it is not saved to EEPROM.

Basically it display the Roll, Pitch, Yaw, compass heading and all sensor's Raw data thru the Uart Console (I am using BT on UART1, change it to UART0 for ICDI port.)

 

Overall it is still buggy and I still cannot reset the Roll setting.

 

Todo. 

1. save calibration data to EEPROM.

2. host software for graphical representation of data.

3. fix bugs.

 

As I am a RC fan, it will be thrilling to see the Stellaris on a Quadcopter, if this goes well, I will go on develop it further, with newer gens of sensors.

I dont know if I can pull it off or not, hopefully someone else can either help or work on it. 

 

The project is up on google code, anyone interested to work on it, please let me know. 

https://code.google.com/p/stellaris-lp-imu/

 

post-551-14264605240444_thumb.jpg

post-551-14264605239168_thumb.png

Share this post


Link to post
Share on other sites

Thanks, I am ok for now, I know there are some guys here working on IMUs as well. hopefully this can be a good community project.

 

I managed to get the calibration routines done but somehow the roll axis is still not right. Saving to EEPROM is working now so I dont have to hard code the calibration.

On a side note, I just built a Hobby king mirco hexa.. this thing flies awesomely with the KK board, simply plug in and it flies ... haha.. 

 

The stellaris Launchpad is a wonderful powerful little board, learn so much about it the pass few days..

 

Lovely! Keep working on this and keep us updated. If you need additional board support in terms of hardware, I'll see if I can sponsor you.

Pics of your setup would be awesome!

Share this post


Link to post
Share on other sites

I like your BMP085 code. Originally, I only used it for collecting barometric pressure. I'm a bit of RC heli and quad junkie so I've been following along with all the different IMU projects. Right now, my primaries are all down for repairs; heli is thrashed from high speed maneuvers under low ceilings, the quad is awaiting 2 replacement ESCs as they got a little smokey for some reason.

Share this post


Link to post
Share on other sites

Actually all the codes are bits and pieces from all over the place, I am quite lost with the maths, and I am still learning, credits goes to LPC Port of the FreeIMU libraries.

 

I have 3 quads, 1 F450, 1 x HK Mirco Hexa and, 1 x HK Mirco Quad. I have APM with GPS and Sonar on the F450, flew well for a while (flying robot) but decide to do teh flip of death out of no reason, I suspect it is an ESC problem but I cannot duplicate the problem in a controlled manner. ESC are all SimonK flashed so no cut off etc. It is grounded since then we have bad weather since dec, and it rained when ever I charge my batts. Hence the smaller hexa and quads, I am putting a mutiwii with GPS on the Hexa, let's see how it flies.

 

I like your BMP085 code. Originally, I only used it for collecting barometric pressure. I'm a bit of RC heli and quad junkie so I've been following along with all the different IMU projects. Right now, my primaries are all down for repairs; heli is thrashed from high speed maneuvers under low ceilings, the quad is awaiting 2 replacement ESCs as they got a little smokey for some reason.

Share this post


Link to post
Share on other sites

Hi pentiumpc,

 

Just few days ago I started the developement of a bluetooth inertial sensor board, to capture body movements.

 

I need to acquire 3D accelerometer and gyroscope data for the very first prototype, but magnetometer should be very useful in the future, so your example will be very useful for me.

 

for the prototype I will use:

- stellaris launchpad

- GY-80 sensors board

- HC06 bluetooth module (to send data to a PC)

 

I look for your code in the google-site link you posted before, but I can't find it...

 

thanks in advance

 

Dario

Share this post


Link to post
Share on other sites

No Bugs, looking at the code you just need to send "Roll, Pitch and Yaw" Data thru the com port, in "R","P","Y"! sequence with delimiters. I just need to quickly visualise the sensor's data.

 

The GUI is Part of the MSP430 AHRS Application Note.

@PentuimPC: Did you port the AHRS sensor Fusion algorithm from the App Note too?

aBUGSworstnightmare

Share this post


Link to post
Share on other sites

That is my exact set up, just change the code from UART0 to UART1 if you use this LP booster, I have it mounted on the bottom of the Stellaris.

you got to check the truck for the source. https://code.google.com/p/stellaris-lp-imu/source/browse/#svn%2Ftrunk%2Fstellaris-lp-imu

Hi pentiumpc,

 

Just few days ago I started the developement of a bluetooth inertial sensor board, to capture body movements.

 

I need to acquire 3D accelerometer and gyroscope data for the very first prototype, but magnetometer should be very useful in the future, so your example will be very useful for me.

 

for the prototype I will use:

- stellaris launchpad

- GY-80 sensors board

- HC06 bluetooth module (to send data to a PC)

 

I look for your code in the google-site link you posted before, but I can't find it...

 

thanks in advance

 

Dario

Share this post


Link to post
Share on other sites

That is my exact set up, just change the code from UART0 to UART1 if you use this LP booster, I have it mounted on the bottom of the Stellaris.

 

where can I find that code?

Share this post


Link to post
Share on other sites

I am making changes to regulate the timing for the AHRS updates.. All this is pretty new to me, I am getting good Yaw and Pitch reading but roll is way off, It goes 1 way and won't return to level after awhile, seem to accumulate some error over time.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×