Control & Navigation
Developed the robot’s autonomous navigation using feedback from inertial, optical, distance, and motor encoder sensors. The inertial sensor provides heading feedback for turning and straight-line driving. A PID controller was implemented to handle 90° turns, improving accuracy from approximately ±10° to within ±3°, which significantly helped reduce cumulative turning error.
During straight-line motion, the software continuously adjusts the left and right motor speeds to correct heading drift. The optical sensor identifies the target coloured stripe, while the distance sensor controls the final approach to the sorting box.
Motor encoders track how far the robot travels during each part of the route. After dropping off the object, the robot uses this recorded distance and heading feedback to retrace its path and return to its starting position. The code can be found on my GitHub.