Hi all,
I presently have an interleaved synchronous buck converter I am controlling with my microcontroller. I also communicate with an external FPGA which provides an outer control loop as well as sends information such as whether or not to turn the converter on or off. I presently use the ADC PPB and the on chip comparators to produce a DC module output. That works fine. For on/off control I read data from the FPGA, look for a certain bit pattern, and based on what the microcontroller reads, send a TZFRC command if the pattern isn't present, or send a TZCLR if it is present. I'm having issues with the functionality however. The documentation for configuring the TZFRC response is a little unclear. All of the OSHT registers look for TZ1-6 as the source, how that correlates to TZFRC and the response is unclear. When I configure the PWM modules as follows I can never get the OSHT flag to clear
EALLOW;
EPwm1Regs.TZSEL.bit.OSHT1 = TZ_ENABLE;
EPwm1Regs.TZCTL.bit.TZA = TZ_FORCE_LO;
EPwm1Regs.TZCTL.bit.TZB = TZ_FORCE_LO;
EDIS;
If I forgo this step, the microcontroller is able to clear the register, but the PWM output is still active. I'm scratching my head as to why I can't clear the OSHT flag in one case and not the other. Any help would be greatly appreciated.
Lance