Performance Tests

Group N’s Approach for Performance Tests:

Used the goToAbsolutePosition() function.

  • Limited the amount of testing needed if we were to use the acceleration function for the code

Used power braking

  • Limited the variation that coasting the AEV to a stop would cause
  • Used reverse and motorSpeed functions to power brake.

Test 1:

  • AEV must travel uphill to the first sensor in order for it to trigger the closed gate.
  • The AEV must stop before the gate between the sensors and pause for seven seconds in order for the gate to open.
  • Finally, the AEV must travel past  the opened gate.

Test 2:

  • Test 1
  • Once through the gate,  the AEV must safely travel down the system and connect with the load without recoiling from the loading dock.
  • The AEV must pause for 5 seconds in the loading zone and then leave the zone with the load attached

Test 3:

  • Tests 1 and  Test 2
  • After leaving the zone with the load, AEV must be able to stop again at the gate between the sensors, to trigger its opening.
  • The AEV must wait for 7 seconds for the gate to open and then travel back to the starting dock safely without recoiling out of it.

*AEV must achieve this with

~ minimal errors

~ a 2.5 minute time limit

~ space between magnet and Arduino

Code for Performance Tests:

// Performance Test 1

motorSpeed(4,50);       // Sets motor speed of all motors to 50%

goToAbsolutePosition(239);        // Goes to absolute position of 239 marks

reverse(4);         // Reverses all motors

motorSpeed(4,51);       //Sets the motor speed of all motors to 51%

goFor(.917);           //Runs at 51% for 0.917 seconds

reverse(4);          // Reverses all motors

motorSpeed(4,0);            //Sets the motor speed of all motors to 0%

goFor(7.5);                  //Runs at 0% for 7.5 seconds

motorSpeed(4,40);          // Sets motor speed of all motors to 40%

 

// Performance Test 2

goToAbsolutePosition(580);           // Goes to absolute position of 239 marks

reverse(4);              // Reverses all motors

motorSpeed(4,48);           //Sets the motor speed of all motors to 48%

goFor(1);            //Runs at 48% for 1 second

motorSpeed(4,0);           //Sets the motor speed of all motors to 0%

goFor(5.5);                  //Runs at 0% for 5.5 seconds

motorSpeed(4,60);                    // Sets motor speed of all motors to 40%

goToAbsolutePosition(500);           // Goes to absolute position of 500 marks

reverse(4);            // Reverses all motors

motorSpeed(4,75);                //Sets the motor speed of all motors to 75%

goFor(1.1);                //Runs at 75% for 1 second

// Final Performance Test

 motorSpeed(4,0);        //Sets the motor speed of all motors to 0%

goFor(8);            //Runs at 0% for 8 seconds

reverse(4);       // Reverses all motors

motorSpeed(4,34);                //Sets the motor speed of all motors to 34%

goToAbsolutePosition(150);      // Goes to absolute position of 150 marks

reverse(4);              // Reverses all motors

motorSpeed(4,60);            //Sets the motor speed of all motors to 60%

goFor(1);          //Runs at 60% for 1 second

brake(4);          //Brakes all motors

 

Data for Final Run:

Final Time: About 50 seconds

Energy: About 290 Joules

Cost of AEV:

Final Costs: