Extended AEV Library


Overview

When the team was introduced to the AEV_Controller software package it quickly became apparent that the existing code was extremely limited in scope. Initially conceived as an additional library to enable access to time data, the Extended AEV (EAEV) Library has since evolved into a powerful addition to AEV_Controller that can calculate velocity, acceleration, and run limited physics simulations. It is centered around a specialized class called smartGoToAbsolutePosition that enables the AEV to calculate the optimum time to run the motors to reach a specific position.

Theory

The EAEV class focuses heavily on the application of basic kinematics equations to the current AEV state. The following simplifications to the AEV physics model are made to minimize the computational strain on the Arduino:

  • AEV powered acceleration is constant
  • AEV experiences no aerodynamic drag or friction between tracks and wheels
  • When unpowered, the AEV experiences a constant deceleration

Given these simplifications, the following kinematics equation can be used:

This equation is applicable only when acceleration is constant. However, under the aforementioned state simplifications, the AEV will experience two different accelerations. However it would be clumsy to have to use two separate equations to calculate the optimum motor run position. So instead a modified equation will be used that allows the AEV to determine its final position if it were to stop the motors at the moment of calculation:

Which can be simplified by inputting the known final velocity of 0 m/s:

These equations can be used by the AEV to calculate how long it needs to propel itself in order to coast the rest of the way to the target position. This is advantageous because it allows the most energy-efficient motor speed to be used exclusively. It also allows the AEV to avoid wasting energy braking, either by using a servo to physically brake or by using the propellers to perform an engine brake. While this could hypothetically be accomplished by guessing the absolute or relative positions needed to coast to the target position, doing so is a slow and inefficient process that is likely to produce inconsistent results. Moreover, providing the AEV with these computational abilities has a significant advantage over the trial-and-error method: the AEV can monitor its projected stopping point as it coasts. This would allow it to make a corrective maneuver if it predicts it will not stop at exactly the intended position. While doing so would lower the energy advantages this method has over the traditional ones, it would still produce noticeable energy savings.

Thus the optimal AEV motion sequence would be as follows:
–Insert AEV motor run, coast, and corrective maneuver diagram here–

Implementation

In progress…