IMX7D 1GB UART3 only working in DTE mode

I’m working on a board that uses all of the UART’s and adds another four with a SPI to uart chip.
So far 9 out of 10 are working fine, but i have issues with UART3.

When I use it in DTE mode the uart itself seems to work fine when talking to a uart to usb converter. When i put it in DCE mode if i swap the leads to the converter nothing works, if i leave them as for DTE atleast TX from the IMX7D works, but RX doesn’t.

Guess which mode i need for the hardware?

imx7d-colibri-emmc-icos_dce.dts (7.3 KB)
imx7d-colibri-emmc-icos_dte.dts (7.3 KB)

Hi @Michielt ,

Thank you for using the Toradex community.

I am sure you already had a look at the datasheet of the Colibri iMX7. On page 36 you can see the following section about UART:

The UART_A is used as standard debug interface for the Toradex Embedded Linux and Windows
Embedded Compact operating systems. It is recommended that at least the RXD and TXD lines of
this port are kept accessible for system debugging.

The UARTs of the i.MX 7 can be configured either in the DTE (Data Terminal Equipment) or DCE
(Data Communication Equipment) mode. Changing the mode will change the direction of all UART
pins (data and all control signals). To ensure compatibility with the entire Colibri family, UARTs
need to be configured in DTE mode.

Particular attention should be paid to the names of the i.MX 7 data signals. In DTE mode, the
UARTx_RX_DATA port is transmitting data from the SoC while the UARTx_TX_DATA port is receiving
it. Therefore, the RX and TX signals need to be swapped. In the following signal descriptions, the
port direction is always described for DTE mode.

The last section is particularly interesting. It can be quite confusing that UART_RX is transmitting and UART_TX is receiving. Please check if you assigned it as intended.

Furthermore I has a look at your device tree file and I noticed the following. In the file " imx7d-colibri-emmc-icos_dte.dts" you provided. I see that you are using DTE and DCE assignments. Is this on purpose?

pinctrl_uart3: uart3-grp {
	fsl,pins = <
pinctrl_uart4: uart4grp {
    fsl,pins = <
		MX7D_PAD_SD2_DATA0__UART4_DCE_RX    	0x79  /* SODIMM 23 */
		MX7D_PAD_SAI2_TX_BCLK__UART4_DCE_TX     0x79  /* SODIMM 27 */

Best Regards

Well wouldn’t say it’s on purpose…
I used a combination of the pinout of the Viola and the ballname’s of the SoM…
That’s why some are dte and some dce because those tend to mix. (my fault of not using a single source)

I’m sure i assigned it as intended. My point is that the uart3 rx doesn’t work in dce mode. (nothing is received).

Hi @Michielt ,

now I am a bit confused.

I see that apparently, UART3 is not receiving anything. According to the manual, all UARTs need to be configured in DTE mode to ensure compatibility. Did you try to put all UARTs into DTE mode?

Or is the DCE mode for UART3 a hard requirement for you?

Let me know.

Best Regards

Sorry, my text might be confusing…

  • DTE works RX and TX
  • DCE only TX works but on the same pin as DTE TX (so its not swapped!)

DCE mode is a hard requirement because the board design, the connection to the RS232 converter to be exact. This can be altered in the next iteration of the PCB.

For now I used patchwires on the prototype to keep working.
So the main reason for this thread is asking if i’m doing something wrong or if DCE is bugged.

Hi @Michielt ,

thanks for the clarification. I understand the situation better now.

I am looking into this, in the meantime. Have you seen the following community post?

I recommend you give this a read if you haven’t yet, it’s not the same module you use, but the method might work on your end too. Some changes in the u-boot section can temporary fix the issue, and then there’s some information on how to make the change permanent.

I will keep you updated for further information as soon as I gather them.

Best Regards