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.
Hello,
I have a question about action qualifiers in ePWM module. In my code I have to change the action qualifier within an interrupt. I want this change of action qualifier to take effect from the next PWM cycle.
From what I understand, if I change the value in AQCTLA register from AQ_SET to AQ_CLEAR, the change takes effect immediately. Is there a way to synchronize this change with TBCTR= Zero (i.e. the beginning of next ePWM cycle).
Can AQCSFRC register help me? If yes, could you please tell me about the way I should configure it?
Best regards,
Pawan
Has anyone figured this out? I have the same question.
I'd like to change the AQCTL, but I only want it to take effect when CTR=0 (or PRD).
For 28069, I would not suggest changing AQCTL on the fly. If you only want to change the PWM output to one particular state and hold it in this state continuously you can use AQCSFRC register (and have its action take effect on 0 or PRD). If changing AQCTL cannot be avoided you should change AQCTL inside a PWM event triggered interrupt synchronized with the time base of the PWM/s affected. You should then change the AQCTL at a point the interrupt as close to 0/PRD as possible. You will have to account for any possible jitter in the interrupt, context save/restore cycles etc. and adjust the trigger event point accordingly.
I hope this helps.
Hrishi