How should the I2C and UART of i.MX7 be configured using the config tool?

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

How should the I2C and UART of i.MX7 be configured using the config tool?

跳至解决方案
930 次查看
HOTA
Contributor III

Hi,


Could you please guide me on how to configure IIC and UART for i.MX7D using the config tool?

The reason I'm asking is that I assume IIC and UART are usually controlled via Open Drain. However, I was informed that Open Drain settings are not available for GPIO, as per the following link:
https://community.nxp.com/t5/i-MX-Processors/How-configure-a-pin-as-Open-Drain-for-i-MX7D-using-the-...

In the config tool under the Peripheral section, options for I2C and UART are available. I assume that in actual software control, there's no need to switch between input and output and that communication will occur via Open Drain.

In that case, how should the "Pull Select Field," "Pull Enable Field," "Hysteresis Enable Field," "Slew Rate Field," and "Drive Strength Field" be set for IIC and UART pins in the config tool? I selected MCIMX7D-SDB-REV-D from the config tool kit and checked the settings under the function groups init_i2c_pins and init_uart_pins. They were set a certain way, which leads me to believe that setting them the same way should be fine. However, I noticed that 100kPD is enabled and Hysteresis is disabled, which prompted me to ask this question. (I usually think that for IIC and UART, Pull-Up and Hysteresis should be enabled.)

HOTA_0-1693905114046.png

Thanks,
HOTA

 

0 项奖励
回复
1 解答
846 次查看
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @HOTA,

I hope you are doing well.

It is not required to set UART pins to open-drain via registers.

Thanks & Regards,
Dhruvit Vasavada

在原帖中查看解决方案

0 项奖励
回复
4 回复数
905 次查看
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @HOTA,

I hope you are doing well.

One doesn't need to explicitly set an open drain for I2C in i.MX7D. It will be handled by the i2c module.

Yes, For I2C Pull-Up and Hysteresis should be enabled in the PAD Control Register.

One can refer to pinctrl_i2c1 node in imx7d-sdb.dts, where 0x0000007f value is configured in 8.2.7.235 SW_PAD_CTL_PAD_I2C1_SDA SW PAD Control Register. (Reference Manual.)

Thanks & Regards,
Dhruvit Vasavada

0 项奖励
回复
892 次查看
HOTA
Contributor III

Hi @Dhruvit ,


Thank you for your reply.

Is it unnecessary to set the UART to open-drain via registers?

 

Thanks,

HOTA

0 项奖励
回复
847 次查看
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @HOTA,

I hope you are doing well.

It is not required to set UART pins to open-drain via registers.

Thanks & Regards,
Dhruvit Vasavada

0 项奖励
回复
833 次查看
HOTA
Contributor III

Hi @Dhruvit ,

 

Thanks again,

HOTA

0 项奖励
回复