TMS320F280039: CLA trigger source CLA_TRIGGER_SDFM1DRINT1,2,3,4 not working

Part Number: TMS320F280039
Other Parts Discussed in Thread: C2000WARE

I intend to handle the filter results of SDFM1 Filter1 by the CLA. So the CLA task needs to be triggered for every data ready interrupt of SDFM1 Filter1. Obviously, the command to set the correct trigger source should be:

CLA_setTriggerSource(CLA_TASK_1, CLA_TRIGGER_SDFM1DRINT1);
 
But the CLA task never gets triggered even though I enable the SDFM interrupt:
 
SDFM_enableInterrupt(SDFM1_BASE, SDFM_FILTER_1, SDFM_DATA_FILTER_ACKNOWLEDGE_INTERRUPT);
 
and also reset the Interrupt Flags to get a triggering edge:
 
SDFM_clearInterruptFlag(SDFM1_BASE, SDFM_FILTER_1_NEW_DATA_FLAG |  SDFM_MAIN_INTERRUPT_FLAG);
 
By the way, I find it very confusing, that the interrupt is sometimes called "Data Ready" and sometimes "Filter Acknowledge". There should be a unique naming convention in the C2000ware.
 
The CLA task is triggered correctly when choosing this interrupt instead:
 
CLA_setTriggerSource(CLA_TASK_1, CLA_TRIGGER_SDFM1DRINT1);
 
However, this is not what I want, because I use this interrupt already for modulator fault exceptions.
 
How can I configure the CLA to only trigger on the data ready interrupt and not on the general SDFM1 interrupt? Obviously, the CLA was designed to be able to distinguish this, because you can configure all of these SDFM1 interrupts:
 
    CLA_TRIGGER_SDFM1INT    = 95U,  //!< CLA Task Trigger Source is SDFM1INT
    CLA_TRIGGER_SDFM1DRINT1 = 96U,  //!< CLA Task Trigger Srce is SDFM1DRINT1
    CLA_TRIGGER_SDFM1DRINT2 = 97U,  //!< CLA Task Trigger Srce is SDFM1DRINT2
    CLA_TRIGGER_SDFM1DRINT3 = 98U,  //!< CLA Task Trigger Srce is SDFM1DRINT3
    CLA_TRIGGER_SDFM1DRINT4 = 99U,  //!< CLA Task Trigger Srce is SDFM1DRINT4
 
However, only the first one (CLA_TRIGGER_SDFM1INT) is really working. I tried all four data ready interrupts and they fail to trigger the CLA. How can I fix that?
  • Hi Oliver,

    Another customer was trying to do something similar, let me find the example code for that and get back to you.

    Best Regards,

    Delaney 

  • Hi Oliver,

    Apologies for the delay here. Attached here is the project I was mentioning. Let me know if this the same as what you are trying to do.

    CLA_SDFM_example.zip

    Best Regards,

    Delaney

  • Yes, I can see in the syscfg file of your example project, that the CLA task 1 trigger is set to "CLA_TRIGGER_SDFM4DRINT1". That means, that in the example project, a similar behavior is intended: CLA task 1 shall trigger on every data ready event of SDFM4 filter 1. It confirms that I configured everything correctly in my syscfg file. But still, the CLA task is not triggered. Only the trigger CLA_TRIGGER_SDFM1INT is working.

  • Hi Oliver,

    If you try running the standalone example do you see the CLA task get triggered?

    Also, to check the functionality, you are adding a  __mdebugstop(); line into the task right? Regular breakpoints do not work inside a .cla file.

    Best Regards,

    Delaney

  • I could not try the standalone example because it is using a different microcontroller, the F28P65x. In my project with the F280039, I am using _mdebugstop(); to verify that the task has been triggered. And it is triggered on every data ready event, if I select SDFM1INT as trigger, but it is not triggered at all if I select SDFM1DRINT1. This is weird, because I expected SDFM1INT to only trigger on error events like modulator fault.

  • Hi Oliver,

    I see, let me loop in the SDFM expert to comment.

    Best Regards,

    Delaney

  • Hi Oliver,

    We'll reach out to you soon!

    Best Regards,

    Masoud

  • Hello, Oliver.

    It looks like the problem here may be caused by a System Control (SysCtl) register default value. Page 290 in the tech reference manual refers to this register set that I believe is influencing which interrupt line the data ready interrupt is being fed through:

    In short, this "SDFM type" register defaults to Type 0, which combines the Data Ready conditions "with the fault conditions on the SDFM interrupt line" (i.e. SDFM1INT). Type 1 causes the DR condition to "not generate the SDFMINT" and instead "generates a separate data read interrupts" (i.e. SDFM1DRINTx).

    If you're using a DriverLib project, you can run the following code to switch the SDFM type into Type 1, and the DR interrupt line should now be generating an interrupt on the DR condition:

    SysCtl_configureType(SYSCTL_SDFMTYPE, 1, 0);

    Alternatively, you can write a 1 in the 0th bit of the SDFMTYPE register via bit field commands.

    Best,

    Ryan