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.

TMS570LS1227: Unable to detect PWM frequency and duty cycle using HET1

Part Number: TMS570LS1227

Hi,

1)

I am using HET1 for:
a) Generating PWM output [using HET1 - pin 14]
b) Capturing PWM frequency & duty cycle [using HET1 - pin 15]
When I physically connect the pin 14 and pin 15, the PWM frequency & duty cycle is correctly showing.
However, when I generate another PWM output (from ePWM pin) and connect this to HET1 pin 15 for capture, it is not giving correct PWM frequency and duty cycle.
Is this behavior normal? I am able to successfully observe the PWM values if I connect to PWM output pin to eCAP.

2)

Using the eCAP pin, I am able to successfully observe PWM frequency and duty cycle. However, I am unable to perform Edge capture and PWM frequency/duty cycle capture using the same pin. Is there a software overhead to allow both edge capture & freq/duty capture? I won't be able to use HET for edge capture because all the HET pins are being used for PWM output.

Thanks.

  • Hello Abar,

    1. N2HET is able to detect the PWM frequency and duty cycle from ePWM.
    2. There is no register to capture the edge of the eCAP pin. But you can increment when the ECAP rising edge or falling edge occurs (interrupt ISR).