|
Re: Pin Point Robot's Position (GPS)
There are many ways to keep track of your position on the field.
The simple way is to measure how fast your robot moves and turns (feet per second and degrees per second for turning) and calculate where your robot is based on where you started, and keeping a running summation of all the commands (pwm outputs) you have sent to your motors, and the amount of time that has passed (SW loops).
This is easy, and its not very accurate (engineering tradeoff). Several teams used this method in the 'stack attack' game to hit the center of the wall as fast as possible in auton mode. In fact, the fastest robots used this method (ie: go forward for 1 second, turn left for 0.5S, go forward for 3 seconds...). If you are trying to hit a wall of boxes 12 feet wide you dont need mm accuracy.
Putting something on one of your wheels that counts revolutions is a more accurate way to measure distance travelled, as long as that wheel stays in contact with the floor and does not spin. Measuring the number of turns of wheels on both sides can be used to measure which way you are pointing.
You could also use the camera sensor to look for the beacon on the field, and use that to triangulate your position, esp if you can see both of them and measure your distance to one or both.
There are magnetic sensors you can get that allow you to measure the direction of the earth magnetic field. You have to place them on your bot where there is no steel or iron nearby, but they work pretty well. then you always know which way your bot is pointing, and these can be accurate to 1°.
accelerometers can be integrated to measure velocity (V=AT), and velocity can be integrated to measure distance (D=VT). This will work no matter what your wheels are doing (slipping, spinning, being pushed backwards), but its more complex and needs to be calibrated to get the best accuracy.
another way to figure out position is to sense the walls and railings and other objects on the playfield. If you keep a running estimate of where you think the robot is, you should know when to expect to run into a field boundary (instead of another robot), and you can use that information to increase the accuracy of your position.
you can get creative with the boundary sensors - simple: use contact switches that close when you bump into something, or more complex, like using an ultrasonic range finder to measure the distance to a boundary, or rotate it like radar to see whats all around your.
My favorite sensor is the yaw rate sensor. Its a solid state device that tells you how fast your robot is turning. This is very usefull for closed-loop steering control (another subject) but you can also integrate the yaw rate to get a compass (heading) reading.
Unfortunately, the best navigation system ever devised, GPS has two problems: 1. the accuracy is excellent for sailing across a lake or ocean, but +/- 2 or 3 feet is not that good for playing this game on the field, and 2. the signals are blocked by the roof of the arena :c(
|