[Willy Wampa] is showing off his self-balancing robot. What strikes us about the build is how well tuned his feedback loop seems to be. In the video after the break you will see that there is absolutely no visible oscillation used to keep its balance.
The parts used are quite easy to obtain. The acrylic mounting plates are his wife’s design and were custom cut through the Pololu service. They were also the source of the gear motors. He’s using a SparkFun IMU with an Arduino and a motor shield. He first posted about the build about a month ago, but the new revision switches to a Pololu motor driver shield which he says works much better, and adds control via a wireless Wii Nunchuck.
The PID loop which gives it that remarkably solid upright stance is from a library written by [Brett Beauregard]. Once again the concept of open source lets us build great things by standing on the shoulders of others.
[via Reddit]
Very cool. It reminded me of R2D2 chasing the ewoks with the electric zapper :P
I wanted to see the dog get fed up and latch onto it and “shake”. :)
Hey, thanks for featuring my project (although I wish you’d correct the spelling of my username – wily, not willy). Here are the parts that I used:
Arduino Uno R3
Pololu 29:1 Metal Gearmotor 37Dx52L mm with 64 CPR Encoder
Pololu Wheel 90x10mm
Pololu Dual VNH5019 Motor Driver Shield for Arduino
SparkFun IMU Analog Combo Board – 5 Degrees of Freedom IDG500/ADXL335
Nyko Wireless Kama
I use a complementary filter to estimate the tilt angle and rate from the IMU vertical and longitudinal accelerometers and tilt gyroscope. The control loop has an outer PID loop of motor speed with tilt angle command output (from the encoders), a middle loop of tilt angle with tilt rate command output, and an inner loop of tilt rate with motor PWM command. There’s a separate loop to control yaw rate (turning) which is just PID with a setpoint from the Wii Nunchuck, input from the yaw gyroscope, and output of a differential PWM motor command.
This board would be o good fit for this project
http://www.robogaia.com/6-axis-accelerometer-gyro-arduino-shield.html
D’awwww, corgi! Oh, and there’s some remote controlled balancing thing, too. That’s pretty nifty.
I officially need to build one of these now.
So what’s the thinking behind having the battery mounted up so high?
Putting the weight up higher (still thinking through the physics) might make it easier to balance because the lowers the amount of weight of the base. Maybe that would lower the power needs to stabilize the system? Moving a lower amount of mass is easier?
I designed it so that the battery height would be adjustable, and found that the maximum height with the threaded rods I used was best. A balancing robot is essentially an inverted pendulum, which has a period inversely proportional to its length. The farther away the center of gravity is from the rotation axis, the longer the period, and hence the slower it falls over, making it easier to correct.
To see that Wily is correct, try this:
tape some weight (wraps of wire) to one end of a yardstick. Try to balance the stick on a finger when the weight is near your finger; then try to balance it when the weight is at the top.
Neil
That can test it yourself. Never balanced a stick or a broom in your hand or chin?
Test how compares attaching some weight to the top/middle/bottom of it. Show it to the kids. ;)
This is very cool. I want to do a project like this soon.
Maybe a weed eating self balancing robot for the lawn edging.
Thinking of using an old wheel chair chassis for the 2 wheels and belt driving them.
Nice job. Very inspiring.
That’s pretty awesome. I mean, anything that chases an adorable fat Corgi around is pure win in my book!
Nice build. I might like to try this myself. Well, as long as I don’t need to buy a Corgi, too. My cats would surely take advantage of it.
Great work. Cute doggy :)
Corgis are necessary for the testing, no other breed would put up with it.
Hey, Wily Wampa,
How can I contact you!
I left you a message one day ago on the reedit pages where you discuss the new revision of your balancing 2 wheel robot.
Send me a PM on reddit. Comments on links don’t notify the poster with an orangered.
Very nice robot! I am biulding similar construction right now.
I have already built one prototype, but it turned out to be very heavy.
Can You tell me the diameter of these metal rods and thickness of acryllic plates that You used ? Your construction seems to be very light and stable.
The threaded rods are 8-32 and the acrylic is 3 mm thick. It still twists a little bit with the 8-32 rods, so that’s the minimum size if you’re making something on the same scale.
very nice job. Can you share arduino code ..?
http://dropcanvas.com/js85e
very nice work:) I want make a robot like this.
I have this items.
—-
arduino Uno and Arduino leonerdo
Pololu 12V, 29:1 Gear Motor w / Encoder
Pololu Wheel 90 x 10mm Black (Pair)
Pololu 37D mm Metal Gearmotor Bracket (Pair)
6 Degrees of Freedom ±2000° / sec ±16g IMU – ITG3200 / ADXL345
Arduino Motor Shield rev 3 and Pololu Dual MC33926 Motor Driver Shield for Arduino
—–
But I havent ”Pololu Dual VNH5019 Motor Driver Shield for Arduino” and ”Nyko Wireless Kama” .. I dont know very well write arduino code. So ı want use your code.
Can ı use motor drivers that I have.
And have any advaice wiresles control? . I get ardunio Jy-mcu bluettoh . and PS3 console.
I would be glad if you help.thanks
Would it be possible to share your Sketch ?