4WD vehicle arduino rosserial, pid, quadrature, encoder help
Hi, i have build a 4WD vehicle with rosserial controlled by a cmd vel topic the arduino due code uses the pid arduino library and quadrature encoder library along rosserial
my code : https://github.com/panagelak/4WD-drive-arduino-code-with-rosserial-encoders-pid
depedencies : rosserial https://playground.arduino.cc/Code/PIDLibrary/ https://github.com/zacsketches/Encoder
My problem is that if i rotate the robot and then stop it either with 'k' button or let it stop and then try to move forward the robot tries to Rotate as if the ''the pid is still active'' i cant seem to be able to reset the pid when the robot stops
I use the teleop node since the default teleoptwistkeyboard did some weird behaviour on my robot
Any advice on improving the robustness of my code welcomed
This code i hope can be used as a template to cheaply and easily control 4WD vehicles with encoders without bying extra encoder chips All you need is an arduino due and 2 L298N motor controllers
Thanks for your time!!
Asked by makemelive on 2019-08-02 06:48:01 UTC
Comments
That sounds more a question for your specific PID-Library then a ROS question. I would ask this question to the author of the PID library you are using. Your setup PID+rosserial+Encoder sounds well chosen.
Asked by Humpelstilzchen on 2019-08-02 07:21:08 UTC
uhm, I got a notification about a comment in this question, but I don't see any - makemelive, did you post one?
Asked by Humpelstilzchen on 2019-08-03 10:55:24 UTC