Robotics StackExchange | Archived questions

How to keep rc-car inside lane after lane detection

Hi, I am working on keeping my RC car between 2 lines inside a circuit track. I'm using a monocular camera (raspicam v2) and a raspberry 4B.

After performing some sort of lane/lines detection with opencv, what could I do to keep the car inside the lane??

Any info is welcomed.

Thank you!

Asked by MrRivi on 2020-09-09 03:58:38 UTC

Comments

Answers

You can check this https://stackoverflow.com/questions/22470902/understanding-moments-function-in-opencv#:~:text=Definition%20of%20moments%20in%20image,center%20of%20mass)%20of%20image.&text=Here%20you%20can%20read%20the,They%20are%20called%20raw%20moments.

understand OpenCV moments function and than get and error value from distance to center. And try to process it in PID or PI or P

Also you can check ball chasing with donkeycar build.

Asked by Morgenstern on 2021-01-19 16:13:21 UTC

Comments