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.

TMS320F280049 ECAP OVERFLOW not set in CAP continuous mode though seen on overflowing on debugger

Helllo,

I am using the ECAP on cascade of an CMPSS to compute some electrical motor speed.

The measure is working fine but when the motor stops i expected to read an overflow flag and set my speed to 0.

But no overflow flag is raised.

Here s my config:

// continuous mode, wrap around after event 4.

ECAP_setCaptureMode(ECAP1_BASE, ECAP_CONTINUOUS_CAPTURE_MODE, ECAP_EVENT_2);

ECAP_selectECAPInput(ECAP1_BASE,ECAP_INPUT_CMPSS3_CTRIP_LOW);

ECAP_setEventPolarity(ECAP1_BASE, ECAP_EVENT_1, ECAP_EVNT_RISING_EDGE);

ECAP_setEventPolarity(ECAP1_BASE, ECAP_EVENT_2, ECAP_EVNT_RISING_EDGE);

ECAP_enableCounterResetOnEvent(ECAP1_BASE, ECAP_EVENT_1);

ECAP_enableCounterResetOnEvent(ECAP1_BASE, ECAP_EVENT_2);

ECAP_enableLoadCounter(ECAP1_BASE);

 ECAP_startCounter(ECAP1_BASE);

ECAP_enableTimeStampCapture(ECAP1_BASE);

 

I then read the CTROVF bit of the ECFLG register.

I see the raised flag for CEVT1 and CEVT2, but nothing on the CTROVF. 

When i look at the Counter , i do see it overflow... (transition from FFFFFFFF to 00000000)

Can you explain what could be the reason i sont see any OVF flag?

Thank you,

PA.