Skip to content

Commit

Permalink
board: MIMXRT1062-FMURT6: Add pinmux support for uart ports
Browse files Browse the repository at this point in the history
used for gps and telemtry.

This patch configures the correct pinmux settings for

lpuart2, lpuart3, lpuart5 ports used for gps and telemetry modules.

It also adds software pull up for the UART console port lpuart7.

Signed-off-by: Sumit Batra <[email protected]>
Signed-off-by: Benjamin Perseghetti <[email protected]>
  • Loading branch information
sumitbatra-nxp committed May 19, 2023
1 parent 5781478 commit bb6b964
Show file tree
Hide file tree
Showing 2 changed files with 91 additions and 8 deletions.
72 changes: 64 additions & 8 deletions boards/arm/mimxrt1062_fmurt6/mimxrt1062_fmurt6-pinctrl.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,8 @@
pinmux = <&iomuxc_gpio_emc_32_lpuart7_rx>,
<&iomuxc_gpio_emc_31_lpuart7_tx>;
drive-strength = "r0-6";
bias-pull-up;
bias-pull-up-value = "100k";
slew-rate = "slow";
nxp,speed = "100-mhz";
};
Expand All @@ -330,10 +332,37 @@
};
};

pinmux_lpuart2: pinmux_lpuart2 {
group0 {
pinmux = <&iomuxc_gpio_ad_b1_02_lpuart2_tx>,
<&iomuxc_gpio_ad_b1_03_lpuart2_rx>;
drive-strength = "r0-6";
slew-rate = "slow";
nxp,speed = "100-mhz";
};
};

pinmux_lpuart2_sleep: pinmux_lpuart2_sleep {
group0 {
pinmux = <&iomuxc_gpio_ad_b1_03_lpuart2_rx>;
drive-strength = "r0";
bias-pull-up;
bias-pull-up-value = "100k";
slew-rate = "slow";
nxp,speed = "100-mhz";
};
group1 {
pinmux = <&iomuxc_gpio_ad_b1_02_lpuart2_tx>;
drive-strength = "r0-6";
slew-rate = "slow";
nxp,speed = "100-mhz";
};
};

pinmux_lpuart3: pinmux_lpuart3 {
group0 {
pinmux = <&iomuxc_gpio_ad_b1_06_lpuart3_tx>,
<&iomuxc_gpio_ad_b1_07_lpuart3_rx>;
pinmux = <&iomuxc_gpio_b0_08_lpuart3_tx>,
<&iomuxc_gpio_b0_09_lpuart3_rx>;
drive-strength = "r0-6";
slew-rate = "slow";
nxp,speed = "100-mhz";
Expand All @@ -343,10 +372,10 @@
/* Flow control for lpuart3 */
pinmux_lpuart3_flow_control: pinmux_lpuart3_flow_control {
group0 {
pinmux = <&iomuxc_gpio_ad_b1_06_lpuart3_tx>,
<&iomuxc_gpio_ad_b1_07_lpuart3_rx>,
<&iomuxc_gpio_ad_b1_04_lpuart3_cts_b>,
<&iomuxc_gpio_ad_b1_05_lpuart3_rts_b>;
pinmux = <&iomuxc_gpio_b0_08_lpuart3_tx>,
<&iomuxc_gpio_b0_09_lpuart3_rx>,
<&iomuxc_gpio_sd_b1_04_gpio3_io04>,
<&iomuxc_gpio_emc_24_gpio4_io24>;
drive-strength = "r0-6";
slew-rate = "slow";
nxp,speed = "100-mhz";
Expand All @@ -355,15 +384,42 @@

pinmux_lpuart3_sleep: pinmux_lpuart3_sleep {
group0 {
pinmux = <&iomuxc_gpio_ad_b1_06_gpio1_io22>;
pinmux = <&iomuxc_gpio_b0_09_lpuart3_rx>;
drive-strength = "r0";
bias-pull-up;
bias-pull-up-value = "100k";
slew-rate = "slow";
nxp,speed = "100-mhz";
};
group1 {
pinmux = <&iomuxc_gpio_b0_08_lpuart3_tx>;
drive-strength = "r0-6";
slew-rate = "slow";
nxp,speed = "100-mhz";
};
};

pinmux_lpuart5: pinmux_lpuart5 {
group0 {
pinmux = <&iomuxc_gpio_emc_23_lpuart5_tx>,
<&iomuxc_gpio_b1_13_lpuart5_rx>;
drive-strength = "r0-6";
slew-rate = "slow";
nxp,speed = "100-mhz";
};
};

pinmux_lpuart5_sleep: pinmux_lpuart5_sleep {
group0 {
pinmux = <&iomuxc_gpio_b1_13_lpuart5_rx>;
drive-strength = "r0";
bias-pull-up;
bias-pull-up-value = "100k";
slew-rate = "slow";
nxp,speed = "100-mhz";
};
group1 {
pinmux = <&iomuxc_gpio_ad_b1_07_lpuart3_rx>;
pinmux = <&iomuxc_gpio_emc_23_lpuart5_tx>;
drive-strength = "r0-6";
slew-rate = "slow";
nxp,speed = "100-mhz";
Expand Down
27 changes: 27 additions & 0 deletions boards/arm/mimxrt1062_fmurt6/mimxrt1062_fmurt6.dts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@
zephyr,console = &lpuart7;
zephyr,shell-uart = &lpuart7;
zephyr,canbus = &flexcan1;
zephyr,gps1 = &lpuart2;
zephyr,telem1 = &lpuart3;
zephyr,telem4-gps2 = &lpuart5;
};

leds {
Expand Down Expand Up @@ -284,6 +287,30 @@
pinctrl-names = "default", "sleep";
};

&lpuart2 {
status = "okay";
current-speed = <115200>;
pinctrl-0 = <&pinmux_lpuart2>;
pinctrl-1 = <&pinmux_lpuart2_sleep>;
pinctrl-names = "default", "sleep";
};

&lpuart3 {
status = "okay";
current-speed = <115200>;
pinctrl-0 = <&pinmux_lpuart3>;
pinctrl-1 = <&pinmux_lpuart3_sleep>;
pinctrl-names = "default", "sleep";
};

&lpuart5 {
status = "okay";
current-speed = <115200>;
pinctrl-0 = <&pinmux_lpuart5>;
pinctrl-1 = <&pinmux_lpuart5_sleep>;
pinctrl-names = "default", "sleep";
};

&lpspi1 {
status = "okay";
pinctrl-0 = <&pinmux_lpspi1>;
Expand Down

0 comments on commit bb6b964

Please sign in to comment.