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.

[参考译文] TMS320F28P650DK:I2C

Guru**** 2577385 points
Other Parts Discussed in Thread: C2000WARE

请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/microcontrollers/c2000-microcontrollers-group/c2000/f/c2000-microcontrollers-forum/1315139/tms320f28p650dk-i2c

器件型号:TMS320F28P650DK
主题中讨论的其他器件:C2000WARE

当检查 ti\cc2000\C2000Ware_5_01_00_00\driverlib\f28p65x\examples\C28x\i2c\ccs\的示例时

I2C_Ex5_controller_target_interrupt

i2cLib_FIFO_CONTROLLER_TARGET_INTERRUPT.c

我发现有两种不同的 发送数据样式、

第一个

I2C_sendStartCondition (base);

//等待目标地址的传输
while (!(I2C_getStatus (base)和 I2C_STS_REG_ACCESS_RDY));

//生成停止条件
I2C_sendStopCondition (base);

第二个  

I2C_sendStartCondition (base);
I2C_sendStopCondition (base);

问题是、当 msater 使用 FIFO 发送地址和数据时、应等待 while (I2C_getTxFIFOStatus (I2CA_BASE)!= I2C_FIFO_TXEMPTY)、然后等待 I2C_sendStopCondition  (base);

或者无关紧要、 在将数据放入 FIFO 后、可以一起发送开始和停止条件、硬件将进行处理、在发送数据后、将发送停止条件。

//设置要发送的数据
I2C_putData (I2CA_BASE、u16Cmd);

I2C_sendStartCondition (base);
I2C_sendStopCondition (base);

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好!  

    是的、硬件将在何时发送停止条件。  

    此致

    西达尔特