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.

6455 i2c问题



我的是自制板,c6455作从发送机;

我初始化完i2c之后发现ICSTR寄存器的ICXRDY位被拉高

Bool i2cEn;
/* Unlock the control register */
CSL_FINST(((CSL_DevRegs*)CSL_DEV_REGS)->PERLOCK, DEV_PERLOCK_LOCKVAL,
UNLOCK);

/* Enable the I2C */
CSL_FINST(((CSL_DevRegs*)CSL_DEV_REGS)->PERCFG0, DEV_PERCFG0_I2CCTL,
ENABLE);

do {
i2cEn = (Bool) CSL_FEXT(((CSL_DevRegs*)CSL_DEV_REGS)->PERSTAT0,
DEV_PERSTAT0_I2CSTAT);
} while (i2cEn != TRUE);

查看数据手册发现

主设备没有进行读操作6455也会有一个写状态;所以我打算清除ICXRDY位,但是我向ICXRDY写0或写1都无法清除他,只有调用CSL_i2cWrite才能清除;但之后我每次向主设备发送的数据都是我上一次发送的值。

请问该如何摆脱这个困境?

谢谢