LPI2C sending TIMEOUT

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

LPI2C sending TIMEOUT

ソリューションへジャンプ
9,948件の閲覧回数
shuo41
Contributor III

S32K344 write and read register of FXLS8967AF(3-Axis Low-g Accelerometer) by I2C, but it  keeps showing timeout. I can not send datas successful.

0 件の賞賛
返信
1 解決策
9,867件の閲覧回数
shuo41
Contributor III

I find the reason why i2c send timeout,the scl pin must in input/output mode,thinks for your help.

元の投稿で解決策を見る

7 返答(返信)
9,918件の閲覧回数
VaneB
NXP TechSupport
NXP TechSupport

Hi @shuo41 

Section 72.3.1.2 (Controller operations) of the S32K3xx Reference Manual, Rev. 7 states that "Whenever LPI2C is enabled, it monitors the I2C bus to detect when the I2C is idle (MSR[BBF]). If either SCL or SDA are low, the I2C bus is no longer considered idle. The bus becomes idle if a STOP condition is detected or if a bus idle timeout is detected (as configured by MCFGR2[BUSIDLE])..."

Double-check whether the I2C signals are correctly muxed in the SIUL2_MSCR/IMCR.

Also, measure the bus with a voltmeter or scope it with an oscilloscope. Are the SDA, SCL signals pulled up at the time you read the MSR[BBF] flag?

Do you have pull-up resistors on the bus?

 

B.R.

VaneB

0 件の賞賛
返信
9,905件の閲覧回数
shuo41
Contributor III

But, Sending status still timeout

0 件の賞賛
返信
9,910件の閲覧回数
shuo41
Contributor III

I have pull-up resistors on the bus,I measured the pull-up resistance with a voltmeter and it is working properly.

0 件の賞賛
返信
9,899件の閲覧回数
VaneB
NXP TechSupport
NXP TechSupport

Hi @shuo41 

Could you share an oscilloscope image of SCL and SDA?

0 件の賞賛
返信
9,794件の閲覧回数
shuo41
Contributor III

All the problems have been solved,thinks。

0 件の賞賛
返信
9,857件の閲覧回数
shuo41
Contributor III

But,the slave do not send ACK to master,my slave address is 0x30h。

The attachment is picture of I2C waveform。

0 件の賞賛
返信
9,868件の閲覧回数
shuo41
Contributor III

I find the reason why i2c send timeout,the scl pin must in input/output mode,thinks for your help.