AnsweredAssumed Answered

i.MX6Q UART and IOMux tool problem?

Question asked by Andrew Trotman on Mar 20, 2013
Latest reply on Apr 28, 2014 by Norman C
Branched to a new discussion

Hi,

 

When I use the IOMux tool (Version 3.4.0.0) to generate the code to route the pins for UART2 on the i.MX6Q (pins E25/E26) it generates the following code:

 

void uart2_iomux_config(void)
{
    // Config uart2.UART2_RX_DATA to pad EIM_DATA27(E25)
    HW_IOMUXC_SW_MUX_CTL_PAD_EIM_DATA27_WR(0x00000004); // DISABLED, ALT4
    // ENABLED, 100K_OHM_PU, PULL, ENABLED, DISABLED, 100MHZ, 40_OHM, SLOW
    HW_IOMUXC_SW_PAD_CTL_PAD_EIM_DATA27_WR(0x0001B0B0);
    HW_IOMUXC_UART2_UART_RX_DATA_SELECT_INPUT_WR(0x00000000); // EIM_DATA26_ALT4

    // Config uart2.UART2_TX_DATA to pad EIM_DATA26(E24)
    HW_IOMUXC_SW_MUX_CTL_PAD_EIM_DATA26_WR(0x00000004); // DISABLED, ALT4
    // ENABLED, 100K_OHM_PU, PULL, ENABLED, DISABLED, 100MHZ, 40_OHM, SLOW
    HW_IOMUXC_SW_PAD_CTL_PAD_EIM_DATA26_WR(0x0001B0B0);
    HW_IOMUXC_UART2_UART_RX_DATA_SELECT_INPUT_WR(0x00000000); // EIM_DATA26_ALT4
}

 

This works fine for writing to the port, but unless I add the following line:

 

HW_IOMUXC_UART2_UART_RX_DATA_SELECT_INPUT_WR(BF_IOMUXC_UART2_UART_RX_DATA_SELECT_INPUT_DAISY_V(EIM_DATA27_ALT4));

 

I can't read from the port - I don't get a signal on the RDR bit of USR2.  Adding the line fixes the problem - I can read and write to UART2.

 

Have I missed something here?  I've not tried it on the other UART - presumably I'll find similar problems?

 

Outcomes