Using Loops to Repeat Robotic Actions
Robots and computers are very good at consistency when performing actions multiple times. Computers use repetition to perform millions of calculations per second with incredible consistency. Since robots are built to interact with their environment and perform tasks precisely, they can be effectively used to repeat behaviors.
Behaviors to be repeated are grouped in programming structures called loops. The number of times and how fast they repeat depends on many factors that the programmer can specify.
Here are some examples of where repetition can be useful:
- Performing routine tasks multiple times
- Checking certain conditions multiple times to check for changes