Monday, November 7, 2011

MultiWii Camera Test

So, I've been wanting to try out the camera stabilzation features on the MultiWii controller, and prompted by an interesting camera stabilization link from my friend Craig I went ahead and put a quick prototype together.  I had been waiting to put together something like this nice gimbal;  I'll get to that soon, but in the mean time here's what I did with hot glue and spare parts sitting around.  There will be lots of jitter with this design, but we'll see if the roll and pitch adjustments are close.
I started by configuring the MultiWii software (notes below) and enabling stabilization in MultiWiiConf.  To hold the camera, I noticed that the Radical RC quad motor mount was the perfect size to hold a GoPro.  By using a clamp while CA'ing the joints (careful not to drip!) I was able to get enough of an angle so that the camera fit snugly enough so that for testing I didn't have to use any other mechanism to hold the camera.
I used two 9 gram servos to make a two-axis gimbal.  Note that this isn't the final plan, but for quick prototyping it's hard to beat, taking about 15 minutes to assemble everything after 30 minutes of fiddling with various parts trying to figure out what fit best where.
I sandwiched one servo between two Radical RC boom mounts and fixed it into position with hot glue.  Put the mounts on the boom and it will be easy to align.  Be sure and use the high temperature setting on your glue gun or the plastic servo body won't stick very well.  Attach the cross-shaped servo arm for maximum surface area to attach the second servo.  Don't forget the screw!
Remove any labels and then hot-glue the second servo onto the  servo arm.  It should be perpendicular.  If you get it wrong, you can clean up the glue joint with rubbing alcohol and try again.
Finally, attach a cross-shaped servo arm to the second servo and hot glue it to the camera mount.  Be sure and check your alignment; my first attempt was very crooked and I had to redo it.
Here's what the mount looks like when it's attached to the rear mounting arm of Arcticopter IV.  I put it in the back so that the Arcticopter arms would appear in any test videos to show the real motion of the unit.

Here's a couple of videos showing the result.  The first one is an overview.  The second is from the GoPro pointing at my iPhone, and the third is from my iPhone pointing back at the GoPro.

Overall I'm pretty pleased with the results.  Ignoring the jitter resulting from the horizontal extension, the camera stays remarkably still.  I need to adjust the rates a little in the software, but it's pretty close as it is.  I had expected the most jitter when pitching down (resulting in the camera moving up); I was a bit surprised that the major jitter was the opposite... the servo would attempt to move the camera downward, gravity would pull the camera down, causing the servo to push back up.  Repeating this through the pitch movement set up an oscillation that really forced the jitter.

Although I must say that if the Arcticopter were moving around like this in flight and if I were the pilot, the last thing to be concerned about would be camera jitter!

Overview video:

Making sure the gimbal motion would clear the mechanism:

Stabilized view from the GoPro, with appropriate jitter disclaimers:

Another view, from the workbench:

Configuration Notes.  If one of the servos is going backwards to how it should be, make the TILT parameter negative.

MultiWii_1_8_patch2 $ diff config.h-orig config.h
< //#define SERVO_TILT
> #define SERVO_TILT
< #define TILT_ROLL_PROP    10
> #define TILT_ROLL_PROP    -10
< //#define BMA180
> #define BMA180

In MultiWiiConf, enable camera stabilization in all modes.

No comments:

Post a Comment