Skip to content

Conversation

AllenZhang-NXP
Copy link

soc: mcxw235,mcxw236: add SOC support for MCXW235 and MCXW236
dts: mcxw235,mcxw236: add dts for MCXW235 and MCXW236
boards: frdm_mcxw23: add frdm_mcxw23 board
boards: mcxw23_evk: add mcxw23_evk board

Copy link

github-actions bot commented Sep 1, 2025

Hello @AllenZhang-NXP, and thank you very much for your first pull request to the Zephyr project!
Our Continuous Integration pipeline will execute a series of checks on your Pull Request commit messages and code, and you are expected to address any failures by updating the PR. Please take a look at our commit message guidelines to find out how to format your commit messages, and at our contribution workflow to understand how to update your Pull Request. If you haven't already, please make sure to review the project's Contributor Expectations and update (by amending and force-pushing the commits) your pull request if necessary.
If you are stuck or need help please join us on Discord and ask your question there. Additionally, you can escalate the review when applicable. 😊

# CMSIS SystemInit allows us to skip enabling clock to SRAM banks via
# this compiler definition
if(NOT DEFINED CONFIG_MCXW23X_SRAM_CLOCKS)
zephyr_compile_definitions(DONT_ENABLE_DISABLED_RAMBANKS=1)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 space indent

default 60

config SYS_CLOCK_HW_CYCLES_PER_SEC
default 32000000
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

get from dts value using dt functions

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can reference this line for an example.
https://github.com/zephyrproject-rtos/zephyr/blob/main/soc/nxp/imxrt/Kconfig.defconfig#L27
You would need to add clock-frequency = 32000000 for the sysclk node in the soc dts file

compatible = "nxp,lpc-syscon";
reg = <0x0 0x4000>;
#clock-cells = <1>;
reset: reset {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

newline line 79, fix in whole PR

Comment on lines 10 to 17
if BOOTLOADER_MCUBOOT
choice MCUBOOT_BOOTLOADER_MODE
# Board only supports MCUBoot via "upgrade only" method:
default MCUBOOT_BOOTLOADER_MODE_OVERWRITE_ONLY
endchoice
endif #BOOTLOADER_MCUBOOT
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if BOOTLOADER_MCUBOOT
choice MCUBOOT_BOOTLOADER_MODE
# Board only supports MCUBoot via "upgrade only" method:
default MCUBOOT_BOOTLOADER_MODE_OVERWRITE_ONLY
endchoice
endif #BOOTLOADER_MCUBOOT
if BOOTLOADER_MCUBOOT
choice MCUBOOT_BOOTLOADER_MODE
# Board only supports MCUBoot via "upgrade only" method:
default MCUBOOT_BOOTLOADER_MODE_OVERWRITE_ONLY
endchoice
endif # BOOTLOADER_MCUBOOT

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

needs vastly reducing in size/resolution

#gpio-cells = <2>;
gpio-map-mask = <0xffffffff 0xffffffc0>;
gpio-map-pass-thru = <0 0x3f>;
gpio-map = <0 0 &gpio0 16 0>, /* A0 */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

space after =, not tab

depends on FXLS8974_TRIGGER

if BOOTLOADER_MCUBOOT
choice MCUBOOT_BOOTLOADER_MODE
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

apply changes from other commit

@nordicjm nordicjm requested a review from kartben September 1, 2025 14:29
@AllenZhang-NXP AllenZhang-NXP force-pushed the mcxw23_zephyr_base_enablement branch from 3a9127e to 8810b1d Compare September 4, 2025 03:50
Copy link

github-actions bot commented Sep 4, 2025

The following west manifest projects have changed revision in this Pull Request:

Name Old Revision New Revision Diff

All manifest checks OK

Note: This message is automatically posted and updated by the Manifest GitHub Action.

@AllenZhang-NXP
Copy link
Author

Fixed the issues mentioned by @nordicjm & the Github CI.
Rebased the main branch and synced the latest hal_nxp (has the updated MCXW23 header files) in west.yml.
Force updated the feature branch.

choice MCUBOOT_BOOTLOADER_MODE
# Board only supports MCUBoot via "upgrade only" method:
default MCUBOOT_BOOTLOADER_MODE_OVERWRITE_ONLY
endchoice
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@butok , do we need this defined here and Kconfig.sysbuild

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, both (with & without sysbuild)
The flash write-block-size = <512>

- gpio
- uart
- counter
- flash
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i2c?

CONFIG_UART_INTERRUPT_DRIVEN=y
CONFIG_GPIO=y
CONFIG_ARM_MPU=y
CONFIG_RUNTIME_NMI=y
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why was this added to the defconfig. I don't see it in a number of the other NXP boards, hence curious why this was added.

- gnuarmemb
supported:
- gpio
- uart
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you help to enable the tests/driver/gpio with arduino header?
and enable tests/drivers/uart/uart_basic_api with lpuart loopback as well?

add soc MCX235 and MCXW236 for board frdm_mcxw23

Signed-off-by: Allen Zhang <[email protected]>
add dts for device MCXW235 and MCXW236

Signed-off-by: Allen Zhang <[email protected]>
enable board support for frdm_mcxw23

Signed-off-by: Allen Zhang <[email protected]>
enable board support for mcxw23_evk

Signed-off-by: Allen Zhang <[email protected]>
…mcxw23_evk

Support arduino_gpio example for NXP frdm_mcxw23 and mcxw23_evk boards.
Test using tests/drivers/gpio/gpio_basic_api.

Signed-off-by: Allen Zhang <[email protected]>
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants