# Self-Stabilizing Platform

Hello Everyone,

Thanks to Arduino Duemilanove, I was able to finish my senior project. The portion of the senior project that I was in charge of, was the self-stabilizing platform. I could do a lot of improvements on this platform, but I decided to do a rough approach and have something working which I could later modify.

I used Pololu’s Freescale MMA7260QT XYZ-axis accelerometer as my tilt sensor (later on, I realized I didn’t need the Z-axis, and could of used an XY-axis accelerometer instead). I attached this accelerometer to my platform.

The accelerometer’s outputs are analog signals, when reading them on the arduino, the arduino automatically converts it to digital (0-1023). I made sure I used External referencing and connected the accelerometer’s 3.3V into the arduinos AREF. Since I wanted to see the actual voltage readings instead of the digital, I multiplied each reading by 0.0032(3.3V/1024).

To calibrate each output of the accelerometer (when it’s horizontally flat which corresponds with 90 degrees), I created a function that would sample the accelerometer’s xy-outputs 100 times to find the average and used this average as my reference.

Now that my accelerometer was calibrated, I subtracted the new readings from the reference to get the difference. I multiplied this difference by (Reference/90) to get the tilt angle in degrees.

The reason I converted the digital readings back to voltage readings and into degrees was because I was outputting these values into an lcd screen to verify that I was getting accurate results.

Using the tilt angle readings, I determined the position of the accelerometer which would correspond to the position of the platform. The eight possible positions that I needed to take in consideration were (+X/+Y), (+X/-Y), (+X-axis), (-X/+Y), (-X/-Y), (-X-axis), (+Y-axis), (-Y-axis).

I controlled four 12Vdc motors individually using two SN754410 H-bridge chips from Sparkfun. The motors were placed on each corner. I connected a rod to a right angle ball-joint which was attached to an arm connected to the motor’s shaft. The rods connected to the platform through an inline swivel which gave it +/- 30 degrees motion. Due to the swivels my platform was limited by +/- 30 degrees of motion.

Depending on the position of the platform detected, I activated the corresponding motors to bring back the platform to it’s reference level +/- 2 degrees.

So there you go, brief description of how I did it, was really fun to implement thanks to Arduino’s simplicity.

A video of my platform with the rest of the project can be seen here:

http://www.youtube.com/watch?v=0sxmonpzFDI

The platform is interesting; your next project should be building an outdoor off-road vehicle, then mounting a camera to the self-stabilizing platform (it seemed kinds pointless to me to add a self-stabilizing platform to a device running on what appeared to be a flat floor)...

Hi there cr0sh,

ya hehe, the video was just us recording to see if it even maintained stabilized in flat floor. The rover is meant for bumpy terrain.

I have friends who did that stabilizing camera for their senior project, that was amazing as well, they used a gyro as well.

Awsome. Wonder why the auto makers don't have this active system replacing shocks, which are passive. Maybe expensive cars have active stabilization.

re: the video: That music! What in the name of all that is Holy are you trying to do to us?

Very neat. However I would have used large hi-torque R/C type servos for the four final control element rather then four H-drive motors.

Lefty

Haha did you make out with that robotic platform after filming the video because the choice of background music really makes me wonder. ;)

Good project though.

lol ya, sorry about the music, I had nothing to do with it =/. The video was taken and editted by one of my senior project partners. Just wanted to share the video of it.

I'll try to take my own video without music and actually going in rough terrain and post it.

@ retrolefty: I initially was going to use hi-torque R/C servos, but I calculated to be cheaper using the h-bridges and dc motors.

Since I was able to make a crude self-stabilizing platform, I eventually want to make something like this:

http://www.aviationweek.com/aw/blogs/defense/index.jsp?plckController=Blog&plckScript=blogscript&plckElementId=blogDest&plckBlogPage=BlogViewPost&plckPostId=Blog%3A27ec4a53-dcc8-42d0-bd3a-01329aef79a7Post%3Ab7e83518-b221-4733-ba1c-16d21825fe2a

Awsome. Wonder why the auto makers don't have this active system replacing shocks, which are passive. Maybe expensive cars have active stabilization.

Some models of expensive cars do have active stabilization; I remember that back in the 1980s Lotus had a model that included such a system.

Personally, while I see the benefits of such a sytem for certain vehicles, I hope it remains an "optional accessory", even if it does become available to lower-end cars. Why?

Because such a thing will likely break down, and often - more often than standard shocks, which you have to replace fairly regularly anyhow. It likely won't be a cheap repair, and it likely won't be something you can do at home with parts from AutoZone, either. It would likely have to go to the shop, or the dealer, and it will use dealer parts and be hella expensive. No thank you.

I don't even like power windows or locks. Sure, they're convenient - until they break. Then you are stuck either crawling thru the window "Dukes of Hazzard" style (unless both go at the same time, then you're hosed).

Honestly I hate what they have done with "modern vehicles"; half the time you can't even get your hand or wrench into certain places - sometimes you damn near have to remove the engine just to change a spark plug! On the old vehicles, it wasn't like that - I can almost crawl into the engine compartment and go to sleep under the hood of my 79 Bronco. My brother-in-law has an old 50's Chevy pick-up that seems clean and roomy to work on; hardly any wires (unlike today's going-every-which-way wiring harnesses that feel nearly undocumented and mysterious as to their operation), plenty of room to get a wrench on.

Well, enough ranting, I suppose. Time and technology marches on, and steals the money from your pocket, I guess. I am hoping that future electric and hybrid technology for cars will make things simpler to work on, but I have my doubts.

:P

thats good. i also have my own arduino for my research project :D