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.

TMS320F28377S: Executing supervisory checks at multiple rate of control ISR

Part Number: TMS320F28377S

We designed a control scheme in which the control algorithm and supervisory checks (over current, voltage, temperature etc) were performed on the same ISR. Basically the gates switching PWM @20 KHz triggers ADC Start Of Conversions. The End Of Conversions EOC of the last control measurements triggers the control ISR. Since hardware tripping circuit was not incorporated for all relevant signals so there is an idea to perform supervisory checks in a relatively much faster ISR. This idea is shown in the diagram below:

 

I understand that we might have to enable two interrupts, a high priority supervisory interrupt executing @ 100 KHz (using a 100 KHz PWM synchronized with the 10 KHz PWM) and a lower priority control interrupt executing at 20 KHz (triggered with gate switching PWM). In this regard I have the following queries:

1- Is this a good approach considering that hardware trips are not implemented for some fast rising voltages/currents in the hardware?. Is there a better and more efficient way?.

2- Do I need to configure separate SOCs for the control ISR and supervisory ISR although both will be sampling the same control inputs?. Is there a more efficient and better way to trigger both ISRs for e.g. both ISRs can use common ADC conversion at some instances when their execution times overlap.

3- How to set priorities for both ISRs?. I understand that supervisory ISR can be assigned to ADCA1 interrupt i.e. highest priority interrupt.  Should we assign other ADC interrupt such as ADCB1 for the control ISR?. Also I think that software method might be required for nesting interrupts so that supervisory ISR can interrupt the control ISR.

  • Hi,

    I will get back to you tomorrow.

    Regards,

    Chen

  • Hi,

    1- Is this a good approach considering that hardware trips are not implemented for some fast rising voltages/currents in the hardware?. Is there a better and more efficient way?.

    From the performance point of view, this will be much worse than using CMPSS since it is based on the h/w. 100kHz is not considered fast enough for current protection.

    2- Do I need to configure separate SOCs for the control ISR and supervisory ISR although both will be sampling the same control inputs?. Is there a more efficient and better way to trigger both ISRs for e.g. both ISRs can use common ADC conversion at some instances when their execution times overlap.

    Depends on if you are using single ADC. if yes then one SOC for that ADC is enough. I think you can actually use the same ADC conversion value for both ISR. It is probably not the same value due to the sampling timing and ISR timing.

    3- How to set priorities for both ISRs?. I understand that supervisory ISR can be assigned to ADCA1 interrupt i.e. highest priority interrupt.  Should we assign other ADC interrupt such as ADCB1 for the control ISR?. Also I think that software method might be required for nesting interrupts so that supervisory ISR can interrupt the control ISR.

    You can refer to the link below and the our reference design in DPSDK if needed. 

    https://software-dl.ti.com/C2000/docs/c28x_interrupt_nesting/html/index.html

    Regards,

    Chen

  • Thank you very much for your reply. Let me try implementation and if there is any further query then I will get back to you.