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.

TM4C1294NCPDT: I2C的用法

Part Number: TM4C1294NCPDT


Hi Expert,

請教一下有關於I2C的用法,目前使用的SDK版本” TivaWare_C_Series-2.2.0.295”,

客戶需要可以在I2C連續傳送2 bytes的資料,目前只找到 “humidity_sht21”的example,

裡面使用I2C_MASTER_CMD_SINGLE_SEND 的方法,只能傳輸一個Bytes的資料。

 

於是客戶參考Using Feature Set of I2C Master on TM4C129x,文件

裡面的I2C_MASTER_CMD_BURST_SEND_START & I2C_MASTER_CMD_BURST_SEND_FINISH

方法實現了傳輸2個bytes的資料,

但會出現一個奇怪的問題,

有時候只會傳輸1個byte的資料,另1個byte沒有傳輸出去 (如下圖),

以下是客戶的code,想問的是客戶這樣的使用方法是這確的?

如果有範例可以參考,再麻煩提供一下,

謝謝

 

Daniel