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.)
Thanks,
HOTA
已解决! 转到解答。
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