Basic Function Calls:
Function Call |
Function |
Example |
celerate(m,p1,p2,t);
|
Accelerates or decelerates motor(s) m from start speed (%) p1 to end speed (%) p2 over a duration of t seconds
|
celerate(1,20,45,2);
Accelerates motor 1 from 20% to 45% power in 2 seconds
|
motorSpeed(m,p);
|
Initializes motor(s) m at percent power p
|
motorSpeed(2,16);
Sets motor 2 speed to 16% power
|
goFor(t);
|
Runs the motor(s) at their initialized state for t seconds
|
goFor(5);
Runs the motor(s) at their initialized state for 5 seconds
|
brake(m);
|
Brakes motor(s) m. Note: This does NOT brake the AEV, just stops the motors from spinning
|
brake(4);
Cuts the power to all motors
|
reverse(m);
|
Reverses the polarity of motor(s) m
|
reverse(1);
Reverses polarity of motor 1
|
goToRelativePosition(n);
|
Continues the previous command for n marks from the vehicle’s current position. n can be positive or negative, with positive meaning the vehicle is moving forward, negative meaning the vehicle is moving backward
|
motorSpeed(4,20);
goToRelativePosition(30);
All motors are set to 20% power, and they will continue to run at 20% power until the AEV reaches 30 marks from its current position
|
goToAbsolutePosition(n);
|
Continues the previous command for n marks relative to the overall starting position of the AEV
|
motorSpeed(4,20);
goToAbsolutePosition(300);
All motors are set to 20% power, and they will continue to run at 20% power until the AEV reaches 300 marks from its starting position
|