You are here

Motor braking - shorting phases

10 posts / 0 new
Last post
rok340
Offline
Last seen: 1 year 1 month ago
Joined: 2021-01-05 08:50
Posts: 5
Motor braking - shorting phases

Deal All,

 

I have a question regarding motor braking using VESC.

Is there a way to brake the motor with shorting the motor phases? In my application the returning of energy is not possible. Also the braking time has to be as short as possible.

Motor is running freely with no load so it has low inertia.

Thanks.

 

Regards,

Rok

 

vadicus
Offline
Last seen: 1 month 3 weeks ago
VESC Free
Joined: 2018-08-17 07:26
Posts: 431

Looks like all you need to implement brakes by means of phase shorting is already in the code:

https://github.com/vedderb/bldc/blob/3a071cee2f76db24308a9fb00b7d7482748...

But you have to consider the safety aspect of it. Shorting phases at full speed can be deadly on a vehicle for example. 

 

 

 

 

NextGen FOC High voltage 144v/34s, 30kw (https://vesc-project.com/node/1477)

rok340
Offline
Last seen: 1 year 1 month ago
Joined: 2021-01-05 08:50
Posts: 5

Thanks.

dpeinado
Offline
Last seen: 15 hours 47 min ago
VESC Free
Joined: 2022-01-14 11:59
Posts: 19

Hello,

Some time has passed from the last reply, but I'm doing exactly the same. How can I use that part of code to implement a short between phases in my logic? As Vadicus points, I should apply current brake, read rpm, and when rpm approx 0, then short circuit the phases.

But how do I do that? The code in "mcpwm_foc_adc_int_handler", is 

// When the modulation is low in brake mode and the set brake current
        // cannot be reached, short all phases to get more braking without
        // applying active braking. Use a bit of hysteresis when leaving
        // the shorted mode.
        if (motor_now->m_control_mode == CONTROL_MODE_CURRENT_BRAKE &&
                fabsf(motor_now->m_duty_filtered) < conf_now->l_min_duty * 1.5 &&
                (motor_now->m_motor_state.i_abs * (motor_now->m_was_full_brake ? 1.0 : 1.5)) < fabsf(motor_now->m_iq_set)) {
            control_duty = true;
            duty_set = 0.0;
            motor_now->m_was_full_brake = true;
        } else {
            motor_now->m_was_full_brake = false;
        }

 

But how I do activate that part?

Sorry for how naive it sounds, but I can not see how to use it.

 

Thanks, in advance

frank
Offline
Last seen: 3 weeks 6 days ago
VESC BronzeVESC FreeVESC GoldVESC OriginalVESC PlatinumVESC Silver
Joined: 2016-12-27 20:19
Posts: 847

The energy has to go somewhere and can't be stored in the universe. Shortening the phases means max torque braking and that will generate quite some amps and heat. The best way to achieve braking in such a system is a big resistive load to push the energy into. So you basically push the energy into heat.

 

j.konrad
Offline
Last seen: 1 year 5 months ago
Joined: 2022-01-06 15:43
Posts: 40

Perhaps the Maximum Power Transfer Theorem would be helpful here to choose an appropriate load impedance.

https://en.wikipedia.org/wiki/Maximum_power_transfer_theorem

Also @dpeinado if you are trying to use the motor as a brake at 0 rpm, research the technique of DC injection into an AC machine.

dpeinado
Offline
Last seen: 15 hours 47 min ago
VESC Free
Joined: 2022-01-14 11:59
Posts: 19

Hello, thanks @frank and @j.konrad for your comments. As I understand them, you both suggest that I should add an external resistor to dissipate the energy produced in the braking process. The value of the resistor should be equal to the internal resistance of the motors (thanks to @j.konrad for the reference). I should also design an external circuit so the inverse current to battery would be diverted to this resistor.

In the braking process there is no much heating so I think I can leave the system as it is. The problem is to retain the vehicle when rpm = 0. The DC injection is effective (handbrake vesc function) but is not very efficient, it consumes around 20Amps to fix the vehicle.

I was wondering if there is another system to prevent the vehicle starts moving from stopped state, and this system does not consume a lot of amps. Thats why I asked for the phase shorting. Of course, if it has to work a lot, then there would be a lot of heating as you both has pointed out, but I do not know if it can stop a vehicle without too much heating (and battery consumption)

Thanks both of you for your comments.

j.konrad
Offline
Last seen: 1 year 5 months ago
Joined: 2022-01-06 15:43
Posts: 40

Regardless of the load resistance (from a dead short to open circuit) you will see little or no braking effect near 0 rpm.  But you may be able to keep the vehicle "parked" with a DC injection current of much less than 20 A.  This will depend on a lot of a factors, not least of which is the overall gear ratio of your drive mechanism and wheel diameter.

Using load resistors equal to the motor phase resistance may not be optimal for your application, but you could do much worse.

Maybe a mechanical "friction band" actuated by a pull solenoid could serve as a parking brake?   Electric parking brakes in automotive applications use a small servomotor to clamp the brake pads against the brake disc.

frank
Offline
Last seen: 3 weeks 6 days ago
VESC BronzeVESC FreeVESC GoldVESC OriginalVESC PlatinumVESC Silver
Joined: 2016-12-27 20:19
Posts: 847

The only way is active braking with current injection and that is not really an option for parking. Typically you need extra brakes for parking.

dpeinado
Offline
Last seen: 15 hours 47 min ago
VESC Free
Joined: 2022-01-14 11:59
Posts: 19

Thanks again both @frank and @j.konrad. Yes, after your comments and some search I've arrived at the same conclusions. The electrical parking brake of cars is something I'm looking for, but bike version. I've not found it yet. I'm also considering bistable solenoids to save battery. Thanks again, regards.