Hello,
I have a clarification question regarding the Real Robot Project - Part 3 in the wall-following + odometry-recording action as
In my implementation, the action is supposed to stop once the robot completes one full lap and returns close to its starting position. This is done by monitoring the distance from the starting pose and stopping once it falls below a threshold (which is given in question as 5 cm).
However, during testing it in simulation, I noticed that, even with multiple changes to the code, issue is observability of the event by ROS server. Although the robot does physically cross the 5 cm region around the starting point, the algorithm often fails to capture that moment. I do not know if this happens cause of Odometry sampling, or something else.
I am not able to capture the condition distance_from_start <= 0.05 even though the robot has objectively completed a lap.
However, I increased the threshold to ~10–11 cm, while ensuring the action terminates only after a full lap and with this adjustment, the robot consistently completes exactly one lap and the action terminates correctly.
My question is:
Is using a slightly larger threshold (≈10–11 cm) acceptable for this Project,?
Or is the 5 cm value intended as a strict requirement rather than a guideline?
Thank you for your time.
Best,
Ninad Mehta