Introduction: 3D Printed Brushless Gimbal
Welcome to my instructable about how I built a Brushless Gimbal with 3D printed parts. This is my first 'ible so any feedback about what I've done right or wrong will be greatly appreciated.
I've fancied a gimbal for my action camera for a while. The problem is that they are quite expensive and generally made for a Go Pro so might not work well with my MUVI action cam.
The solution is to make one. This was to be a bit of an experiment for me, I started with very little knowledge of brushless gimbals and it is also my first useful project with my 3d printer. It is fairly important to have a strong ridged gimbal so 3d printing the parts probably isn't the best option. However, my main motivation was to see if I could build it and get it working.
The gimbal needs to fit around my MUVI K2 action camera, if you build a gimbal for a different camera, you will want to alter the dimensions of the 3D printed parts to fit yours. I'd like the gimbal to have three axes so it will need three motors, it will need a controller board to drive the motors with an accelerometer to sense the motion of the camera. It will require a battery to supply power, I'll look through a few options later. I will add a joystick to allow manual adjustment of the pitch and yaw axes, although this is optional. I also want to 3d print as many of the parts as possible. My gimbal will be handheld but if you wanted to hang it from a drone instead, it's fairly simple to flip it over and alter a few settings.
Step 1: Parts and Tools
Let's start with all the bits needed to build the gimbal:
- 3x Brushless Gimbal Motors
(I used 2208 motors) ~£6 each from ebay
- 1x Brushless Gimbal Controller
(I used Storm32 v3.1 board) ~£18 from ebay
- 1x joystick module ~£3 from ebay
- USB to TTL serial adapter or cable for flashing the firmware
- Power source (my BGC takes 6-24v) with suitable connectors
(I used a couple of 18650 lithium cells with a battery box)
- 3D Printer
- Jumper wires (or wire and soldering iron)
- Calipers (for measuring camera and various parts)
A few screwdrivers, a craft knife and the usual bits and bobs will probably be useful too.
Step 2: Electronics
There are a variety of options for this section of the build, I will explain what I used but feel free to try something else.
First the motors; I used 3x 2208 Brushless Gimbal Motors which seem to be more than adequate for my needs. After ordering these I discovered motors with hollow shafts, these have a hole running through the middle of the shafts to allow routing of the cables. This is probably an option worth exploring as it would help keep the cables neat and out of the way.
The motors are brushless so require drivers and a controller is needed to interpret the sensor reading and calculate movements for the motors. For this I used a Storm32 Brushless Gimbal Controller which includes motor drivers. I used version 1.31 of the BGC board. I didn't put a huge amount of consideration into my choice of board so I'm not sure how it compares to other controllers, however it does have a very good online documentation and set up guide which I found very useful, it is linked to below. There is also some useful information on there about building and balancing a gimbal.
OlliW's wiki pages: http://www.olliw.eu/storm32bgc-wiki/Manuals_and_Tutorials
I decided to add a joystick which will allow manual control of the pitch and yaw axes. Most joystick modules also include a button when the stick is pressed in which can by used to toggle modes or anything you like.
Finally the gimbal needs a power supply. The 1.31 version of the Storm32 board will accept anything between 6v and 24v. I chose to use a couple of 18650 lithium cells in a battery box. If you have Lipo batteries then these would also be a great solution and anything from 2S to 6S should work. I don't have a Lipo charger which is why I opted for the 18650s instead as I already have a charger for them.
I have a fairly long cable between the battery box and gimbal to allow me to keep the batteries in my pocket and keep down the weight in my hand. However, you could incorporate the batteries into the handle to keep everything together.
Step 3: 3d Design
By far the most time consuming part of the build was designing the parts to be printed. I used Tinker cad to create the designs. The software is very easy to use but is fairly basic with regards to features which made the process slower. I have since played with Fusion 360 which is trickier to get used to but has many features which would have made the designing a bit easier.
The first part to make is the Pitch axis, this is the part that will hold the camera and connect to the Pitch motor. I made a small cavity in the bottom to hold the accelerometer board, this can be placed elsewhere on the part if you prefer as long as it is aligned with the axes of the gimbal. I also made the attachment holes for the motor adjustable so the balance of the axis can be fine tuned.
The next part to make is the Roll arm. This is much simpler and just connects the Pitch and Roll motors. The important thing to note here is that everything so far (Camera, pitch motor and pitch arm not just the camera) are balanced with the centre of the Roll motor. Like before, I have made the Roll motor attachment adjustable.
Thirdly is the Yaw arm. This is just like the Roll arm but a bit bigger. Balance this part the same as noted before. I made the arm big enough to allow the Roll arm to fit inside so the gimbal will lie flat for storage.
The last parts to print are the base box and it's lid. The dimensions of these may vary if you use a different BGC. I tried to keep the box small while leaving enough room for all the wiring inside. The box will need to have a hole that allows a USB cable to be plugged into the board for programming, a hole for the power cable or connector and a hole for the wires connecting the joystick or any other accessories you might like to add.
The lid needs a method of securing, I used a screw in each corner which also line up with the mounting holes in the BGC. You may want to consider options for a handle here too, I printed the lid with a small square recess into which I glued a standard Go Pro mount to leave further options for the handle.
The last file is of a covering box that fits over the joystick, it isn't included in any of the pictures as I haven't decided if it's necessary yet and therefore haven't printed it. Although, I may do in the future...
EDIT: I did get around to printing the joystick cover and I quite like it, so a picture is now included in the last step (6).
Step 4: Assembly
With everything printed it should be fairly simple to fit everything together. The motors bolt onto the 3d printed parts with the included bolts. The accelerometer is pushed into the cavity in the pitch arm, mine was quite a tight fit, you may need a dab of glue. The motor connectors slot through the holes in the base and plug into the header pins on the BGC, the orientation of the connectors doesn't matter. The joystick is plugged into the POT pins on the BGC, match up 3.3v, Gnd and the button pins then connect the x and y axes of the stick to any two of the POT pins, you can select their functions later. Any of the connections could be soldered instead to save a bit of space inside. I connected the board to a DC barrel jack which fitted through the side of the box for connection with the batteries. I printed a small recess on the side of the box to place the joystick in, it is simply glued in place. With the controller board inside all that is left to do is screw the lid to the base of the box.
My camera is currently attached to the gimbal with a few elastic bands until I decide on a better solution!
That completes the gimbal itself, but to run properly the settings on the BGC need to be set up and tuned.
Step 5: Firmware Set Up and Tuning
This step is covered very well in the wiki pages relating the the Storm32 board which is a great resource and explains the process much better then I can hope to. Consequently, this step is just a quick overview of the guide on the wiki.
These two pages are particularly useful: Getting Started and Tuning Recipe.
Depending on the board you purchase, it may or may not have the firmware included. Either way it is probably a good idea to flash the latest version, to do this you will require a USB to TTL Serial converter, the type needed and process to follow is explained thoroughly on the wiki. It is probably better (easier) to do this before fully assembling the gimbal.
With the firmware flashed to your board, open the corresponding software tool again and connect the BGC with a USB cable. You can now set up your gimbal using the 'Configure Gimbal Tool', add settings for the joystick (in the RC Inputs tab) and customise any other settings you choose.
Finally, you will need to tune the PID settings. The PID Controller is what works out how much to move the motors to make the gimbal react to movements of you hand, if the PID settings are set too low then the gimbal will react very slowly, but set too high and the motor may judder or oscillate. The idea is to carefully tune each motor controller to achieve the most reactive settings that produce no unwanted side effects. Like before there is a Tuning Recipe (linked above) on the wiki page which will guide you through the process.
Step 6: Final Thoughts
I learnt a lot while making my gimbal so there are a few things I would do differently next time.
For starters, 3d Printed parts probably aren't ideal for the gimbal arms, I don't have anything to compare with, but there is some flexibility in the plastic and I think the PID settings need to be lower to compensate this. Having said that, the gimbal does work and perform fairly well.
The BGC I used is quite big which makes it's box bulky. Similarly, I just stuck the joystick to the outside making it even bigger. Using different components might have allowed for a more compact design.
I designed a small box to fit over the joystick but remain unsure about it's usefulness. I may print it at some point and see what happens.
Edit: I have now printed the joystick cover and it turned out a lot better than I had expected, it is now shown in the pictures above.
The 3d designs also suffer a little from my naivety, I squared the top of all the holes, but this wasn't really necessary. I also left the corners of the arms square rather than rounding or tapering them which causes the wires to occasionally get stuck. Using hollow shaft motors would fix this problem too.
The holes for cables in the top of the base weren't quite big enough for the connectors to fit through so I had to carve them out a bit, it's always worth double checking measurements!
All in, I spent around £40 on the gimbal components and another £20 or so on batteries and battery box. I think this is fairly reasonable considering the +£200 price tag of most retail gimbals, while still retaining the necessary features.
Overall, it all came together and worked really well, dispite being a little rough round the edges.
This is my first Instructable, so thank you for getting to the end of it :)
Any feedback you wish to give is appreciated.