How to stop smoothly when using the Parallax Motor Mount and Wheel Kit with Pos
jmbertoncelli@USA
Posts: 48
Hello All,
I have a question about the Motor Mount and Wheel Kit with Position Controller, How to stop smoothly when an object has been detected in front of a robotic rover?· Let say that you have a rover with·a sensor(s) that is giving you the distance·to an·object for your rover to avoid then what should be the right command(s) to send to the position controller to stop smootlhy few centimeters or inches before to colide with the object??? I know that that I can use the clear position command but that is all but smooth... What from your point of view should be the best option to manage this process?
thanks.
jm.
I have a question about the Motor Mount and Wheel Kit with Position Controller, How to stop smoothly when an object has been detected in front of a robotic rover?· Let say that you have a rover with·a sensor(s) that is giving you the distance·to an·object for your rover to avoid then what should be the right command(s) to send to the position controller to stop smootlhy few centimeters or inches before to colide with the object??? I know that that I can use the clear position command but that is all but smooth... What from your point of view should be the best option to manage this process?
thanks.
jm.
Comments
Another way is to simply switch the motors off when they reach the threshold distance and let them free wheel to a stop. Sounds simple, but if the robot is very light it will still stop suddenly, especially if the robot has soft tyres or is operating over a soft surface. The trade off is that it saves power. If the mass of the robot and its payload doesn't change, and it only operates over smooth, hard surfaces, it shouldn't be too much of a problem.
A third method is to thow the motors in reverse. This might sound strange, because you'd expect it to bring the robot to a sudden stop. Whether it does or not will depend on the mass off the robot, its velocity at the time, and how long the braking force is applied for. The drawbacks are that it wastes a lot of power, and it risks damaging the motor and gearbox. However, controlled braking (e.g. pulsing the motors in reverse) can be very useful in certain situations. Trying to stop a forward moving robot on a downhill slope is one example.
based on the documentation:
"Then it uses the current average speed to calculate the distance required to decelerate smoothly to the
final end point without overshoot. When traveling in one direction, if a new position advancement value
requires the wheel to reverse direction, it will still decelerate smoothly to a stop at the user-set ramp rate
before re-accelerating in the opposite direction toward the new end point."
If we can QUERY the current position (QPOS) then we know the current POS then if we * by -1 the current POS and set the new TRVL with the new current POS that should stop the robot... however there is still and unknown how many POS the robot will still travel before to stop related to the speed and ramping down rate...???
based on the documentation:
"Sending a command to travel 0 positions is a special case used to bring the wheel to a
smooth stop when traveling. The current speed is decelerated at the speed ramp rate and
the end point is advanced to the exact location where the speed will reach zero. Note that
this special case is not considered accumulative and will override the previously remaining
distance to travel. However, TRVL commands sent after this will be accumulative as
expected."
Can we compute what is the maximum distance before that the robot stop related to the speed and ramping rate...??? If yes my problem is solved I just have to set my obstacle detection subsystem with the right distance + a cushion.
thanks
jm.
Just in case, keep that baseboard touchup paint handy!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
·"If you build it, they will come."
jm.