Following the last post, I took the robot out to the stadium to check how it performs.
How I transformed an IR sensor into an encoder, that enables the calculation of speed and distance.
PID is finally starting to work. Apparently the last issues were not entirely caused by bad tweaking but by “bad” coding as well. Continue reading “PACERBOT Part 16 : Algorithm talk”
Some footage of the robot running in the stadium. The process of tweaking the PID values is tricky. Even after a long time working on these values, I have given up (for the day!) and stayed with slow speeds, which are easier to work with.
Measuring speed can be done in many ways. I chose to build an optical encoder, to sense the frequency of the drive shaft’s revolutions, and calculate the speed by recording the time between pings.
A peak into the PID tuning process. A good demonstration of the various effects changes in the parameters have on the behavior of the robot.