How to open the clock stretching for master I2C of RT1176?

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

How to open the clock stretching for master I2C of RT1176?

1,035 次查看
vwsncr
Contributor II
 
0 项奖励
回复
1 回复

1,004 次查看
Gavin_Jia
NXP TechSupport
NXP TechSupport

Hi @vwsncr ,

Thanks for your interest in NXP MIMXRT series!

I am glad to provide service for you. 

Here is a detailed documentation that you can refer to.It helps you to understand this feature. Also, please refer to the code in the SDK that enables Tx and Rx SCL clock stretching in the official SDK.

 

We don't need to send ACK/NACK manually, so enable clock stretching except ACKSTALL.
When ACKSTALL is enabled, there is no need to set either RX SCL Stall
(SCFGR1[RXSTALL]) or Address SCL Stall (SCFGR1[ADRSTALL]).
 
Code:
Gavin_Jia_0-1721036002171.png

void LPI2C_SlaveInit(:

Gavin_Jia_1-1721036066202.png

 

Best regards,
Gavin
 
0 项奖励
回复