StatCounter

Thursday, April 3, 2014

In robotics, making a precisely straight robot or a precise 90/180 degree turn right/left can be challenging, especially if you are using trial-and-error to figure out how long to turn the robot. There are some methods to do improve accuracy:




Trial and Error, without sensors
Gyroscope Sensor
Odometry/Wheel Encoder Sensor
Simplicity
Easy, just play with
delay values
Medium-Hard, may require
knowledge of  i2c/spi
protocols and/or reading the sensor datasheet, expensive ~$20-40
Medium, may require basic geometry in measuring angles, coding is straightforward. ~$5-20
Accuracy
Unaccurate,
speed changes
 when voltage drops
Accurate, relies on the inertia of a spinning
disk called a gyro
to measure the angular velocity.
During drift, it finds the angular displacement and auto-corrects to
 the original angle.
Accurate on 90 degree/180 degree turns with right wheel diameter/chassis diameter calculations, but can't be used in moving
forward because of drift.
Pros
Easy-to-code
Accurate on both straight and degree turn robots
Moderately inexpensive, accurate degree turn 
with correct geometry,
straightforward coding.
Cons
Requires a lot of adjustment
when the  voltage
 drops to match speed
Requires some intermediate coding skills, and is costly.
Doesn't sense drift!




Each has its own advantages, but I will use the gyroscope method in my future robot posts, because it is accurate in both going forward as well as 90 degree turns. Unlike odometry, which only senses the turns the motor traveled for each wheel, I could compensate for the angular drift when moving straight, because the gyro knows the difference between now's angle and the angle we started with.

No comments:

Post a Comment