"Follow Me" for GoPiGo

While I have known it should be possible to use the PiCamera and OpenCV to command the GoPiGo3 to “Follow Me” by putting a specific color/shape or an AprilTag on my belt, I never got around to giving it a try. The thought was to use the vertical position in the frame to estimate the following distance for motor speed commanding, and use the left/right position in the frame to command the bot rotation/turning.

My first experiment with the Oak-D-Lite sensor is going to use a “human detector” and the “depthAI” to implement the “follow me behavior”.

I’m thinking to start the behavior when a human steps into the center of the field of view at a preset follow-me distance - Change WiFi LED color from Red to Green for “GoPiGo3 Ready To Go”.

Then translate Z change magnitude to speed, and X or Y change for turn commands (not sure if X is left/right and Y is climbing a ladder or vice versa.).

I can’t figure out how to stop the behavior though; If it was Carl, I could just say “Hey Carl, Get Lost!”

2 Likes

I think X would be left/right
/K

2 Likes

That’s the way it is on my joysticks.

X is roll, y is pitch and z is yaw.

2 Likes