Hi,
Release: Yocto-Morty (4.9.51_GA)
Board: i.MX8MQ based custom board
I want to use iMX8MQ ECSPI2 pins as full UART4 and I have used configured pinmux as below in dts file.
pinctrl_uart4: uart4grp {
fsl,pins = <
MX8MQ_IOMUXC_ECSPI2_MISO_UART4_DCE_CTS_B 0x49
MX8MQ_IOMUXC_ECSPI2_MOSI_UART4_DTE_RX 0x49
MX8MQ_IOMUXC_ECSPI2_SCLK_UART4_DTE_TX 0x49
MX8MQ_IOMUXC_ECSPI2_SS0_UART4_DCE_RTS_B 0x49
>;
};
&uart4 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_uart4>;
assigned-clocks = <&clk IMX8MQ_CLK_UART4_SRC>;
assigned-clock-parents = <&clk IMX8MQ_CLK_25M>;
fsl,uart-has-rtscts;
status = "okay";
};
But I am unable to use it as UART4. When I read registers using devmem2 utility, there are UART4 TX & RX pins configure as a GPIOs instead of TX/RX. RTS/CTS pins configured correctly.
root@imx8mqpicoitx:~# devmem2 0x30330204
/dev/mem opened.
Memory mapped at address 0xffffa4999000.
Read at address 0x30330204 (0xffffa4999200): 0x0000000100000005 //Tx configured as a GPIO
root@imx8mqpicoitx:~# devmem2 0x30330208
/dev/mem opened.
Memory mapped at address 0xffffa1ff9000.
Read at address 0x30330208 (0xffffa1ff9208): 0x0000000100000005 //Rx configured as a GPIO
root@imx8mqpicoitx:~# devmem2 0x3033020C
/dev/mem opened.
Memory mapped at address 0xffff9c17e000.
Read at address 0x3033020C (0xffff9c17e208): 0x0000000100000001
root@imx8mqpicoitx:~# devmem2 0x30330210
/dev/mem opened.
Memory mapped at address 0xffffa5f35000.
Read at address 0x30330210 (0xffffa5f35210): 0x0000001000000001
root@imx8mqpicoitx:~#
Is there any other configuration required to use it as a UART?
Best regards,
Nirmal
Hello,
Just to know. Have you reviewed if you are not porting the UART4 RX/TX into another port?
For example.
MX8MQ_IOMUXC_UART4_RXD_UART4_DTE_TX and MX8MQ_IOMUXC_UART4_TXD_UART4_DCE_TX
Best regards,
Diego.
Hello Diego Adrian Cuevas,
Thanks for your response.
This issue is resolved now as there is a mistake in hardware design and pins getting conflicted.
So, it remains in default state which is as GPIO.
Best regards,
Nirmal