What's a good way to stop Magni?

Suppose I have a Magni driving happily along at 0.2 m/s, and at some point it notices something and I want it to stop right there. How do I do that? If I just send a zero Twist to cmd_vel it continues to roll for quite a bit.

Well the stopping distance is limited by the acceleration and jerk limits. They definitely are there in the motor node and may also be there in whatever application you are using to control the robot. You can make the acceleration limits less strict and thus enable faster acceleration and stopping - however bear in mind the mild mannered acceleration and deceleration you see with the default configuration is not because the robot has limited power - its because of the acceleration limits, ditto stopping. With no acceleration limits its easy to make the robot do wheelies flip over etc. If the robot is carrying a payload that raises its center of gravity a sudden stop will definitely cause it to tip over. Its also a lot easier to crash the robot in to walls and people and generally do damage - please be careful.

As a note most people want mild mannered acceleration but a rapid “stop” - we’ve opened a ticket to implement this by default - at least for teleop. You can actually see this ticket here:
https://github.com/UbiquityRobotics/ubiquity_main/issues/148

Bear in mind that you need to adjust acceleration limits for all parts of your control stack. To adjust acceleration limits for the motor node look at the documentation here: