Braking with an electric motor
A typical DC motor may be reasonably well modeled as an ideal motor in series with a certain amount of inductance and resistance.  An ideal motor will always have voltage across its leads proportional to rotational speed, and current flowing through it proportional to torque.  If a motor with frictionless bearings and 2.4-ohm internal resistance would have a no-load speed of 1200rpm at 12 volts, then such a motor rotated at 1200rpm would generate 12 volts.  If the leads are shorted, such a motor would have 5 amps flowing through it, and would generate 5 amps' worth of torque.

As a pretty good approximation, shorting a motor which is spinning at a certain speed will generate braking torque pretty close to what would be obtained by driving a stalled motor with the same voltage as the spinning motor would generate open-circuit.