This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

disable PWM and Is and Vs

In order to make motor to stop completely, I call HAL_disablePwm().

What I have observed is the Is never gets to zero and the Vs goes up the Vdcbus value.

Is this normal?

Thanks.

  • hmmm, I don't think that's expected, would have to test myself.

    what lab are you using?

    are the values "freezing" at their last known state or actually changing?

    Actually, this may be expected. If you are turning off the PWM but still running the control system you will saturate out your Vs control, so I can see it going to the bus value (in per unit).

  • I am controlling the motor by using the Potentiometer on the kit.

    If the POT goes down to less than 3%t for example I shut down the PWM. And then turn on the PWM back when the POT goes up to more than 3%. Meanwhile, I did not shut down the CTRL.

    The Is jumps up very high when the PWM is turned back on even when I only allow a low speed in a duration of 1 or 2 secs. And when the Is jumps; sometimes my power supply strips and then the DSP is reset.

    If I do not turn on/off the PWM then the motor could hum at 0 rpm.

  • yes, your control system is saturating, so when you turn PWMs back on you get a "kick" as the control system is maxed out on its command.

    it's better to either try to control to 0 speed (though this can have drawbacks as well), disable the system using the flag, or create a "brake" function to turn all high or low side switches on so the motor acts as its own brake....if you do this you should reset the controller, or set the controller outputs to a determined level.

  • ChrisClearman said:

     create a "brake" function to turn all high or low side switches on so the motor acts as its own brake....if you do this you should reset the controller, or set the controller outputs to a determined level.

    1. How do I turn on all high or low side switches?

    2. How do I reset the controller?

    I could not figure out from the APIs.

  • By calling CTRL_setFlag_enableCtrl(), I can bring the CTRL and the EST to idle state and back online.

    The 'kick' is still there.

    Thanks.