MR60

Building a 3-Axis Gimbal for GoPro

The following steps were taken to build a light-weight responsive 3-axis gimbal for the GoPro.  I'll cover:

I    Requirements

II   Design

III  Build

IV  Test

V   Performance

Background:  The next duration ship needed to be a video and camera platform. The ship can't be fully designed until the envelope of the gimbal/camera is known.  

This is a photo of the final product.

3691242950?profile=original

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • Impressive! A lot of time & effort.
    • MR60

      not as impressive as what Vega does with optics! quite impressive series of products that you offer.

      my hope is that for multi-copter use (a huge potential field given what your cameras can "see" and the applicable use in agriculture and structure inspection) that all commercial suppliers take to heart that with duration multi-copters (ships that fly for more than an hour), that every 10 grams of weight equates to more than 1 minutes of flight.

      so in this case, a 100 grams savings taken off of the gimbal will allow my video quad to fly for 10 more minutes.

  • MR60

    III     Build

    Pitch Axis - The first axis to build and tune.

    With the parts milled out of the lightest and strong-enough sandwich panel material available,

    - the back plate was fitted (note notching) and then bonded to the side and bottom plates using Scotch-Weld 2216 adhesive

    - the back sandwich panel is about 4.6 mm thick so the CNC router cuts out a pocket (one shown for the IMU sensor) along with the through-slot for the connector that plugs into the back of the camera 

    - the camera electronics were embedded into the back pitch axis plate and hot glued (non conductive)

    3702090679?profile=original

    Shows the IMU on the right hot-glued in place

    3702091031?profile=original

    Shows two views of the other side with the:

    - through-slot for the back-of-camera 90 degree connector.

    - the Teflon bushing on the left side

    - the pitch cage around and bonded (rather than bolted at the end of) to the motor bell housing.

      ... creates a larger mechanical interface

      ... pushes the motor 11 mm close to the roll and yaw axis, reducing the total envelope needed to roll/yaw the camera  

      ... reduces the r^2 for the inertia that the roll and yaw motors have to rotate

    3702090949?profile=original

    The motor bell bonded to the pitch housing (hot glue; the gimbal motor is controlled in a manner, the power setting, to not get too hot).

    3702091058?profile=original

    The pitch axis was now ready for motor selection and test with the lightest motor attached as the first try.  The method of test is shown in this video, which was performed on the roll and pitch axis.  The only difference is that only one load was tried, the actual camera.

    https://www.youtube.com/watch?v=w4liszj-fsM

    The test results were as follows. Key are meeting the requirements:  rapid small error (not shown) and stability beyond 30 Hz.  Thus the smallest motor was found to be adequate.

    3702091084?profile=original

    Note:  Autotune in Simple BGC GUI is pretty good.  Tune one axis at a time.  Manual tuning can also be effective.  

    1) Set I and D to zero

    2) Up P until the gimbal becomes unstable

    3) Set P to 50% of that value

    4) Up D to just below instability

    5) Up P to just below instability

    6) Try I values between .005 and 2.

        ... in the Analyze tab, measure stability

       ... in the Scripting tab, oscillate the axis motor to full limits at acceleration = 1300 and velocity = 1000 twenty times

       ... record maximum deviation (the blue number next to the dials showing axis movement

       ... choose the best balance of stability & performance (lower I, to a point, = higher stability and lower accuracy)

    Roll Axis - Next was to build and tune roll.

    The roll arm was fitted and assembled.  The roll arm is shaped like a tuning fork, thus it is important to ensure that the tune it plays is not the same frequency as the gimbal motors nor the same as your target frequencies (< 35 Hz).  The top brace of the roll arm has two functions:

    - push the natural frequency of the roll arm higher

    - allow for an easy way to square the assembly so the opposing pitch motor axle and bushing/pin align.  

    Shown are the:

    - roll and pitch arms.

    - the roll arm pin that goes through the pitch arm bushing (a carbon rod; recommend a fitted nylon or metal rod & bearing)

    3702090700?profile=original

    The carbon roll pin being inserted into the pitch Teflon bearing.

    3702091124?profile=original

    Roll/Pitch assembly complete, front view.

    3702091100?profile=original

    Roll/Pitch assembly back view.

    3702091149?profile=original

    Roll axis ready to be mounted on the test device with its load.

    3702091226?profile=original

    The roll axis was then tested in the same manner as pitch.  In both cases, the motor is attached to the device that oscillates the axis back and forth about 11 degrees at 5 Hz, a rather extreme test in terms of motion.  Also, the following test was conducted in order to bring reality into the test.  After all, who cares about numbers?  What we really care about is the final video result.  This is how reality was brought back into the test.

    https://www.youtube.com/watch?v=lu-u-QYM5Jk

    It is important to note that many of us tend to take the ship high in the air and shoot a beautiful vista that is are away and rave about our gimbals.  But consider what you are seeing.  Hardly any detail.  A leaf is 1 pixel or less.  Definition does not exist, so gimbal performance isn't tested.  The only way to test a gimbal is to move the camera close to a very complex piece of art that is designed to measure photo quality. The eye chart is attached. The smallest oscillations (more than a pixel) are detectable.

    For this axis, 2206 size gimbal motors were deemed adequate, with the results below showing that the requirements were met.

    3702091276?profile=original

    Notes:  for this axis, using a left and right support bar has the advantage of excellent pitch rotation support, necessary for the smaller motor because it's axle is not that strong.  however, if a larger/stronger axle motor was used:

    - could the weight gain be countered by structure loss in the pitch and roll arms?

    - the issue of the tuning fork resonance would no longer be an issue

    - in fact the roll arm had to be slightly widened so that the bushing did not contact the roll arm or resonate backlash vibrations that would excite the motors

    - the advantage of a one side roll arm would be a smaller rotational envelope and possibly bring the roll axis closer to the lens axis

    - if i rebuild the gimbal, i'll try this option to see if it can be done without net weight gain or loss in performance.

    Yaw Axis - One might think that Yaw would be the easiest axis since it really only has to rotate about +/- 17 degrees in ship follow mode.  Thus the tests can be restrained to about +/-20 degrees.  But it proved to be the most difficult axis to tame, finally having to move to the largest of the motors, which might not be large enough.  The primary problem was stability:

    - the 2206 motors were only stable to about 10 Hz (maybe that's high enough, but way under 30 frames per second).

    - it proved to be impacted by the lower motors which could together excite yaw if one pushed the PIDs too high

    - then once Yaw got excited, that vibration would feed back to roll and pitch

    - with Yaw and Roll, i tried filtering (an option with the Basecam controller), but never achieved a satisfactory result.

    So a simple Yaw arm show here was fitted and bonded.  The only real design consideration besides the obvious is ensuring that the brace doesn't interfere with the camera and gimbal wires during rotation.  A script was written to ensure that the wires would not cause issues by using a script that tested out every possible combination of roll, pitch and yaw in 15 degree increments (a rather long script).  This also ensured that there wasn't a 6D position of the camera that would cause unwanted harmonics.

    This photo also gives you a good look at sandwich panel material.  Carbon/Balsa core sandwich panels are extremely strong because the layer farthest from its center is a single ply of carbon. Then the core, while soft balsa, is put on edge so the balsa tree core is put 90 degrees to the carbon plies, making the core highly non-compressible (soft on the sides and hard at the ends). This keeps the two carbon skins in a near perfect parallel condition during bending resulting in extreme stiffness for the weight.

    3702091285?profile=original

    Finally after three days of trying different PIDs and motors, the test results yielded the following:

    3702091175?profile=original

    I would have preferred higher stability to well over 30 Hz.  But Yaw vibration is not as violent as roll and pitch (vertical to gravity and tends to harmonize at lower frequencies.  So hopefully, the results, while not meeting the original requirements, are OK.  If the actual video proves that Yaw does not have to be stable to over 10 Hz (versus 30 Hz), the PIDs will get reduced to further distance Yaw from harmonics.

    eye chart multi-rotor rev b.PDF

  • MR60

    II     Design

    Motor Selection -  Four gimbal motors were selected for testing to handle the expected torque and offset loads.

    - Torque loads were estimated by placing the required virtual parts in 3-D space; the mass of each part estimated and multiplied by the inertial equation for each shape type and then added to the mass times the square of the distances from each axis to derive the parallel moment of inertia for each axis (g-mm2):  100k for pitch, 160K for roll, and 165k for Yaw.  

    - The motors were then tested to those loads.  Three of the motors shown here.

    3702090185?profile=original

    The motors were put on a device to test their ability to handle load.  This is one type of torque test performed on each motor.

    https://www.youtube.com/watch?v=g7fJaW9smSI

    Then this test was used to measure response and error of the motor to rotating different inertial loads.

    https://www.youtube.com/watch?v=w4liszj-fsM

    The results of the test are summarized here.

    GBM 1806 by MayTech - very light weight; for GoPro mass and inertia:
    - axle too weak to support suspended camera,
    - does not support > 30 Hz stability (but might for Pitch);
    - low unbalanced torque ability; if retested for Mobius camera inertias and mass, it would likely be good in all tests.
    - also recommend a through-the-bell mount to decrease axis load and decreasing roll inertia
    Turnigy AX-2206 is marginally better than the GBM 1806​ because
    - it was stable to 30 Hz
    - is OK (won't freak) until past 40 Hz
    - can handle nearly 2x as much unbalanced torque
    - errors were smaller (0.05ish degrees vs. 0.07ish) 
    - but weighs 12 grams more
    ​T-Motor at 8 more grams than the Turnigy might be worth the weight gain
    - is stable to 50 Hz with fairly smooth degradation until just past 60 Hz (the new critical 60 fps rate)
    - can handle 35% more unbalanced load than the Turnigy
    - but couldn't seem to tune it so the errors would be smaller than 0.06ish

    Motor selection was performed on each actual axis so that the lightest solution would be chosen.

    Electrical Interface - Chose the Lumeneir GoPro Live Video Out + Charge Right Angle Connector that goes into the back of the camera.  Note:  going into the side of the camera (the USB type) takes too much room and pushes the motor farther out on the axis creating more inertia for the gimbal motors to move (a function of distance squared).  

    3702090329?profile=original

    Mechanical Interface to Camera - Velcro strap.  See photo above.

    Gimbal Controller - DYS Basecam SimpleBGC 32-bit Tiny.  Selected for performance, weight (10 g w/o the case), the two IMUs, follow and other modes, and the software (SimpleBGC GUI) for testing the setup.  

    3702090257?profile=original

    Camera Isolation Cage Option - By placing two sets of dampers in series, one can increase the total dampening from 15 dB to possibly 20ish dB.  With 3 set ... who knows.  For example, Damper set:

    1, a given, was the set of dampers between the ship frame/motors and the electronics platform (FC + batteries + gimbal)

    2, an option, was between the electronics platform and the gimbal

    3, an option, was between the final gimbal motor (pitch) and the camera.

    In the photo below, the camera is given extra isolation from motor noise (option 3) as each motor does have a hum during movement and can also hum during stationary hold.  Note the two GoPro dampers on top and two on bottom of the camera. This concept was tested.  Because of the low resolution (compared to professional cameras) of the GoPro, this level of vibration isolation was deemed unnecessary.  Thus the isolation cage for the camera was eliminated.

    3702090198?profile=original

    .

    Materials - Three types of sandwich panels were used in design.

    - 1-ply Carbon with sandwich panel using 1/8" balsa core (most structural parts)

    - 1-ply Carbon skin sandwich panel using 1/4" balsa core (around the pitch motor bell housing)

    - 2-ply Carbon skin sandwich panel using  1/16" birch core (thin enough to interface to dampers)

    Drawings - The system drawing.

    3702090402?profile=original

     

    The part drawings.

    3702090274?profile=original

    Coming to this design took three iterations:  the isolated cage design and then two iterations to get the roll bar sized correctly for 3D wire movement envelope and control of the roll bar (tuning fork shape).  

    Also, for ease of assembly, the notches were chosen to aide alignment and joint angles. If going commercial, however, the through-bolt to an embedded nut design might be better.

    Camera Lens Motion - If the camera is under the ship, when the ship rolls or pitches, the lens is physically displaced in 3D space.  The farther the lens is from the rotational CG of the ship, the more the lens is moved (displaced).  For example:

    - it is common for a ship in stable mode to rotate 1 degrees before attitude is corrected.

    - if the camera is 50 mm (2") below the center of ship rotation, then the camera will be displaced 0.9 mm

    - this equates to a HDMI chip that is 10 mm showing the scene shift 200ish pixels or 9% of the screen.

    This displacement of the scene is further explained here:

    3702090373?profile=original

    During the trial with the isolated camera cage, the lens/parallax was mounted centered to each axis versus aligning the axis to the CG of what it's rotating.  This results in not scene shifts caused by the ship stabilizing but also causes imbalances that need correction by adding weight (balance) to each axis.  Since weight can increase vibration, a trade-off is needed.

    Calculations were made to identify the errors if each axis was aligned to the axis CG instead assuming high performance response where errors would not exceed .07 degrees and the offset was less than 4mm.  It turns out that the scene shift would be about 23% of the width of one pixel.  So it was determined that:

    - aligning each axis to the lens axis and parallax was not necessary for the resolution of the GoPro.

    - but that the gimbal would be located such that the axis of the gimbal motors was at the CG of the ship.

    The rest of the requirements would be met through motor selection and testing of each axis as the gimbal was assembled.

    • MR60

      i'm still looking for a GoPro 4 interface cable that:

      - allows HD video out (might be GoPro limitation)

      - comes out the back (as the one i'm using) so system remains compact (versus out the right side USB)

      - was also thinking that battery elimination would be nice:

        ... Pro, less weight to rotate and gets roll motor closer to the lens center

        ... Con, heat is lost from converting 12+ VDC to 4 - 5 VDC

    • MR60

      For those interested, here is a picture of the worksheet used to estimate axis loads in terms of inertia.

      - Col 1 to 7 define the mass and size/shape geometry (cuboid, rod, sphere, etc)

      - Col 8 to 10 define the mass position in 3D space from each gimbal axis

      - Col 11 to 14 the torques

      - Col 15 to 17 the moment of inertia for each axis (to rotate the object on it's own axis)

      - Col 18 to 20 the parallel moment of inertia for each axis (to rotate that object around a parallel axis)

      3702593466?profile=original

      The formulas for the different shapes are like these that can be found on the internet.

      3702550351?profile=original

      https://storage.ning.com/topology/rest/1.0/file/get/3702593466?profile=original
  • MR60

    I     Requirements

    1) 3-axis to handle roll, pitch, and yaw ship stability movements (estimated at < 20 Hz corrective movement)

    2) yaw with programmable follow mode to transition ship yaw motion

    3) degrees of motion

        - pitch +45 to -110     panning down while retreating and slightly up while going forward

        - roll    -45 to +45      ship movement not likely to exceed +/- 20 degrees

        - yaw   +17 to -17      ship will handle large yaw movements

    4) Physical interface (mechanical lock and electrical) to GoPro 3 or 4 (camera will not carry a battery)

    5) Limited to a 114 mm side to side envelope (fit between the batteries)

    6) Total package < 200 grams (for a duration ship 200 g equates to a 20ish minute reduction in flight time)

    7) Camera lens movement less than 3 mm during ship rotation (roll, pitch, or yaw)

    8) Max deviation error during normal flight < 0.1 degrees at 5 Hz

    9) Stable high performance movement to > 30 Hz for final recording at 30 frames per second

    10) Stable in wind offset torque of 500 g-mm

This reply was deleted.

Activity