The response of the system while performing the above
stated tasks can be divided into three regions with respect to
distance from obstacle as shown in Figure 4. The first region is
defined by obstacles at a distance greater than 40 cm, second one
by obstacles in a range of 25-40 cm from copter, the third and
the most critical one by distances in the range of 10-25 cm. In
the first region, the values from transmitter are directly fed into
the receiver. The second region prompts Arduino to call the
obstacle avoidance code, which de-accelerates the copter to
gradually stop, thus preventing the collision. In case, the deacceleration
is not sufficient to stop the copter before it enters
the critical region, jerk is increased to ensure that the copter
stops before hitting the obstacle.
Having discussed the concept and approach for preventing
collision, final algorithm/pseudo code, based on the
understanding of previous section, has been presented in the
succeeding section.