Dock to battery charger

How to dock to a charger

First of all, we need to keep track of the battery level; as long as it is high, the robot should be carrying its routine tasks, but as soon as the level drops below certain level, the robot should switch to a charging routine.

As you remember from the previous project, our robot was just running circles between set of waypoints. When the battery drops, the robot should (from wherever it is) cancel its current navigation and go to a "charger waypoint", which is simply a waypoint located in the place from where a charger can be seen.

After the robot arrived to a "charger waypoint", it should do a 360 degrees turn, looking for an aruco marker (one that is attached to a charger). As soon as marker is found, robot stops rotating.

Then the robot should calculate distance and angle, and go towards the line that is perpendicular to it.

Next, the robot needs to turn 90 degrees to face marker. Now the robot can approach the marker at 90 degrees.

As robot moves towards marker, it should control the angle between robot's front vector and marker, and if for some reason (one tire is inflated properly, the other one is flat) it deviated from 90 degrees line, it should adjust its trajectory.

As our camera has certain min. range (in the camera.xacro it is currently set to 0.8 m), the robot should stop at this distance before the marker.

(C) snowcron.com, all rights reserved

Please read the disclaimer