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.

TMS320F28388D: 关于20.11 ADC Calibration章节的疑问

Part Number: TMS320F28388D
Other Parts Discussed in Thread: C2000WARE

在这一章节中 提到了很多函数的名字

The Device_cal() function copies the trim values for ADC and DAC offset from OTP memory to their
respective trim registers.

问题1.按照这段文字的描述,Device_cal()函数是用来配置偏置值的吗?

The CalAdcXINL() functions copy the trim values for linearity from OTP memory to the respective trim
registers.

问题2.按照这段文字的描述,CalAdcXINL函数是用来配置线性度的吗?可是这个函数是在哪里定义又是在何处调用的呢?

A different offset trim is required for each possible combination of resolution and signal mode. The
GetAdcOffsetTrimOTP(Uint16) function takes an input value corresponding to the ADC, resolution, and signal
mode and returns the corresponding offset trim value from OTP memory, which the user then moves into the
ADC offset trim register.

问题3.GetAdcOffsetTrimOTP这个函数是在哪里定义的?

问题4.按照“takes an input value corresponding to the ADC, resolution, and signalmode”的描述,函数GetAdcOffsetTrimOTP的参数是与ADC、分辨率、采样模式有关的一个Uint16的数值,这个Uint16的数值的和这三个参数是什么关系,哪里有定义?

The trim functions in Device_cal() are callable in C2000ware as ADC_setOFFSETTRIM(),
ADC_setINLTRIM(), and DAC_setDACTRIM(). These functions fetch trim values from the TI reserved OTP
memory source locations where the values are stored during test process as well as the analog module
register destinations where the trim values are copied to.

问题5.这段描述中提到了4个函数的名字,Device_cal、ADC_setOFFSETTRIM、ADC_setINLTRIM、DAC_setDACTRIM之间是什么关系?从这段的描述看,是Device_cal包含其余3个函数吗?调用Device_cal是会调用其余3个函数吗?

问题6. CalAdcXINL和ADC_setINLTRIM看起来都是对线性度的设定,这二者之间有什么关系吗?

  • 您好,我需要一点时间来看一下,预计下周给您答复。

  • 1. 是的。每块芯片在出厂时会做校准,并将校准值保存在指定内存。使用时调用相关函数加载校准值即可;

    2. 是的,原理如上;

        

    3. 

    4. 如上面两张图所示,这些定义最终是指向OTP指定内存的指针,这些位置上保存着校准值;

    5. Device_cal是bit-field中的函数,另外3个是driverlib中的函数;

    6. CalAdcXINL(X = a, b, c, ...)是指向保存校准值的OTP内存,ADC_setINLTRIM是driverlib中的校准函数。