The Subalgorithm flowcharts

Subalgorithm Pot0
This subalgorithm is the main part of the program. It will govern Vertigo passed all the obstacles to the top of the wall. Vertigo's actions depend on the output signals of the sensors. Depending on which sensor and how many of them become active, Vertigo will react by turning, backing up, moving forward etc. For example, when a white object is detected, Vertigo will make a 90 degrees turn, move forward and correct his orientation until he is in his original orientation again.
Since speed is one of the important judging parameters of the Clawar competition, we tried t develop an algorithm that will give the fastest solution in every situation. As a result, this algorithm is quite lengthy, due to the numerous possible situations. The basis is the always the same. When a light sensor detects an object, Vertigo will turn, move forward, and turn again, to avoid it.

 

Subalgorithm Pot00
This subalgorithm kicks in when Vertigo's orientation is sideward, so facing a side of the wall, instead of the top. In case of Pot90, Vertigo is facing the right side of the wall. The robot will move forward just a little and try to turn to face the top again. If he detects an object before completing this cycle, he will turn 180 degrees, move forward and start the procedure again.

 

Subalgorithm Pot-90
This algorithm is almost identical to Pot90. The only differences are the orientation and the way of turning.