Skip to content
Permalink
Browse files

boards: mimxrt1060_evk: Enable mcux lpi2c driver and pins

Enables the mcux lpi2c shim driver and pin muxes on the mimxrt1060_evk
board. Updates the board documentation and yaml supported list
accordingly.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
  • Loading branch information...
MaureenHelm committed Jan 21, 2019
1 parent 7f9f39f commit e0d7378712e9ee96d9b680b310103f7eab687f4a
@@ -29,6 +29,13 @@ config GPIO_MCUX_IGPIO_5

endif # GPIO_MCUX_IGPIO

if I2C_MCUX_LPI2C

config I2C_1
default y

endif # I2C_MCUX_LPI2C

if UART_MCUX_LPUART

config UART_MCUX_LPUART_1
@@ -98,6 +98,8 @@ features:
+-----------+------------+-------------------------------------+
| GPIO | on-chip | gpio |
+-----------+------------+-------------------------------------+
| I2C | on-chip | i2c |
+-----------+------------+-------------------------------------+
| UART | on-chip | serial port-polling; |
| | | serial port-interrupt |
+-----------+------------+-------------------------------------+
@@ -123,6 +125,10 @@ The MIMXRT1060 SoC has five pairs of pinmux/gpio controllers.
+---------------+-----------------+---------------------------+
| GPIO_AD_B0_13 | LPUART1_RX | UART Console |
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_00 | LPI2C1_SCL | I2C |
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_01 | LPI2C1_SDA | I2C |
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_06 | LPUART3_TX | UART BT HCI |
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_07 | LPUART3_RX | UART BT HCI |
@@ -81,6 +81,10 @@ arduino_serial: &uart3 {};
};
};

&i2c1 {
status = "ok";
};

&uart1 {
status = "ok";
current-speed = <115200>;
@@ -17,3 +17,4 @@ flash: 8192
supported:
- display
- hwinfo
- i2c
@@ -58,6 +58,26 @@ static int mimxrt1060_evk_init(struct device *dev)
IOMUXC_SW_PAD_CTL_PAD_DSE(6));
#endif

#ifdef CONFIG_I2C_1
/* LPI2C1 SCL, SDA */
IOMUXC_SetPinMux(IOMUXC_GPIO_AD_B1_00_LPI2C1_SCL, 1);
IOMUXC_SetPinMux(IOMUXC_GPIO_AD_B1_01_LPI2C1_SDA, 1);

IOMUXC_SetPinConfig(IOMUXC_GPIO_AD_B1_00_LPI2C1_SCL,
IOMUXC_SW_PAD_CTL_PAD_PUS(3) |
IOMUXC_SW_PAD_CTL_PAD_PKE_MASK |
IOMUXC_SW_PAD_CTL_PAD_ODE_MASK |
IOMUXC_SW_PAD_CTL_PAD_SPEED(2) |
IOMUXC_SW_PAD_CTL_PAD_DSE(6));

IOMUXC_SetPinConfig(IOMUXC_GPIO_AD_B1_01_LPI2C1_SDA,
IOMUXC_SW_PAD_CTL_PAD_PUS(3) |
IOMUXC_SW_PAD_CTL_PAD_PKE_MASK |
IOMUXC_SW_PAD_CTL_PAD_ODE_MASK |
IOMUXC_SW_PAD_CTL_PAD_SPEED(2) |
IOMUXC_SW_PAD_CTL_PAD_DSE(6));
#endif

#ifdef CONFIG_DISPLAY_MCUX_ELCDIF
IOMUXC_SetPinMux(IOMUXC_GPIO_B0_00_LCD_CLK, 0);
IOMUXC_SetPinMux(IOMUXC_GPIO_B0_01_LCD_ENABLE, 0);

0 comments on commit e0d7378

Please sign in to comment.
You can’t perform that action at this time.