robotics project quadruped and a kalman...

3
1 Robotics Project Quadruped and a Kalman Filter Eric Carmi and Jason Vossoughi, California State University Sacramento EEE 187 - Robotics December 13, 2015 Abstract—Humans have been trying to replicate the motion of walking of mammals and insects with the use of robots. Recently humans have become successful in creating accurate robots that can walk, run and maintain stability. Our goal is to create a robot that is stable and able to walk in a similar motion to a dog, and also to be able to track its position. The robot was designed and evaluated in a CAD program (SolidWorks), which was then printed on a 3D printer. I. I NTRODUCTION L EGGED locomotion is a popular area of re- search in robotics. It is possible to design a legged robot with various numbers of legs, and therefore varying amounts of possible gaits by which the robot can navigate. It is also possible to design a legged robot’s frame from scratch with the advent of 3D printers. If the robot would like to be used for the SLAM problem, encoders are not effective sensors to use if there are many motors on the robot. Alternatively, a typical IMU could be used to localize a robot relative to some initial position by double integrating the acceleration data. A Kalman Filter (KF) is a great tool for removing noise typically found in sensor measurements II. S OFTWARE FOR QUADRUPED CALIBRATION Once the servos have been put in place, the angles corresponding to certain configurations needs to be figured out. An easy way to accomplish this is to use a GUI that enables independent control of each servo position. One implementation uses Python, which is a very easy programming language to learn with many resources available online (and it’s open source!). A screen-shot of the GUI is shown in figure 1. The values of the sliders in Python range between 0 Fig. 1. Python GUI for Quadruped Calibration and 180, and are sent through the computer’s serial port to the Arduino. Sliders 1-8 control each servo motor individually, while sliders 9,10 and 11 control all of the knees, the front hips and the back hips, respectively. With the help of this GUI, it was easy to calibrate its standing position so that the Quadruped could default to standing position whenever it is turned on. Once we figured out how to make it stand, we moved the sliders around to figure out if it could stand on three legs, and what kind of gait would allow it to walk. Unfortunately, we were not able to make the robot walk by simply moving one slider at a time or even with the help of the combo-motion sliders. III. DESIGN OF THE ROBOT Looking at Design 1 in figure 2, there are three servo motors per leg. On this leg there are three links which can be examined further. The three links include the following: hip, leg and foot. Link 1 is rotated about the Z axis and its job is to turn the robot. Link 2 is rotated about the x axis and is used to walk forward and backward. Lastly, Link 3 is rotated about the x axis. The last link rotating about the x-axis is to assist the forward and backward motion. In Figure 2 we see the first design of the three 3 links and how the it assembled together. One

Upload: others

Post on 22-Apr-2020

9 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Robotics Project Quadruped and a Kalman Filterathena.ecs.csus.edu/~vossougj/Final_Project.pdfRobotics Project Quadruped and a Kalman Filter Eric Carmi and Jason Vossoughi, California

1

Robotics ProjectQuadruped and a Kalman Filter

Eric Carmi and Jason Vossoughi,California State University Sacramento

EEE 187 - RoboticsDecember 13, 2015

Abstract—Humans have been trying to replicate themotion of walking of mammals and insects with the useof robots. Recently humans have become successful increating accurate robots that can walk, run and maintainstability. Our goal is to create a robot that is stable and ableto walk in a similar motion to a dog, and also to be able totrack its position. The robot was designed and evaluatedin a CAD program (SolidWorks), which was then printedon a 3D printer.

I. INTRODUCTION

LEGGED locomotion is a popular area of re-search in robotics. It is possible to design a

legged robot with various numbers of legs, andtherefore varying amounts of possible gaits bywhich the robot can navigate. It is also possible todesign a legged robot’s frame from scratch with theadvent of 3D printers. If the robot would like tobe used for the SLAM problem, encoders are noteffective sensors to use if there are many motorson the robot. Alternatively, a typical IMU couldbe used to localize a robot relative to some initialposition by double integrating the acceleration data.A Kalman Filter (KF) is a great tool for removingnoise typically found in sensor measurements

II. SOFTWARE FOR QUADRUPED CALIBRATION

Once the servos have been put in place, the anglescorresponding to certain configurations needs to befigured out. An easy way to accomplish this is touse a GUI that enables independent control of eachservo position. One implementation uses Python,which is a very easy programming language to learnwith many resources available online (and it’s opensource!).

A screen-shot of the GUI is shown in figure 1.The values of the sliders in Python range between 0

Fig. 1. Python GUI for Quadruped Calibration

and 180, and are sent through the computer’s serialport to the Arduino. Sliders 1-8 control each servomotor individually, while sliders 9,10 and 11 controlall of the knees, the front hips and the back hips,respectively.

With the help of this GUI, it was easy to calibrateits standing position so that the Quadruped coulddefault to standing position whenever it is turnedon. Once we figured out how to make it stand, wemoved the sliders around to figure out if it couldstand on three legs, and what kind of gait wouldallow it to walk. Unfortunately, we were not able tomake the robot walk by simply moving one sliderat a time or even with the help of the combo-motionsliders.

III. DESIGN OF THE ROBOT

Looking at Design 1 in figure 2, there are threeservo motors per leg. On this leg there are threelinks which can be examined further. The three linksinclude the following: hip, leg and foot. Link 1 isrotated about the Z axis and its job is to turn therobot. Link 2 is rotated about the x axis and is usedto walk forward and backward. Lastly, Link 3 isrotated about the x axis. The last link rotating aboutthe x-axis is to assist the forward and backwardmotion.

In Figure 2 we see the first design of the three3 links and how the it assembled together. One

Page 2: Robotics Project Quadruped and a Kalman Filterathena.ecs.csus.edu/~vossougj/Final_Project.pdfRobotics Project Quadruped and a Kalman Filter Eric Carmi and Jason Vossoughi, California

2

Fig. 2. Design 1

problem we encountered was the links caused therobot to wobble while moving. In Figure 3 we seetwo servos motors per leg and 2 links per leg. Thereis 1 hip and 1 leg. This Link 1; has the same linkas the one above. Link 2; has the same link asthe two above. In our second design we attemptedto fix our problem with the robot wobbling. Ourattempt to further design would hopefully reduce thewobble we had experienced. We accomplished thisby eliminating the middle servo that controlled theknee. This had a big effect on the stability. The robotknow could lift each leg while remaining balancedon the other three legs.

A. Components

Our robot was created with several different partswhich were in charge of certain actions. The Ar-duino was the brains of the robot and controlledeach servo motor. We chose to use the Arduino Due,which had just enough connections for all twelveservos. The servos were mounted at each joint andwhere small MG90S metal servo motors. Each servowas capable of rotating a total of 180 degrees.

Lastly, all this was possible due to our batterysupply which is made up of 8 AA batteries. Figure 4is an image of our finished robot. The robot has fourlegs and a center body. On the bottom of the feetthere are rubber grips. The rubber grips help keep

Fig. 3. One Leg for Design 2

Fig. 4. Robot Completely Built

the robot stable and move over different surfaces.We were inspired by our four legged friends andthe way they move upon the ground.

IV. LOCALIZING A QUADRUPED

Encoders are useful sensors that allow a robot totrack how much it has moved from an initial loca-tion. With 8 servos, it is not practical to use encodersto track the Quadruped’s location. Acceleration datafrom an IMU can be used to calculate linear velocityand motion. This is much cheaper than buying 8encoders, but IMUs tend to be noisy, which means

Page 3: Robotics Project Quadruped and a Kalman Filterathena.ecs.csus.edu/~vossougj/Final_Project.pdfRobotics Project Quadruped and a Kalman Filter Eric Carmi and Jason Vossoughi, California

3

Fig. 5. IMU

Fig. 6. Probability Distributions for a Prediction and MeasurementStep for the Kalman Filter

a Kalman Filter is essential for making the sensor’smeasurements useful. Figure 5 shows the IMU wedecided to use for our project. The IMU had thecapability to measure 10 degrees of freedom.

A Kalman Filter consists of two prediction equa-tions and four update equations. The predictionequations step uses the previous state, input andcovariance to predict the current state. The updateequations uses a measurement and the predictionto make an approximation of the true state byconsidering where the probability distributions ofthe measurement and prediction overlap. This dis-tribution is overlap is illustrated in figure 7.

Python was used to read the acceleration datafrom the Arduino and make a plot of the data.Although the Kalman Filter was implemented oncethe acceleration data had been sent to the Pythoninterpreter, it is probably better to filter the datawith the Arduino so that the computer can make asmoother real-time plot. An example of the Python

0 50 100 150 200Iteration

1.0

0.5

0.0

0.5

1.0

Acce

lera

tion

FilteredMeasurement

Fig. 7. Acceleration Data from IMU: Measured and Kalman Filtered

plot is shown in figure blank, and the code used isattached to this document.

V. PROBLEMS ENCOUNTERED

While working on this design we experienceda handful of problems. Our first design was verywobbly which caused the robot to fall while on threelegs. What we found was that we needed better con-nections between each link. We also needed morepowerful servos that could handle the weight of therobot. To solve all the problems would have requiredan entire new design. The new design would haveservo motors that had a gear on each side, whichwould have allowed for a sturdier construction andmore torque at each joint. We initially avoided theseservo motors because of the high cost.

VI. CONCLUSION

As the result of our editing and adjusting the firstdesign, our second design had small improvements.After removing one joint we saw more stabilityand less wobbling. The servos also didn’t have thetorque to lift its own weight. One goal we didaccomplish was to have the robot stable enough tostand on three feet.

After our adjustments, we were able to move for-ward with our project and accepting the fact that therobot could not walk. In creating a walking robot welearned the importance of the connections betweenthe links. Lastly, we learned that we need to addin more powerful motors. Overall, we learned anincredible amount of things to avoid when creatinga walking robot.