Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deceleration control #3

Open
David9696 opened this issue Aug 5, 2019 · 2 comments
Open

Deceleration control #3

David9696 opened this issue Aug 5, 2019 · 2 comments

Comments

@David9696
Copy link

Hi,

The deceleration of the controller seems not in place. The robot would just freely roll until it stops when zero velocity is sent. Is it possible to set the deceleration?

Thanks.

@roaldlemmens
Copy link
Owner

Hi,
Currently if velocity is 0, the motors are released. This was done intentionally to allow the robot to be moved manually and safe some power. I have implemented PID control (see branch feature/duty_cycle_pid) which improves control. If you add velocity_smoother you will get smooth deceleration. For a project I'm working on I set the decel_factor to 0.6 to have a longer time to stop, which is convenient when the robot is travelling with a high load.

But it could also be useful to have active braking, see issue #1

@David9696
Copy link
Author

Hi,

Thanks for your reply. Totally agree that the motor release can save some power. However, if the robot is moving on a ramp and stop, then releasing the motor might not be a good behavior as the robot might fall down. Hence, active braking might be a better choice. I am not very good in programming. If you can guide me where to work out the active braking, I am more than happy to help.

Also, I have tried the duty_cycle_pid branch. Indeed, it is a very good work. The robot control becomes much smoother and responsive. Good works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants