EdVenture 5 – What IF?
Give Edison the power to make decisions
The introduction said that a robot can think or make decisions on its own and act on those decisions. Well, now were going to see how that happens using the IF icon.
Create the program and download it to Edison. Place him next to a thick black line on a white surface and press the play button. He will follow the line.

How the program works
The first thing the program does is turn on the line tracking LED. Next, the program enters an endless loop. In the loop is the, all important, IF icon. The IF icon asks: Is the line tracker on a reflective surface (white)? If the answer is YES, then the program follows the tick path out of the top of the IF icon. The dual drive icon turns Edison right. This drives him onto the black line. But, if the answer is NO, then the program follows the cross path out of the bottom of the IF icon. This dual drive icon turns Edison left and drives Edison off the line. The program then loops around again, and again, and…
Edison is in a constant battle with himself. When he’s on the line, he wants to get off it. When he’s off the line he wants to get on it. Frustrated movement by movement he moves forward.
EdFact
This program is very simple, but demonstrates the principal of ‘artificial’ decision making (intelligence). Scientist still don’t fully understand how the human brain works and are now using computer scientists to help make sense of their research. Do you think your brain is a giant computer?