Hello,
I want to switch on and off the FET pre-drivers in order to reduce the current. My code is :
if(PTT_PTT1)
{
PMFENCA_PWMENA = 0;
}
else
{
PMFENCA_PWMENA = 1;
}
if I clear the PMFENCA_PWMENA bit, the PMF can work well after set the PMFENCA_PWMENA bit.
I also find this in the RM,but I do not understand.
Any idea?
Thanks!
Hello,
You can mask and unmask the PWM channels using PMFCFG2_MSK[5:0] bits (please see Figure 15-41 RM rev. 2.11)
or disable the PWM generators by clearing PWMENx. That is up to you.
Regards,
Daniel
Thanks,Daniel
If I clearing PWMENx, it will not work well when I set PWMENx again. There is no output on PWM channel.
Now, I use the Timer0 interrupt to check the input square wave's duty. If the duty under 10% , I will close the motor. Meanwhile, I want to reduce stand-by current. If the duty up 15%, it will restart the motor. I disable the GDU and PMF by PMFENCA_PWMENA = 0; &GDUE_GFDE = 0. But when it restarts the motor ,there is no output on PWM channels. I enable the GDU and PWF when it restarts.
What can I do to disable the GDU and PMF if I don't use it? OR is there other way to reduce the stand-by current?
Regards,
Frank
Hi Frank,
Can you check PMF and GDU fault registers before you enable the PWM generators again?
Thanks,
Daniel
Hi Daniel,
It doesn't work, I have check PMF adn GDU fault registers before I enable the PWM generators.
If I close the PMF / GDU, it will met GDUF = 0x21 ,Low VLS error. It returns 0, when I read GDUF and I can't clear it by GDUF = 0x21