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.

PMSM3_1的A,B,C三相电流采样问题

Other Parts Discussed in Thread: CONTROLSUITE

TI专家好:

我现在用PMSM3_1调试程序,现在很疑惑电流采样F281X_ileg2_drv模块,查了资料说是Date15是双极性电流以Q15的格式表示,代表的是电流的标幺值,但是下面这段程序完全就没有进行不标幺化的部分,怎么Date15就成了电流的标幺值了呢?在这里很疑惑,还有就是电流经过ADC转化,不是要除以65520,再乘以3呢,为什么这段程序没有?最后得到的电流采样结果ImeasA也是电流的标幺值吗?不需要转化成实际值吗??

求教TI老师,谢谢老师们!问题有点多,不好意思啦!

DatQ15 = AdcRegs.ADCRESULT0^0x8000; 
Tmp = (int32)p->ImeasAGain*(int32)DatQ15; 
p->ImeasA = (int16)(Tmp>>13); 
p->ImeasA += p->ImeasAOffset; 
p->ImeasA *= -1; 

DatQ15 = AdcRegs.ADCRESULT1^0x8000; 
Tmp = (int32)p->ImeasBGain*(int32)DatQ15; 
p->ImeasB = (int16)(Tmp>>13); 
p->ImeasB += p->ImeasBOffset; 
p->ImeasB *= -1; 
p->ImeasC = -(p->ImeasA + p->ImeasB);