Terenceang 0 Posted March 8, 2013 Share Posted March 8, 2013 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/ chicken, gwdeveloper and Fred 3 Quote Link to post Share on other sites
bluehash 1,581 Posted March 9, 2013 Share Posted March 9, 2013 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! Quote Link to post Share on other sites
Terenceang 0 Posted March 9, 2013 Author Share Posted March 9, 2013 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! Quote Link to post Share on other sites
gwdeveloper 275 Posted March 9, 2013 Share Posted March 9, 2013 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. Quote Link to post Share on other sites
Terenceang 0 Posted March 9, 2013 Author Share Posted March 9, 2013 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. Quote Link to post Share on other sites
Terenceang 0 Posted March 9, 2013 Author Share Posted March 9, 2013 First test.. at 5:52am.. got get some Zzzz.. Church and lessons to cover till 3pm.. arghh! bluehash 1 Quote Link to post Share on other sites
bluehash 1,581 Posted March 10, 2013 Share Posted March 10, 2013 Perfect! Did you design the UI? Quote Link to post Share on other sites
Darmurg 0 Posted March 10, 2013 Share Posted March 10, 2013 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 Quote Link to post Share on other sites
aBUGSworstnightmare 1 Posted March 10, 2013 Share Posted March 10, 2013 Perfect! Did you design the UI? 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 bluehash 1 Quote Link to post Share on other sites
Terenceang 0 Posted March 10, 2013 Author Share Posted March 10, 2013 No, the UI is from Ti, from fro MPU-9150 and MSP430..haha.. http://www.ti.com/lit/an/slaa518a/slaa518a.pdf Perfect! Did you design the UI? Quote Link to post Share on other sites
Terenceang 0 Posted March 10, 2013 Author Share Posted March 10, 2013 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 Quote Link to post Share on other sites
Terenceang 0 Posted March 10, 2013 Author Share Posted March 10, 2013 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 Quote Link to post Share on other sites
Darmurg 0 Posted March 10, 2013 Share Posted March 10, 2013 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? Quote Link to post Share on other sites
Terenceang 0 Posted March 10, 2013 Author Share Posted March 10, 2013 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. Quote Link to post Share on other sites
Terenceang 0 Posted March 10, 2013 Author Share Posted March 10, 2013 where can I find that code? https://code.google.com/p/stellaris-lp-imu/source/browse/#svn%2Ftrunk%2Fstellaris-lp-imu the code is for UART1. not updated to use the UI. Please update us with you mocap experiment, thanks. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.