Reflectance Sensors

Reflectance sensors properly supported on AEV:

The Reflectance Sensors is created using sensors that detect low output voltage and records it as a “mark” As the wheels on the AEV have reflective tape, the sensor detects the “low output voltage” as an indication of greater reflection from the tape. The program then records the amount of marks in an allotted time which using basic math can be converted to a distance. Each 8 marks indicates a full wheel revolution, and using the arduino the AEV can be programmed to move a certain amount of marks or revolutions on the track. Therefore the main function of the reflectance sensors is to convert movements from the AEV into a programmable variable that can be manipulated by the students to finish objective and functions designated by the company.

 Reflectance Sensor Code:

//REFLECTANCE SENSORS
//1) run both for 25% for 2 secs
motorSpeed(4,25);
goFor(2);
//2) fun at 20% absolutefunc to travel 12 feet
motorSpeed(4,20);
goToAbsolutePosition(70.2);
//3) reverse motors
reverse(4);
//4) run all motors 30% for 1.5 sec
motorSpeed(4,30)
goFor(1.5)
//5) brake all motors
brake(4);