At the beginning of lab 9a, the group made a code that could approximately complete the task. However, during lab 9a, while testing the AEV code, it was found that the magnet attachment point on the AEV was not going to line up with the magnet on the load. The attachment point was on the wrongs side of the AEV. The attachment point, unfortunately, could not be simply moved to the other side of the AEV as this would position the load’s magnet too close to the Arduino. The group had to quickly redesign the layout of the AEV. Figure 1 shows the initial design (minus the servo) with the load attachment point on the wrong side. Figure 2 shows the updated design.
Figure 1: Original Design (Minus Servo)
Figure 2: Updated Design
Performance Test 1 involved the AEV having to successfully travel to the first gate, wait 7 seconds for the gate to open, and run until it is out of range of the gate’s second set of sensors. The code used to complete Performance Test 1 is as follows:
reverse(4); //motors go in proper direction
motorSpeed(4,35); //motors run at 35% power
goToAbsolutePosition(255); //goes to 255 marks
brake(4); //shuts off motors
rotateServo(110); //servo engages
goFor(9); //servo engages for 9 seconds
rotateServo(50); //servo disengages
motorSpeed(4,43); //motors run at 43% power
goFor(2); //motors go for 2 seconds
brake(4); //shuts off motors
goFor(3); //brakes for 3 seconds
Performance Test 1 was completed successfully.