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.

F2808HALL驱动的问题



   在bldc3_1示例中,有段HALL驱动代码不甚明白,请教TI专家:

   ECAP初始化时,

CAP1POL_RISING_EDGE + \
CAP2POL_FALLING_EDGE + \
CAP3POL_FALLING_EDGE + \
CAP4POL_RISING_EDGE + \
CAPLDEN_ENABLE + \
EVTFLTPS_X_1 + \
EMULATION_FREE )

定义了4个CEVT事件,而在F280X_HALL3_Read中却仅判断CEVT1/CEVT2标志:

p->CapFlag = 0;  
if ((ECap1Regs.ECFLG.bit.CEVT1 != 0)||(ECap1Regs.ECFLG.bit.CEVT2 != 0))  
p->CapFlag |= 1;
if ((ECap2Regs.ECFLG.bit.CEVT1 != 0)||(ECap2Regs.ECFLG.bit.CEVT2 != 0))  
p->CapFlag |= 2;
if ((ECap3Regs.ECFLG.bit.CEVT1 != 0)||(ECap3Regs.ECFLG.bit.CEVT2 != 0)) 
p->CapFlag |= 4;

这一点,就不太明白了,难道CEVT3/CEVT4不使用?