forked from zephyrproject-rtos/zephyr
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
boards: arm: Add support for NXP FRDM-K22F board
This adds support for NXP's Freedom K22 board. Co-authored-by: Sean Nyekjaer <[email protected]> Co-authored-by: Tom Burdick <[email protected]> Signed-off-by: Tom Burdick <[email protected]>
- Loading branch information
Showing
12 changed files
with
731 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# | ||
# Copyright (c) 2019, Prevas A/S | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
|
||
if(CONFIG_PINMUX_MCUX) | ||
zephyr_library() | ||
zephyr_library_include_directories(${ZEPHYR_BASE}/drivers) | ||
zephyr_library_sources(pinmux.c) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Kconfig - FRDM-K22F board | ||
# | ||
# Copyright (c) 2018, Prevas A/S | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
|
||
config BOARD_FRDM_K22F | ||
bool "NXP FRDM-K22F" | ||
depends on SOC_SERIES_KINETIS_K2X | ||
select SOC_PART_NUMBER_MK22FN512VLH12 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
# Kconfig - FRDM-K22F board | ||
# | ||
# Copyright (c) 2018 Prevas A/S | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
|
||
if BOARD_FRDM_K22F | ||
|
||
config BOARD | ||
default "frdm_k22f" | ||
|
||
config OSC_XTAL0_FREQ | ||
default 8000000 | ||
|
||
config MCG_PRDIV0 | ||
default 0x3 | ||
|
||
config MCG_VDIV0 | ||
default 0xc | ||
|
||
config MCG_FCRDIV | ||
default 0 | ||
|
||
if UART_MCUX | ||
|
||
config UART_MCUX_1 | ||
default y if UART_CONSOLE | ||
|
||
endif # UART_MCUX | ||
|
||
if PINMUX_MCUX | ||
|
||
config PINMUX_MCUX_PORTA | ||
default y | ||
|
||
config PINMUX_MCUX_PORTB | ||
default y | ||
|
||
config PINMUX_MCUX_PORTC | ||
default y | ||
|
||
config PINMUX_MCUX_PORTD | ||
default y | ||
|
||
config PINMUX_MCUX_PORTE | ||
default y if UART_MCUX_1 | ||
|
||
endif # PINMUX_MCUX | ||
|
||
if GPIO_MCUX | ||
|
||
config GPIO_MCUX_PORTA | ||
default y | ||
|
||
config GPIO_MCUX_PORTB | ||
default y | ||
|
||
config GPIO_MCUX_PORTC | ||
default y | ||
|
||
config GPIO_MCUX_PORTD | ||
default y | ||
|
||
config GPIO_MCUX_PORTE | ||
default y | ||
|
||
endif # GPIO_MCUX | ||
|
||
if I2C | ||
|
||
config I2C_0 | ||
default y | ||
|
||
endif # I2C | ||
|
||
if ADC | ||
|
||
config ADC_0 | ||
default y | ||
|
||
endif # ADC | ||
|
||
if PWM_MCUX_FTM | ||
|
||
config PWM_3 | ||
default y | ||
|
||
endif # PWM_MCUX_FTM | ||
|
||
if SPI | ||
|
||
config SPI_0 | ||
default y | ||
|
||
endif # SPI | ||
|
||
endif # BOARD_FRDM_K22F |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
set_ifndef(OPENSDA_FW daplink) | ||
|
||
if(OPENSDA_FW STREQUAL jlink) | ||
set_ifndef(BOARD_DEBUG_RUNNER jlink) | ||
set_ifndef(BOARD_FLASH_RUNNER jlink) | ||
elseif(OPENSDA_FW STREQUAL daplink) | ||
set_ifndef(BOARD_DEBUG_RUNNER pyocd) | ||
set_ifndef(BOARD_FLASH_RUNNER pyocd) | ||
endif() | ||
|
||
board_runner_args(jlink "--device=MK22FN512xxx12") | ||
board_runner_args(pyocd "--target=k22f") | ||
|
||
include(${ZEPHYR_BASE}/boards/common/pyocd.board.cmake) | ||
include(${ZEPHYR_BASE}/boards/common/jlink.board.cmake) | ||
include(${ZEPHYR_BASE}/boards/common/openocd.board.cmake) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.