Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Nifty balancing robot

Status
Not open for further replies.
It looks like fun.

I noticed the author used a lot of floating point math in the code. It would be interesting to see if one could use integer math instead. Also said several things were on the edge of just good enough to make it work. Interesting.

EDIT:
One of the limiting factors is the response time of the IR distance sensor, about 39 ms (25 MHz). Sharp makes similar sensor with a range of 20-150 cm with a response time of 16.5ms (60 MHz). About 2.5 times faster. DigiKey has it for about $50. 425-2499-ND
Not sure if the range would reduce the resolution too much. Sharp also has one with the same speed and a detection range of 4-30cm. 425-2498-ND

The location of the battery pack is interesting. If it were mounted closer to the center of rotation it would take less motor torque to make corrections. But as it is it provides some resistance from movement. Not sure.

Just the same the guy did some neat stuff here.
 
Last edited:
It's made me wonder if I could glue a breadboard to a Tamiya double gearbox and use a 2 axis accelerometer in inclinometer mode to achieve the same effect. I might just have a play with that idea.

@3v0, do you think the high battery pack would slow down the system in a similar way a long pole does with a tightrope walker?

Mike.
 
Pommie said:
@3v0, do you think the high battery pack would slow down the system in a similar way a long pole does with a tightrope walker?
Mike.

Yes. But it also has the disadvantage that it requires more motor torque to make corrections.

Think about the two extreems. The first is like the equibot. It has a large mass that must be ballanced high above the wheels. On the other extreem would be a system with the center of mass below the wheels like a tight rope walker using a pole with weights that hang off the end of the pole below the rope.

The first is hard to ballance, the second ballances by itself. In between there are shades of grey. At some point there should be and ideal setup for the double gearbox.

The author said that his sensor was nearly too slow. I think the first order of buisness would be to get the sensing rate (corrections per second up).

I am a bit out of touch (green) on the sensor bit. How would the use of a gyro compare to that of an inclinometer. Does it just come down to whichever has the best sample rate? resolution?
 
I wonder if changing to a low gear ratio would make any difference, less gear lash at the least. I do like the simplicity of using a IR distance sensor facing the floor.
 
I do like the simplicity of using a IR distance sensor facing the floor.

Not to mention the cost. I was placing a parts order when you first posted about this so I tacked on a IR distance sensor. :)

As long as the robot is moving the lash should not have much effect. The only time it will come into play is when the robot is standing in one spot. Then it is leaning first left then right. But that should also be where you have the most time to teact because the mass is very nearly always directly over the axle.
 
3v0 said:
Think about the two extreems. The first is like the equibot. It has a large mass that must be ballanced high above the wheels. On the other extreem would be a system with the center of mass below the wheels like a tight rope walker using a pole with weights that hang off the end of the pole below the rope.

I think of it more like balancing a broom on my hand. The longer the broom the more time I have to move my hand underneath it. His low rate of sensor reading may be the reason that he has the batteries high. Maybe someone should mail the owner of equibot and ask what effect moving the batteries has.

I have a ADXL202 on a breadboard that I could use as an inclinometer. By comparing the X & Y readings and doing a little maths, you can work out the angle of the chip. Knowing this angle should be enough to make a balancer as long as it doesn't change speed fast.

Mike.
 
Pommie said:
I think of it more like balancing a broom on my hand. The longer the broom the more time I have to move my hand underneath it. His low rate of sensor reading may be the reason that he has the batteries high. Maybe someone should mail the owner of equibot and ask what effect moving the batteries has.

It will take longer for a tall poll to fall over but it does not matter how much weight you have on top of the poll. Feather rock sort of thing (ignore air friction).

With the robot, the further up the "center of mass" is from the axle the harder it is to make a correction. If the battery were at the top of the robot and it dropped an inch the motor would have to lift the pack an inch. If the pack were at the axle it would not drop at all.

I could be wrong.....

EDIT:
Mass about the axle is a ying-yang sort of thing. On the one hand it would seem to make the robot more stable. One the other needed corrections become more costly.
 
Last edited:
3v0 said:
It will take longer for a tall poll to fall over but it does not matter how much weight you have on top of the poll. Feather rock sort of thing (ignore air friction).

However, the pole will rotate about the center of mass. In the robot scenario the center of mass will tend to stay still while the wheels move underneath it.

Mike.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top