Page 1 of 1

BrakingStrength on DC Motor Phidget

Posted: Wed Jun 22, 2022 9:20 am
by Wolfpack34
How exactly is braking implemented on the phidget? It looks like the braking strength is a value from 0 to 1 with it ramping based on the acceleration parameter.

To my understanding, typically you would short both terminals of the motor to ground for hard braking. Does this parameter tie one of the motor connections to ground by opening that low-side fet and then throttle the duty cycle of the other low-side fet from 0 to whatever is specified by the setBrakingStength?

As implemented, when you set a braking strength the motor is being braked whenever a velocity is not set, correct? So if you only want to brake the motor for 1-second after you tell it to stop then you would set the braking strength to some value while it's moving and then 1-second after you set the velocity to zero you can set the braking strength to 0 to allow it to free-wheel. Correct?

Re: BrakingStrength on DC Motor Phidget

Posted: Mon Jun 27, 2022 10:26 am
by jdecoux
As implemented, DC Motor baking strength only applies when Velocity = 0

The velocity parameter is a target duty cycle, which will by definition apply power in one direction or another when Velocity is non-zero.

Braking Strength is the fraction of time the motor will be shorted to itself once it has decelerated to a velocity of 0 (assuming current limits are not exceeded).

Setting braking strength to 0 will indeed allow the motor to freewheel once it decelerates to a "Velocity" of 0.