i2c bus busy problem

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

i2c bus busy problem

3,253 次查看
love_hate_and_repeat
Contributor III

i'm working on t1042 cpu and i didnt solve some problems i encountered. 

i firstly send start condition to bus and after that, i dont send anything except stop condition to free bus but 

after start condition, if i send stop condition to bus, it doesnt work and bus is always remaining as busy.

code is like follow; 

send start condition

send stop condition

exit

0 项奖励
回复
3 回复数

2,825 次查看
jeffthompson
Contributor V

Try reconfiguring the clock as a GPIO pin, toggle it 16 times, then configure it back to an I2C clock and try again.

See Common Problems In Systems - I2C Bus. Got to Analyzing Obscure Problems/Blocked I2C Bus.

0 项奖励
回复

2,825 次查看
Pavel
NXP Employee
NXP Employee

See the Section 23.5.3.1 of the T1042 Reference Manual:

The bus is detected to be busy upon the detection of a START condition, and idle upon the detection of a STOP condition.

It looks like that a STOP condition is not detected.

Send STOP condition again.

 

Try to use command sequence from the Section 23.6.2.3.

Have a great day,
Pavel Chubakov

 

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 项奖励
回复

2,825 次查看
love_hate_and_repeat
Contributor III

thanks.

0 项奖励
回复