Arduino Basic Codes

 

Function Call Function
celerate(m,p1,p2,t); Accelerates the the (m) number motor from percent (p1) to percent (p2) power in (t) seconds
motorSpeed(m,p); Keeps the (m) number motor at percent (p) power
goFor(t); The previous function will last for the (t) seconds in this function
brake(m); Will cut power to the (m) number motors, causing the propellers to come to a stop
reverse(m); Will reverse the polarity of the (m) number motor, causing the propellers to slow to a stop, and if power is supplied will spin in opposite direction
goToRelativePosition(n); The previous function will run for as long as the AEV takes to reach (n) marks from when the command is called upon.(Positive means the vehicle is moving forward, and negative is backwards)
goToAbsolutePosition(n); Continues the previous function for (n) marks relative to the starting position of the AEV