I am currently working on a project where a Pixy2 camera is used to make a 4WD robot follow a line. The way I am getting the robot to follow it is by looking at the vector of the line and if the camera is to the right of it the robot moves left and if its to the left the robot ,moves right. It just recentres itself.
Is there another way to do this line follower as when the robot gets to sharper corners the vector on the Pixy2 camera changes and the robot ends up turning around and going backwards.
Any help is apprieciated.