Skip to content

Commit 12cee02

Browse files
simbit18xiaoxiang781216
authored andcommitted
boards/arm/kinetis: Added CMake build for NXP Freedom-K64F board
- CMake added board NXP Freedom-K64F https://www.nxp.com/design/design-center/development-boards-and-designs/FRDM-K64F Signed-off-by: simbit18 <simbit18@gmail.com>
1 parent eca3942 commit 12cee02

File tree

2 files changed

+93
-0
lines changed

2 files changed

+93
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# ##############################################################################
2+
# boards/arm/kinetis/freedom-k64f/CMakeLists.txt
3+
#
4+
# SPDX-License-Identifier: Apache-2.0
5+
#
6+
# Licensed to the Apache Software Foundation (ASF) under one or more contributor
7+
# license agreements. See the NOTICE file distributed with this work for
8+
# additional information regarding copyright ownership. The ASF licenses this
9+
# file to you under the Apache License, Version 2.0 (the "License"); you may not
10+
# use this file except in compliance with the License. You may obtain a copy of
11+
# the License at
12+
#
13+
# http://www.apache.org/licenses/LICENSE-2.0
14+
#
15+
# Unless required by applicable law or agreed to in writing, software
16+
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
17+
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
18+
# License for the specific language governing permissions and limitations under
19+
# the License.
20+
#
21+
# ##############################################################################
22+
23+
add_subdirectory(src)
Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
# ##############################################################################
2+
# boards/arm/kinetis/freedom-k64f/src/CMakeLists.txt
3+
#
4+
# SPDX-License-Identifier: Apache-2.0
5+
#
6+
# Licensed to the Apache Software Foundation (ASF) under one or more contributor
7+
# license agreements. See the NOTICE file distributed with this work for
8+
# additional information regarding copyright ownership. The ASF licenses this
9+
# file to you under the Apache License, Version 2.0 (the "License"); you may not
10+
# use this file except in compliance with the License. You may obtain a copy of
11+
# the License at
12+
#
13+
# http://www.apache.org/licenses/LICENSE-2.0
14+
#
15+
# Unless required by applicable law or agreed to in writing, software
16+
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
17+
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
18+
# License for the specific language governing permissions and limitations under
19+
# the License.
20+
#
21+
# ##############################################################################
22+
23+
set(SRCS k64_boot.c k64_spi.c)
24+
25+
if(CONFIG_ARCH_LEDS)
26+
list(APPEND SRCS k64_autoleds.c)
27+
else()
28+
list(APPEND SRCS k64_userleds.c)
29+
endif()
30+
31+
if(CONFIG_ARCH_BUTTONS)
32+
list(APPEND SRCS k64_buttons.c)
33+
endif()
34+
35+
if(CONFIG_BOARDCTL)
36+
list(APPEND SRCS k64_appinit.c k64_bringup.c)
37+
elseif(CONFIG_BOARD_LATE_INITIALIZE)
38+
list(APPEND SRCS k64_bringup.c)
39+
endif()
40+
41+
if(CONFIG_I2C)
42+
list(APPEND SRCS k64_i2c.c)
43+
endif()
44+
45+
if(CONFIG_KINETIS_SDHC)
46+
list(APPEND SRCS k64_sdhc.c)
47+
if(CONFIG_FS_AUTOMOUNTER)
48+
list(APPEND SRCS k64_automount.c)
49+
endif()
50+
endif()
51+
52+
if(CONFIG_USBDEV)
53+
list(APPEND SRCS k64_usbdev.c)
54+
endif()
55+
56+
if(CONFIG_USBMSC)
57+
list(APPEND SRCS k64_usbmsc.c)
58+
endif()
59+
60+
if(CONFIG_PWM)
61+
list(APPEND SRCS k64_pwm.c)
62+
endif()
63+
64+
if(CONFIG_BOARDCTL_UNIQUEID)
65+
list(APPEND SRCS k64_uid.c)
66+
endif()
67+
68+
target_sources(board PRIVATE ${SRCS})
69+
70+
set_property(GLOBAL PROPERTY LD_SCRIPT "${NUTTX_BOARD_DIR}/scripts/flash.ld")

0 commit comments

Comments
 (0)