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.

TMS320F280045: SDFM issue

Part Number: TMS320F280045

Hi experts,

My customer use SINCFAST filter, OSR=128, Sdfm1Regs.SDDPARM2.bit.SH=1. When input of AMC1306 is -250mV~250mV, hey found the data fluctuates greatly. They thought that for SINCFAST filter, OSR=128, the data scope is -32768~32767, within the 16-bit data range, the shift registers are not required to be operated. Is it right?

The second issue is when selecting the SINC3 filter, the data fluctuates significantly under the same conditions as SINCFAST filter type. Here is the measured result:

When the SINC3 filter is selected, OSR=32, the shift register 0, the amc1306 modulator input 250mV signal, the theoretical data is 25598, but the actual data range is form 28389 to 28553.

Here is the code:

EALLOW;

    EPwm5Regs.TBPHS.all = 0;

//向上计数模式

    EPwm5Regs.TBCTL.all = 0xc000;

    EPwm5Regs.CMPCTL.all = 0x0;

    EPwm5Regs.CMPCTL2.all = 0x0;

    EPwm5Regs.AQCSFRC.all = 0x0;    //Force Disable

/*Action-Qualifier Output A Control Register*/

//时基计数器等于周期寄存器或实际计算器值等于0时使ePWM5A输出高电平

    EPwm5Regs.AQCTLA.all = 0x0003;

/*Action-Qualifier Output A2 Control Register*/

    EPwm5Regs.AQCTLA2.all = 0;

/*Do nothing*/

/*Action-Qualifier Output B Control Register*/

    EPwm5Regs.AQCTLB.all = 0;

/*Do nothing*/

/*Action-Qualifier Output B2 Control Register*/

    EPwm5Regs.AQCTLB2.all = 0;

/*Do nothing*/

/*Dead-Band Generator Control Register*/

//使能双边延时,apwma翻转

    EPwm5Regs.DBCTL.all = 0x0007;

/*Event-Trigger Selection Register*/

    EPwm5Regs.ETSEL.all = 0x0;

/*Event-Trigger Prescale Register*/

    EPwm5Regs.ETPS.all = 0x0;

/*Time-Base Period Register*/

//EPwm5Regs.TBPRD = 4; // 10M 100M/10M/2 - 1 = 4

//配置时机周期寄存器

    EPwm5Regs.TBPRD = 2; // 16.67M 100M/(2 + 1)/2 = 16M

 

 

//IU sigma-delta ADC

    Sdfm1Regs.SDDFPARM2.bit.DOSR = 128;        //抽取率

    Sdfm1Regs.SDDFPARM2.bit.SST = 0;           //滤波器类型

    Sdfm1Regs.SDDFPARM2.bit.FEN = 1;           //使能数据滤波器

    Sdfm1Regs.SDDPARM2.bit.DR = 0;             //16bit数据

    Sdfm1Regs.SDDPARM2.bit.SH = 0;             //数据移位

 

//IW sigma-detal ADC

    Sdfm1Regs.SDDFPARM4.bit.DOSR = 128;

    Sdfm1Regs.SDDFPARM4.bit.SST = 0;

    Sdfm1Regs.SDDFPARM4.bit.FEN = 1;

    Sdfm1Regs.SDDPARM4.bit.DR = 0;

    Sdfm1Regs.SDDPARM4.bit.SH = 0;

 

//Comparator (Secondary) Filter Unit Config

//过流保护模块使用数据范围为0-32768

    Sdfm1Regs.SDCPARM2.bit.COSR = 31;

//Sinc3型滤波器

    Sdfm1Regs.SDCPARM2.bit.CS1_CS0 = 3;

//使能比较滤波器

    Sdfm1Regs.SDCPARM2.bit.CEN = 1;

//使能大于高阈值中断

    Sdfm1Regs.SDCPARM2.bit.IEH = 1;

//使能小于低阈值中断

    Sdfm1Regs.SDCPARM2.bit.IEL = 1;

 

    Sdfm1Regs.SDCPARM4.bit.COSR = 31;

    Sdfm1Regs.SDCPARM4.bit.CS1_CS0 = 3;

    Sdfm1Regs.SDCPARM4.bit.CEN = 1;

    Sdfm1Regs.SDCPARM4.bit.IEH = 1;

    Sdfm1Regs.SDCPARM4.bit.IEL = 1;

 

//使能主滤波器器

    Sdfm1Regs.SDMFILEN.bit.MFE = 1;

//主中断使能

    Sdfm1Regs.SDCTL.bit.MIE = 1;

 

    EPwmXbarRegs.TRIP4MUX16TO31CFG.bit.MUX18 = 1;

    EPwmXbarRegs.TRIP4MUX16TO31CFG.bit.MUX22 = 1;

    EPwmXbarRegs.TRIP4MUXENABLE.bit.MUX18 = 1;

    EPwmXbarRegs.TRIP4MUXENABLE.bit.MUX22 = 1;

 

//过流保护阈值在此设置

 

    Sdfm1Regs.SDCMPH2.bit.HLT = 24000;

    Sdfm1Regs.SDCMPL2.bit.LLT = 10000;

    Sdfm1Regs.SDCMPH4.bit.HLT = 24000;

    Sdfm1Regs.SDCMPL4.bit.LLT = 10000;

    EDIS;

 

    EALLOW;

Sdfm1Regs.SDIFLGCLR.bit.MIF = 1;

    EDIS;

Please help solve these issues, thanks a lot!