Skip to content

Enabling IW416 and IW612 BT HCI controller with MIMXRT1060EVKC platform for Bluetooth apps to work #85639

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions boards/nxp/mimxrt1060_evk/doc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,10 @@ The MIMXRT1060 SoC has five pairs of pinmux/gpio controllers.
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_01 | LPI2C1_SDA | I2C |
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_04 | LPUART3_CTS | UART BT HCI |
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_05 | LPUART3_RTS | UART BT HCI |
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_06 | LPUART3_TX | UART BT HCI |
+---------------+-----------------+---------------------------+
| GPIO_AD_B1_07 | LPUART3_RX | UART BT HCI |
Expand Down Expand Up @@ -428,6 +432,14 @@ should see the following message in the terminal:
***** Booting Zephyr OS v1.14.0-rc1 *****
Hello World! mimxrt1060_evk//qspi

Shield for M.2 Wi-Fi and BT Interface
=====================================

Rev C version is tested with :ref:`nxp_m2_wifi_bt` shield to attach any M.2 module
with BT HCI UART interface and Wi-Fi SDIO interface. The shield binds the required NXP
HCI driver or SDIO driver to perform firmware-load and other setup configurations
for NXP SoC IW416/IW612.

Troubleshooting
===============

Expand Down
6 changes: 5 additions & 1 deletion boards/nxp/mimxrt1060_evk/mimxrt1060_evk.dtsi
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2018,2024 NXP
* Copyright 2018,2024-2025 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
Expand Down Expand Up @@ -308,3 +308,7 @@ arduino_spi: &lpspi1 {
dvp_fpc24_i2c: &lpi2c1 {};

dvp_fpc24_interface: &csi {};

m2_hci_bt_uart: &lpuart3 {};

m2_wifi_sdio: &usdhc1 {};
91 changes: 91 additions & 0 deletions boards/shields/nxp_m2_wifi_bt/Kconfig.defconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
# Copyright 2025 NXP
# SPDX-License-Identifier: Apache-2.0

if SHIELD_NXP_M2_1XK_WIFI_BT

if BT

choice BT_NXP_MODULE
default BT_NXP_IW416
endchoice

endif # BT

if WIFI

config WIFI_NXP
default y

choice NXP_WIFI_PART
default NXP_IW416
endchoice

choice NXP_IW416_MODULE
default NXP_IW416_MURATA_1XK_M2
endchoice

endif # WIFI

endif # SHIELD_NXP_M2_1XK_WIFI_BT

if SHIELD_NXP_M2_2EL_WIFI_BT

if BT

choice BT_NXP_MODULE
default BT_NXP_NW612
endchoice

endif # BT

if WIFI

config WIFI_NXP
default y

choice NXP_WIFI_PART
default NXP_IW61X
endchoice

choice NXP_IW61X_MODULE
default NXP_IW612_MURATA_2EL_M2
endchoice

endif # WIFI

endif # SHIELD_NXP_M2_2EL_WIFI_BT

if (BT_NXP_IW416) || (BT_NXP_NW612) || (NXP_IW416) || (NXP_IW61X)

if BT

config SYSTEM_WORKQUEUE_STACK_SIZE
default 2048

config BT_LONG_WQ_STACK_SIZE
default 2560

config MAIN_STACK_SIZE
default 2560

if SHELL

config SHELL_STACK_SIZE
default 4096

endif # SHELL

endif # BT

if WIFI_NXP

if SHELL

config NXP_WIFI_SHELL
default y

endif # SHELL

endif # WIFI_NXP

endif
8 changes: 8 additions & 0 deletions boards/shields/nxp_m2_wifi_bt/Kconfig.shield
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Copyright 2025 NXP
# SPDX-License-Identifier: Apache-2.0

config SHIELD_NXP_M2_1XK_WIFI_BT
def_bool $(shields_list_contains,nxp_m2_1xk_wifi_bt)

config SHIELD_NXP_M2_2EL_WIFI_BT
def_bool $(shields_list_contains,nxp_m2_2el_wifi_bt)
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
/*
* Copyright 2025 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/

/ {
chosen {
zephyr,uart-pipe = &lpuart1;
};
};

&m2_hci_bt_uart {
/delete-property/ pinctrl-0;
/delete-property/ pinctrl-1;
/delete-property/ pinctrl-2;
/delete-property/ pinctrl-names;
pinctrl-0 = <&pinmux_lpuart3_flow_control>;
pinctrl-1 = <&pinmux_lpuart3_sleep>;
pinctrl-names = "default", "sleep";

bt_hci_uart: bt_hci_uart {
m2_bt_module: m2_bt_module {
sdio-reset-gpios = <&gpio1 24 GPIO_ACTIVE_HIGH>;
w-disable-gpios = <&gpio1 19 GPIO_ACTIVE_HIGH>;
};
};
};

&m2_wifi_sdio {
/* Use dat3 detection method */
detect-dat3;
pinctrl-4 = <&pinmux_usdhc1_dat3_nopull>;
pinctrl-names = "default", "slow", "med", "fast", "nopull";
};

&pinctrl {
/* removes pull on dat3 for card detect */
pinmux_usdhc1_dat3_nopull: pinmux_usdhc1_dat3_nopull {

group0 {
pinmux = <&iomuxc_gpio_sd_b0_01_usdhc1_clk>;
bias-disable;
drive-strength = "r0";
input-schmitt-enable;
slew-rate = "fast";
nxp,speed = "100-mhz";
};

group1 {
pinmux = <&iomuxc_gpio_b1_12_gpio2_io28>,
<&iomuxc_gpio_sd_b0_00_usdhc1_cmd>,
<&iomuxc_gpio_sd_b0_02_usdhc1_data0>,
<&iomuxc_gpio_sd_b0_03_usdhc1_data1>,
<&iomuxc_gpio_sd_b0_04_usdhc1_data2>;
drive-strength = "r0";
input-schmitt-enable;
bias-pull-up;
bias-pull-up-value = "47k";
slew-rate = "fast";
nxp,speed = "100-mhz";
};

group2 {
pinmux = <&iomuxc_gpio_b1_14_usdhc1_vselect>;
drive-strength = "r0-4";
input-schmitt-enable;
bias-pull-up;
bias-pull-up-value = "47k";
slew-rate = "fast";
nxp,speed = "100-mhz";
};

group3 {
pinmux = <&iomuxc_gpio_ad_b0_05_gpio1_io05>;
drive-strength = "r0-6";
slew-rate = "slow";
nxp,speed = "100-mhz";
};

group4 {
pinmux = <&iomuxc_gpio_sd_b0_05_usdhc1_data3>;
bias-disable;
drive-strength = "r0";
slew-rate = "fast";
nxp,speed = "100-mhz";
input-schmitt-enable;
};
};
};
62 changes: 62 additions & 0 deletions boards/shields/nxp_m2_wifi_bt/doc/index.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
.. _nxp_m2_wifi_bt:

NXP M.2 Wi-Fi and BT Shield
###########################

Overview
********

This Zephyr shield is tested with the following M.2 modules and hardware for Wi-Fi and Bluetooth applications:

- Embedded Artist 1XK module - uses Murata 1XK radio module with NXP IW416 chipset
- Embedded Artist 2EL module - uses Murata 2EL radio module with NXP IW612 chipset

More information about supported chipsets, radio modules and M.2 modules can be found in below links,

- `IW612 NXP Chipset <https://www.nxp.com/products/IW612>`_
- `IW416 NXP Chipset <https://www.nxp.com/products/IW416>`_
- `2EL Murata Radio Module <https://www.murata.com/en-us/products/connectivitymodule/wi-fi-bluetooth/overview/lineup/type2el>`_
- `1XK Murata Radio Module <https://www.murata.com/en-us/products/connectivitymodule/wi-fi-bluetooth/overview/lineup/type1xk>`_
- `1XK Embedded Artist Module <https://www.embeddedartists.com/products/1xk-m-2-module>`_
- `2EL Embedded Artist Module <https://www.embeddedartists.com/products/2el-m-2-module>`_

Requirements
************

To use the shield, below requirements needs to be satisfied.

- M.2 module with BT HCI UART and SDIO Interface with NXP IW416 or IW612 SoC support.
- Host platform shall have compatible M.2 interface slot.
- For Coex (Wi-Fi + BT), UART driver that supports UART RTS line control to wakeup BT CPU from sleep.
- To use default Bluetooth-Shell app it needs ~490KB flash & ~130KB RAM memory.
- To use default Wi-Fi-Shell app it needs ~1MB flash & ~1.2MB RAM memory.

Integration Platform
********************

This shield works with below host platform,

- :zephyr:board:`mimxrt1060_evk` Rev-C.

Programming
***********

Below are the supported shields to be used with ``--shield <option>`` when you invoke
``west build``.

- ``nxp_m2_1xk_wifi_bt``: For Wi-Fi/Bluetooth samples to work with NXP IW416 SoC
- ``nxp_m2_2el_wifi_bt``: For Wi-Fi/Bluetooth samples to work with NXP IW612 SoC

For example:

.. zephyr-app-commands::
:zephyr-app: samples/bluetooth/handsfree
:board: mimxrt1060_evk@C//qspi
:shield: nxp_m2_1xk_wifi_bt
:goals: build

.. zephyr-app-commands::
:zephyr-app: samples/net/wifi/shell
:board: mimxrt1060_evk@C//qspi
:shield: nxp_m2_2el_wifi_bt
:goals: build
37 changes: 37 additions & 0 deletions boards/shields/nxp_m2_wifi_bt/nxp_m2_1xk_wifi_bt.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
/*
* Copyright 2025 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/

/ {
chosen {
zephyr,bt-hci = &bt_hci_uart;
};
};

&m2_hci_bt_uart {
current-speed = <115200>;
status = "okay";

bt_hci_uart: bt_hci_uart {
compatible = "zephyr,bt-hci-uart";
status = "okay";

m2_bt_module {
compatible = "nxp,bt-hci-uart";
hci-operation-speed = <3000000>;
hw-flow-control;
fw-download-primary-speed = <115200>;
fw-download-secondary-speed = <3000000>;
fw-download-secondary-flowcontrol;
};
};
};

&m2_wifi_sdio {
nxp_wifi {
compatible = "nxp,wifi";
status = "okay";
};
};
37 changes: 37 additions & 0 deletions boards/shields/nxp_m2_wifi_bt/nxp_m2_2el_wifi_bt.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
/*
* Copyright 2025 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/

/ {
chosen {
zephyr,bt-hci = &bt_hci_uart;
};
};

&m2_hci_bt_uart {
current-speed = <115200>;
status = "okay";

bt_hci_uart: bt_hci_uart {
compatible = "zephyr,bt-hci-uart";
status = "okay";

m2_bt_module {
compatible = "nxp,bt-hci-uart";
hci-operation-speed = <3000000>;
hw-flow-control;
fw-download-primary-speed = <115200>;
fw-download-secondary-speed = <3000000>;
fw-download-secondary-flowcontrol;
};
};
};

&m2_wifi_sdio {
nxp_wifi {
compatible = "nxp,wifi";
status = "okay";
};
};
Loading
Loading