Errors in Wall Avoidance example code

The Wall Avoidance example code has an error that prevents it from compiling as observed here.

Wall_Avoidance.ino: In function ‘void loop()’: Wall_Avoidance:10: error: ‘GREEN’ was not declared in this scope Wall_Avoidance:17: error: ‘RED’ was not declared in this scope

On line 11, the GREEN constant requires RGB_ prefix

On line 17, the RED constant requires RGB_ prefix

The same error is present in the explanation of the code that appears earlier on the page.

In addition the example code included with the library is missing the first line in the loop function:

The impact of this is that sparki only moves backward :unamused:

I really appreciated the examples of when the ultrasonic range finder may fail to detect an object. I observed this because sparki was turning only 15 degrees each time instead of the 30 degrees suggested by the comments. The Turning real degrees and moving given distances provides more detail on this. What this behaviour does provide is an opportunity to improve the algorithm by handling the case where the wall is at an angle.

Fixed the example, thanks for pointing it out!