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.

Compiler/TMS320F28035: Issue with epwm interrupt with TMS320F28035

Part Number: TMS320F28035

Tool/software: TI C/C++ Compiler

Hi all

I am designign a three phase inverter, so I am using the epwm4, epw5 and epwm6 to generate the three phase sinusoidal signal. I set a data table in flash memory, from this table I obtain the pulses for epwm´s. I did a subroutines of service to epw´s interrupts. Althought the configuration of three epw modules is almost equal, only epwm4 and epwm5 function fine. The epw6 not generat the interruption. I send screenviews about the set the modules epwm.

I hope that someone can to help me.

Thanks a lot in advance.

Sebastián

  • Are you getting pulses from EPWM6?
  • Hi, Ramesh
    Yes, but that pulses only correspond to the initial configuration. The epwm6 module don´t make the interrupt, I did verify in the debugger of CCS.

    Thank you for your interest
  • Can you check the ETFLG register and report the bit values? These indicate if the EPWM module attempted to generate an interrupt. If the INT flags in here are set, this means that something further down the line (outside of the EPWM) is not configured properly.

    I also do not see your code setting the PieVectTable to the EPWM ISRs. Could you share that as well?
  • Hi
    I send several screen views of epwm registers (epwm4, epwm5 and epwm6). I am using the framework of the lab 7 of C2000 Workshop where it´s a file has for interrupts subrutine service.

    Thanks a lot.

    Sebastián

  • It looks like the flag is being set. It is likely an issue outside of the PWM. Please post your entire initialization code in main().
  • Hi Kaparrent

    I send the screeniews of the main.c file.

    Thank you very much.

    Sebastián...

  • Sebastián,

    Why are you clearing the ETFLG in the while() loop for EPWM6? This may be what is causing the problem with your interrupt generation.

    Why is the InitPieVect function commented out? Where are you setting up the PieVectTable now? Please search for PieVectTable and show any code associated with it.
  • Hi Kaparrent

    I did an exercise where I changed the epwm modules 3, 4 and 5 instead 4, 5 and 6 epwm modules. In this case the module epwm5 don´t generates the interruption. I want to say that the three interruption service subrutines have the instruction to clear the interruption flag. However, I will eliminate this instruction.

    The PieVectTable is in the file PieVect_5_6_7_8_9_10.c this file is part of the example Lab7 in the C2000 Piccolo workshop. So I send several screewn views that show the table.

    Tanks a lot.

    Sebastián...

  • Sebastian,

    I was referring to the ETCLR in your while() loop in main. That is a strange place to clear the interrupt condition and may clear it before it propagates to the PIE.

    All of the screenshots are really confusing. I would recommend just posting your entire file(s) for any code relating to PWMs or interrupts generation.
  • Hi Kparrent

    With the instruction for clear ETCLR, INT bit I tried clear interrupt flag fo the epwm6, but don´t function. Now I am using empw3, epwm4 and epwm5, therefore this instruction don´t have efect in my actual program. However I will put this like a coment.


    The screenviews correspond to PieVectTable file and I sent such in order, if you see the lines number, is the complet file and sent those because another partner of forum asked to me.

    Thanks a lot.

    Sebastián

  • Sebastián,

    please read the following addresses using the memory browser during run time. If the value of the these addresses are not the same as the corresponding ISR address you need to correct them.

     0x0000 0D60  EPWM1_INT (EPWM1) 
     0x0000 0D62  EPWM2_INT (EPWM2) 
     0x0000 0D64  EPWM3_INT (EPWM3) 
     0x0000 0D66  EPWM4_INT (EPWM4) 
     0x0000 0D68  EPWM5_INT (EPWM5) 
     0x0000 0D6A  EPWM6_INT (EPWM6)
     0x0000 0D6C  EPWM7_INT (EPWM7)

    If those are correct: read the configuration of the switches shown in the diagram below(INTM, IER, IFR, PIEIER, PIEIFR), if they are not enabled your interrupt signal will not reach the CPU.

    Regards,
    Cody