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.

TMS320F28075: Sensitivity of comparator subsystem

Part Number: TMS320F28075

Dear experts, 

for my work I am developping an application on the microcontroller Piccolo (TMS320F28075) for the motor control.

I programmed the CMPSS2 subsystem to perform a protection of the EPWM2 by means of tripzone.

Here below my settings:

Cmpss2Regs.CTRIPHFILCTL.bit.SAMPWIN = 31;
Cmpss2Regs.CTRIPHFILCTL.bit.THRESH = 30;
Cmpss2Regs.CTRIPHFILCLKCTL.bit.CLKPRESCALE = 2;
Cmpss2Regs.CTRIPHFILCTL.bit.FILINIT = 1;

I performed some experimental tests in lab in order to verify the effectiveness of my code.

I succesfully demonstrate that when I apply a DC current (130mA) higher than threshold (115mA), the tripzone forces high the PWM signal. 

Therefore, everything works fine if I apply a step input signal.

Then, I performed some experimental test by applying a pulse signal with the same amplitude (the amplitude of the pulse is 150mA, again).

I verified that the subsystem CMPSS2 does not trigger the tripzone if the width of the pulse is lower than 10ms.

Moreover, I verified that the register Cmpss2Regs.COMPHSTS.bit.COMPHLATCH is always 0. 

To sum up:

- everything works fine with a step input signal;

- the cmpss does not work with a pulse signal less wide than 10ms.

Why does the operation of CMPSS depends on the width of my signal?

I calculated that the width of the digital filter is (SAMPWIN+1)/(SYSCLK/(CLKPRESCALE+1))=32/(120000000/3)=800ns

Best regards,

Benito

 

  • I solved the problem! Here below the explaination. I hope it will be helpful for other users.

    There is a leak in my setup.

    Specifically, in order to apply the pulse I connected the microcontroller to a waveform generator. Morevoer, in order to measure the current, between the waveform generator and the microcontroller I connected an ammeter.

    Differently from the step voltage, the pulse voltage wide 10ms is probably filtered by the ammeter.

    Indeed, I removed the ammeter from the setup and everything works fine (as in case of the step voltage).