<< return to Pixycam.com

Line tracking mode - 90º Curves - Problem

Hey There!

I’m working on line follower robot. During the tests, I’ve realized that when it faces 90º curves the vector points to the wrong direction. It points down, rather than the correct direction.Is it normal behave of the line tracking API or it’s just a problem on the parameters tunning?

Best Regards


In general, the line following algorithm will treat “elbows” as lines and not intersections since there is no branching. If the vector is pointing down, it either chose incorrectly upon acquiring the line, or it was a continuation of the previous vector. You can call reverseVector() to flip the vector if you like.



According to the text in the motor control section of the line_zumo_demo.ino program, the Zumo Robot will attempt to backup if the line vector points down:

else // If the vector is pointing down, or down-ish, we need to go backwards to follow.
left -= ZUMO_SLOW;
right -= ZUMO_SLOW;

Maybe the Line Following app can be updated to use the barcodes to turn right or left at “elbows” as it does with intersections?


You could make a zig-zag line and Pixy will just draw a straight line through it because each zig and zag isn’t an intersection. You can only turn at intersections (where the line branches).

One advantage of using a camera for line following is that you get a complete image of where the line is headed. Most robot line followers are only looking at a very tiny image to determine where the line is going – those robots will zig and zag as the line does, and it’s difficult for these robots to determine if there is an intersection.


1 Like

Can you please release a firmware with 90 degree turns (elbows)?
Pixy cant detect elbows or detects wrong vectors.

1 Like