anoff / robby5

autonomous robot car 🤖🚗
MIT License
17 stars 5 forks source link

Odometry without Encoders #2

Closed guilyx closed 4 years ago

guilyx commented 4 years ago

Hey,

Trying to upgrade an Elegoo car kit with a RPi and ROS, and I'm currently developing the arduino firmware. I've done it before with motors with encoders to get the odometry, but right now with only a way to control the speed of the motor and the way of the spin, can't figure how to get an an odom. Sounds like you've done it anyway, but can't figure out how, if you could help/explain/highlight, would be quite cool !

Thanks

anoff commented 4 years ago

Hey @Guilyx, sadly I haven't figured out odometry either.

See my notes on the default motor setup and localization. It has been a while but I played around with cheap MPUs for accelero/gyro based odometry which turned out really bad but I haven't invested a lot of time into proper signal processing. With the stock motors there is no way you can do proper odometry because the speed is not stable enough. The motors do have a mounting point for encoders though. The only issue I had was that my 4x4 setup did not allow for much room to install them and I would have to remove some parts of the chassis to mount the encoders correctly. But even with the encoders you still have the issue of rotation for which you might need a yaw rate sensor (MPU).

Hope that helps.. In which project are you solving this? Would be interested in following up on whatever you build :)

guilyx commented 4 years ago

Hey,

Sorry for the delay. I'll check if I can mount encoders on my motors.

It was a Christmas Gift to a family members and they wanted me to check if it could be upgraded to be more reliable. Here's the empty repo : elegoo-arduino-firmware The wheels have little to no adherence, there's a lot to fix on the robot right now. There's that to fix. As for the speed unstability, I was hoping to fix this AFTER solving the odometry problem using a PID Controller. ( Only PI might be required )

For now I'm only studying my options. I've done it from scratch with encoders once here with four peers if you want to check it out.

Thanks for your help, I'll give you updates if I find anything relevant and satisfying to solve the issue.

anoff commented 4 years ago

these encoders fit the yellow motors so you only need to glue the PCB with the laser sensor somewhere on the chassis