Arduino Gimbal With Micro Servos

54,813

234

33

Introduction: Arduino Gimbal With Micro Servos

About: Engineer, Norway

I find gimbals really fascinating even just to look at. So lately I decided to make my own since the ones out there are so expensive, and making stuff is so much cooler than buying stuff.

I quickly realized that they are usually made with a gimbal controller board and brushless motors. And they are super easy to make, so maybe later I will make one of those. But I also have a lot of components laying around, and just because i was curious i decided to make a arduino gimbal with micro servos

luckily I found this instructable by woojay wich became the basis for my gimbal.

I had no hopes that it could even support my action camera, but to my surprise it did. It has some delay, but its a fun and interesting project and its really cheap.

Step 1: Partslist

The parts needed for the arduino gimbal with micro servos is:

2 x 9g micro servos

1 x arduino (i prototyped with the uno, and in the end i used the nano just because it so little, you can use wich one you like)

1 x mpu6050 accel/gyro sensor

2 x 10k resistors

Power supply (i ended up with 4x1.5 AA batteries) IMPORTANT, the power output from the arduino will not be enough to drive the servos itself, you NEED external power.

And the casing and arms. I printed this item, my design can be found on thingiverse. And if you have a printer yourself, i would love to see some other designs, mine was rough and could probably be a lot more refined.

Step 2: The Prototype

So i searched a lot around the web to find anyone else making a gimbal with micro servos. And i couldn't find much info, so I assumed that this wouldn't even work since the internet wasn't full of info. But there was one instructable that made it all happen. It was a prototype of the system made by woojay. This really helped a lot since I am not a programmer in any ways.

So i went ahead and built his system with his code and it worked without any issues.

The only thing to be clear about here is the calibration of the MPU6050. Everyone of these sensor are unique in there own way, therefor you need to run the calibration program stand alone on your MPU6050 first to read its characteristics. The the value you get out of you chip must be edited in to your specific program for the gimbal.

For the mpu6050 to work you also need I2Cdev and the MPU6050 Libraries installed.

For this sample to work, the I2Cdev and the MPU6050 libraries need to be installed. Find the calibration program and wiring diagram attached. Also check out woojay's instructable, he has good wiring diagrams.

Step 3: Going Forward

So i made woojay's system, then it is time to turn it in to a real gimbal. This is all about creativity and how you want to make you specific system, you can use my step files and print it, or make something completely different.

I used a nano instead from this point to make it smaller and a cheap protoboard to make it one unit.

I put the mpu6050 inside the main box. I've read that maybe putting it on the camera side (the arm the camera sits on) might be a better solution. So that is up to you. Everything would still be the same if you choose to do so.

As you can see from pictures and video the first arm configuration i design was to flexible, maybe I should have seen that one coming, but anyways I am giving you a heads up now if you should want to design your own. I also added a switch between the battery and arduino.

Any questions leave a comment, and read more at my blog

First Time Authors Contest 2016

Participated in the
First Time Authors Contest 2016

Epilog Contest 8

Participated in the
Epilog Contest 8

Remix Contest 2016

Participated in the
Remix Contest 2016

1 Person Made This Project!

Recommendations

  • For the Home Contest

    For the Home Contest
  • Big and Small Contest

    Big and Small Contest
  • Make It Bridge

    Make It Bridge

33 Comments

0
misterton44
misterton44

2 years ago

hi ~
my name is Max, I just learned about how to make a 3 axis gimbal and I found your article. I am very interested in the project you created. I have tried lots of examples regarding the MPU6050, I have tried everything you tell me, but I still do not succeed in moving the servo that I use (even though the green led light indicates the signal has been transferred successfully already on), please help and guidance if you can contact me because your guidance and assistance means a lot to me! My email address is misterton44@gmail.com

0
astroguy034
astroguy034

3 years ago

Let's say I take different motors, make a massive frame and replace the GoPro with a decently sized film camera. If I adjust for the new motor input and other differences, will this work?

1
mati007
mati007

3 years ago

Heyhey!
I made his gimbal from Woojay but I used 9G Servos with meral gears and I modified them that they have no tolerance (shaft).
It worked but it is to slow for fast and great movements.
If there is no counterforce when roll-arm is moving down...arm is chattering.So better use a counterbalance or spring or elastic strap.
Any ideas how to fasten up the reaction of the system?
cheers!

0
Mehran khattak
Mehran khattak

3 years ago

hey is there anyone who made this gimbal?

1
blackie99
blackie99

5 years ago

Looks like a fun project! Question - I may be wrong but I think there is a wiring error in your small picture of the servos, UNO, 6050, and the 9V battery. The 6050 GND seems to be connected to the UNO VIN. Shouldn't UNO VIN get +9V and 6050 GND get ground from someplace?

0
spenproject
spenproject

Question 3 years ago

How long should it take to calibrate?? I let mine go for 5 minuets and all i got was dots no finished message.

0
ArkadiuszS7
ArkadiuszS7

4 years ago

Thanks for inspiration, I'm gonna use your code and tutorial to build my own gimbal, however I believe that 180 degree of freedom on these servos is more that needed.

I will step down gearing on these servos leaving only about 60-80 degree of freedom and at the same time increase torque. That hopefully will eliminate shaking. What do you guys think, will it work?

0
gugliandolosergio
gugliandolosergio

Question 4 years ago

Why just 2 and not 3 axis? There is a lot of difference!

0
Jencek
Jencek

Question 4 years ago

The I2Cdev library can not be inserted into Arduino 1.8.4, it does not contain the correct files .. Something like that says :-( Please help, thanks ..

0
YogeshG41
YogeshG41

4 years ago

enabling interrupt detection (arduino external interrupt 0).... Nothing happens after printing this... What should I do?

2
sblood1
sblood1

Question 5 years ago on Step 2

How do you download those libraries, because it isn't working for me.

0
ArvilD1
ArvilD1

5 years ago

Why not use 5v for gyro vcc instead of 3.3v?

0
robo sagar
robo sagar

5 years ago

hey please help! i am not able to open the code .Please share the code here or please mail gimbal code to my mail - theultimateforcerobo@gmail.com .

thank you, nice works

0
BảoT8
BảoT8

5 years ago

hi there. i want to a question why we have two file code. i don't know why we have two file..tks if you reply. i really want to do that.

0
blackie99
blackie99

5 years ago

I made the project with a Nano and it and it works great! Many thanks to Friedrikeide and Woojay! I will use it to show some teens how a gyro can be used to change the direction of a rocket. That's quite a leap from this project, but it's a start! Does anybody have suggestions for changing the servos from pitch and roll to pitch and yaw? Or even better, to use servos on all three axes.

Gimbal 2 Servo project.jpg
0
BảoT8
BảoT8

Reply 5 years ago

hi there. i want to a question why we have two file code. i don't know why we have two file..tks if you reply

0
paul.sneed.39
paul.sneed.39

5 years ago

nice job!.. I have an issue with the code though, help? :)

0
Fredrikeide
Fredrikeide

Reply 5 years ago

maybe? what is the problem?

0
BrendanP20
BrendanP20

5 years ago

I actually just finished building this! Thank you but the servos keep spazzing out. Any idea why? I calibrated the gyro too