Motor Control - Brake vs. Float
Any time you are running a motor you want to be able to stop it. There are two traditional ways of stopping a motor; brake and float. The end result is basically the same but it is how the motor is stopped that is the difference. I will diagnose the differences and provide you with a better understanding of how to get your motors to stop best for your situation.
When a motor is stopped using the float method, power is simply removed from the motor. The will slowly come a complete stop. Once stopped, the motor can normally be turned easily with the only resistance coming from friction inside the motor or gears. This method is to be used when precision is not a necessity.
When a motor is stopped using the brake method, power is quickly reversed and the motor will stop abruptly. Once stopped the motor enter either a float state or a hold state depending on the motor control device and the software. Many of the motor control options from mindsensors.com will allow to brake or brake hold. If the brake hold method is used the motor will stop abruptly and hold that position. Even if you are able to move the motor slightly, the motor will quickly move backed to its original stopped position. Brake methods can be used anytime, but especially if precision is expected.
It is important to remember the properties of the programming language, environment, motor controller, and or motor controller libraries. Some allow for proper timing of each function and will handle each command, then move to the next command. Keep in mind all are not like this. It may take a few milliseconds for a function to run, send the command to the motor controller, and physically execute the operation. In some scenarios, if you brake the motor for precision and immediately run a float command, the motor float command will overwrite brake command too fast to execute the brake and you will not achieve the desired precision. This can happen even if the float command is not in the same function. This usually occurs is fail safe stops and exit codes.