mirror of
https://github.com/apache/nuttx.git
synced 2026-05-27 11:26:12 +08:00
Added new configuration (evalos) for the Nucleo-144 board family.
This new configuration will showcase all the features of the boards, so is a good way to easily test out a new board. This can be added to all boards in the future.
This commit is contained in:
@@ -142,9 +142,9 @@ Basic configuration & build steps
|
|||||||
be modified to point to the correct path to the Cortex-M7 GCC toolchain (if
|
be modified to point to the correct path to the Cortex-M7 GCC toolchain (if
|
||||||
different from the default in your PATH variable).
|
different from the default in your PATH variable).
|
||||||
|
|
||||||
- Configures nuttx creating .config file in the nuttx directory
|
- Configures nuttx creating .config file in the nuttx directory.
|
||||||
$ cd tools && ./configure.sh nucleo-f746zg/nsh && cd ..
|
$ cd tools && ./configure.sh nucleo-f746zg/nsh && cd ..
|
||||||
- Refreshes the .config file with the latest features addes sice this writting
|
- Refreshes the .config file with the latest available configurations.
|
||||||
$ make oldconfig
|
$ make oldconfig
|
||||||
- Select the features you want in the build.
|
- Select the features you want in the build.
|
||||||
$ make menuconfig
|
$ make menuconfig
|
||||||
@@ -155,7 +155,7 @@ Hardware
|
|||||||
========
|
========
|
||||||
|
|
||||||
GPIO - there are 144 I/O lines on the STM32F746ZGT6 with various pins pined out
|
GPIO - there are 144 I/O lines on the STM32F746ZGT6 with various pins pined out
|
||||||
on the Nucleo F746ZG
|
on the Nucleo F746ZG.
|
||||||
|
|
||||||
See https://developer.mbed.org/platforms/ST-Nucleo-F746ZG/ for slick graphic
|
See https://developer.mbed.org/platforms/ST-Nucleo-F746ZG/ for slick graphic
|
||||||
pinouts.
|
pinouts.
|
||||||
@@ -293,42 +293,80 @@ Serial Consoles
|
|||||||
Configurations
|
Configurations
|
||||||
==============
|
==============
|
||||||
|
|
||||||
nsh:
|
nsh:
|
||||||
---------
|
---------
|
||||||
Configures the NuttShell (nsh) located at apps/examples/nsh for the
|
Configures the NuttShell (nsh) located at apps/examples/nsh for the
|
||||||
Nucleo-144 boards. The Configuration enables the serial interfaces
|
Nucleo-144 boards. The Configuration enables the serial interfaces
|
||||||
on UART8. Support for builtin applications is enabled, but in the base
|
on UART6. Support for builtin applications is enabled, but in the base
|
||||||
configuration no builtin applications are selected (see NOTES below).
|
configuration no builtin applications are selected (see NOTES below).
|
||||||
|
|
||||||
NOTES:
|
NOTES:
|
||||||
|
|
||||||
1. This configuration uses the mconf-based configuration tool. To
|
1. This configuration uses the mconf-based configuration tool. To
|
||||||
change this configuration using that tool, you should:
|
change this configuration using that tool, you should:
|
||||||
|
|
||||||
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
|
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
|
||||||
see additional README.txt files in the NuttX tools repository.
|
see additional README.txt files in the NuttX tools repository.
|
||||||
|
|
||||||
b. If this is the intall configuration then Execute
|
b. If this is the intall configuration then Execute
|
||||||
'cd tools && ./configure.sh stm32f746g-disco/nsh && cd ..'
|
'cd tools && ./configure.sh nucleo-144/nsh && cd ..'
|
||||||
in nuttx/ in order to start configuration process.
|
in nuttx/ in order to start configuration process.
|
||||||
Caution: Doing this step more than once will overwrite .config with
|
Caution: Doing this step more than once will overwrite .config with
|
||||||
the contents of the stm32f746g-disco/nsh/defconfig file.
|
the contents of the nucleo-144/nsh/defconfig file.
|
||||||
|
|
||||||
c. Execute 'make oldconfig' in nuttx/ in order to refresh the
|
c. Execute 'make oldconfig' in nuttx/ in order to refresh the
|
||||||
configuration.
|
configuration.
|
||||||
|
|
||||||
d. Execute 'make menuconfig' in nuttx/ in order to start the
|
d. Execute 'make menuconfig' in nuttx/ in order to start the
|
||||||
reconfiguration process.
|
reconfiguration process.
|
||||||
|
|
||||||
e. Save the .config file to reuse it in the future starting at step d.
|
e. Save the .config file to reuse it in the future starting at step d.
|
||||||
|
|
||||||
2. By default, this configuration uses the ARM GNU toolchain
|
2. By default, this configuration uses the ARM GNU toolchain
|
||||||
for Linux. That can easily be reconfigured, of course.
|
for Linux. That can easily be reconfigured, of course.
|
||||||
|
|
||||||
CONFIG_HOST_LINUX=y : Builds under Linux
|
CONFIG_HOST_LINUX=y : Builds under Linux
|
||||||
CONFIG_ARMV7M_TOOLCHAIN_GNU_EABIL=y : ARM GNU for Linux
|
CONFIG_ARMV7M_TOOLCHAIN_GNU_EABIL=y : ARM GNU for Linux
|
||||||
|
|
||||||
3. Although the default console is USART3 (which would correspond to
|
3. Although the default console is USART3 (which would correspond to
|
||||||
the Virtual COM port) I have done all testing with the console
|
the Virtual COM port) I have done all testing with the console
|
||||||
device configured for UART8 (see instruction above under "Serial
|
device configured for UART8 (see instruction above under "Serial
|
||||||
Consoles).
|
Consoles).
|
||||||
|
|
||||||
|
evalos:
|
||||||
|
---------
|
||||||
|
This configuration is designed to test the features of the board.
|
||||||
|
- Configures the NuttShell (nsh) located at apps/examples/nsh for the
|
||||||
|
Nucleo-144 boards. The console is available on serial interface USART3,
|
||||||
|
which is accessible over the USB ST-Link interface.
|
||||||
|
- Configures nsh with advanced features such as autocompletion.
|
||||||
|
- Configures the on-board LEDs to work with the 'leds' example app.
|
||||||
|
- Configures the 'helloxx' example app.
|
||||||
|
|
||||||
|
NOTES:
|
||||||
|
|
||||||
|
1. This configuration uses the mconf-based configuration tool. To
|
||||||
|
change this configuration using that tool, you should:
|
||||||
|
|
||||||
|
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
|
||||||
|
see additional README.txt files in the NuttX tools repository.
|
||||||
|
|
||||||
|
b. If this is the intall configuration then Execute
|
||||||
|
'cd tools && ./configure.sh nucleo-144/evalos && cd ..'
|
||||||
|
in nuttx/ in order to start configuration process.
|
||||||
|
Caution: Doing this step more than once will overwrite .config with
|
||||||
|
the contents of the nucleo-144/evalos/defconfig file.
|
||||||
|
|
||||||
|
c. Execute 'make oldconfig' in nuttx/ in order to refresh the
|
||||||
|
configuration.
|
||||||
|
|
||||||
|
d. Execute 'make menuconfig' in nuttx/ in order to start the
|
||||||
|
reconfiguration process.
|
||||||
|
|
||||||
|
e. Save the .config file to reuse it in the future starting at step d.
|
||||||
|
|
||||||
|
2. By default, this configuration uses the ARM GNU toolchain
|
||||||
|
for Linux. That can easily be reconfigured, of course.
|
||||||
|
|
||||||
|
CONFIG_HOST_LINUX=y : Builds under Linux
|
||||||
|
CONFIG_ARMV7M_TOOLCHAIN_GNU_EABIL=y : ARM GNU for Linux
|
||||||
|
|||||||
@@ -0,0 +1,113 @@
|
|||||||
|
############################################################################
|
||||||
|
# configs/nucleo-144/evalos/Make.defs
|
||||||
|
#
|
||||||
|
# Copyright (C) 2016 Gregory Nutt. All rights reserved.
|
||||||
|
# Author: Gregory Nutt <gnutt@nuttx.org>
|
||||||
|
# Author: Mark Olsson <post@markolsson.se>
|
||||||
|
#
|
||||||
|
# Redistribution and use in source and binary forms, with or without
|
||||||
|
# modification, are permitted provided that the following conditions
|
||||||
|
# are met:
|
||||||
|
#
|
||||||
|
# 1. Redistributions of source code must retain the above copyright
|
||||||
|
# notice, this list of conditions and the following disclaimer.
|
||||||
|
# 2. Redistributions in binary form must reproduce the above copyright
|
||||||
|
# notice, this list of conditions and the following disclaimer in
|
||||||
|
# the documentation and/or other materials provided with the
|
||||||
|
# distribution.
|
||||||
|
# 3. Neither the name NuttX nor the names of its contributors may be
|
||||||
|
# used to endorse or promote products derived from this software
|
||||||
|
# without specific prior written permission.
|
||||||
|
#
|
||||||
|
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||||
|
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||||
|
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||||
|
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||||
|
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||||
|
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||||
|
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||||
|
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||||
|
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||||
|
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||||
|
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||||
|
# POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
#
|
||||||
|
############################################################################
|
||||||
|
|
||||||
|
include ${TOPDIR}/.config
|
||||||
|
include ${TOPDIR}/tools/Config.mk
|
||||||
|
include ${TOPDIR}/arch/arm/src/armv7-m/Toolchain.defs
|
||||||
|
|
||||||
|
LDSCRIPT = flash.ld
|
||||||
|
|
||||||
|
ifeq ($(WINTOOL),y)
|
||||||
|
# Windows-native toolchains
|
||||||
|
DIRLINK = $(TOPDIR)/tools/copydir.sh
|
||||||
|
DIRUNLINK = $(TOPDIR)/tools/unlink.sh
|
||||||
|
MKDEP = $(TOPDIR)/tools/mkwindeps.sh
|
||||||
|
ARCHINCLUDES = -I. -isystem "${shell cygpath -w $(TOPDIR)/include}"
|
||||||
|
ARCHXXINCLUDES = -I. -isystem "${shell cygpath -w $(TOPDIR)/include}" -isystem "${shell cygpath -w $(TOPDIR)/include/cxx}"
|
||||||
|
ARCHSCRIPT = -T "${shell cygpath -w $(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/scripts/$(LDSCRIPT)}"
|
||||||
|
else
|
||||||
|
# Linux/Cygwin-native toolchain
|
||||||
|
MKDEP = $(TOPDIR)/tools/mkdeps$(HOSTEXEEXT)
|
||||||
|
ARCHINCLUDES = -I. -isystem $(TOPDIR)/include
|
||||||
|
ARCHXXINCLUDES = -I. -isystem $(TOPDIR)/include -isystem $(TOPDIR)/include/cxx
|
||||||
|
ARCHSCRIPT = -T$(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/scripts/$(LDSCRIPT)
|
||||||
|
endif
|
||||||
|
|
||||||
|
CC = $(CROSSDEV)gcc
|
||||||
|
CXX = $(CROSSDEV)g++
|
||||||
|
CPP = $(CROSSDEV)gcc -E
|
||||||
|
LD = $(CROSSDEV)ld
|
||||||
|
AR = $(ARCROSSDEV)ar rcs
|
||||||
|
NM = $(ARCROSSDEV)nm
|
||||||
|
OBJCOPY = $(CROSSDEV)objcopy
|
||||||
|
OBJDUMP = $(CROSSDEV)objdump
|
||||||
|
|
||||||
|
ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'}
|
||||||
|
ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1}
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
|
||||||
|
ARCHOPTIMIZATION = -g
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_DEBUG_NOOPT),y)
|
||||||
|
ARCHOPTIMIZATION += $(MAXOPTIMIZATION) -fno-strict-aliasing -fno-strength-reduce -fomit-frame-pointer
|
||||||
|
endif
|
||||||
|
|
||||||
|
ARCHCFLAGS = -fno-builtin
|
||||||
|
ARCHCXXFLAGS = -fno-builtin -fno-exceptions -fno-rtti
|
||||||
|
ARCHWARNINGS = -Wall -Wstrict-prototypes -Wshadow -Wundef
|
||||||
|
ARCHWARNINGSXX = -Wall -Wshadow -Wundef
|
||||||
|
ARCHDEFINES =
|
||||||
|
ARCHPICFLAGS = -fpic -msingle-pic-base -mpic-register=r10
|
||||||
|
|
||||||
|
CFLAGS = $(ARCHCFLAGS) $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHCPUFLAGS) $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES) -pipe
|
||||||
|
CPICFLAGS = $(ARCHPICFLAGS) $(CFLAGS)
|
||||||
|
CXXFLAGS = $(ARCHCXXFLAGS) $(ARCHWARNINGSXX) $(ARCHOPTIMIZATION) $(ARCHCPUFLAGS) $(ARCHXXINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES) -pipe
|
||||||
|
CXXPICFLAGS = $(ARCHPICFLAGS) $(CXXFLAGS)
|
||||||
|
CPPFLAGS = $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES)
|
||||||
|
AFLAGS = $(CFLAGS) -D__ASSEMBLY__
|
||||||
|
|
||||||
|
NXFLATLDFLAGS1 = -r -d -warn-common
|
||||||
|
NXFLATLDFLAGS2 = $(NXFLATLDFLAGS1) -T$(TOPDIR)/binfmt/libnxflat/gnu-nxflat-pcrel.ld -no-check-sections
|
||||||
|
LDNXFLATFLAGS = -e main -s 2048
|
||||||
|
|
||||||
|
ASMEXT = .S
|
||||||
|
OBJEXT = .o
|
||||||
|
LIBEXT = .a
|
||||||
|
EXEEXT =
|
||||||
|
|
||||||
|
ifneq ($(CROSSDEV),arm-nuttx-elf-)
|
||||||
|
LDFLAGS += -nostartfiles -nodefaultlibs
|
||||||
|
endif
|
||||||
|
ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
|
||||||
|
LDFLAGS += -g
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
HOSTCC = gcc
|
||||||
|
HOSTINCLUDES = -I.
|
||||||
|
HOSTCFLAGS = -Wall -Wstrict-prototypes -Wshadow -Wundef -g -pipe
|
||||||
|
HOSTLDFLAGS =
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,78 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# configs/nucleo-144/evalos/setenv.sh
|
||||||
|
#
|
||||||
|
# Copyright (C) 2016 Gregory Nutt. All rights reserved.
|
||||||
|
# Author: Gregory Nutt <gnutt@nuttx.org>
|
||||||
|
# Author: Mark Olsson <post@markolsson.se>
|
||||||
|
#
|
||||||
|
# Redistribution and use in source and binary forms, with or without
|
||||||
|
# modification, are permitted provided that the following conditions
|
||||||
|
# are met:
|
||||||
|
#
|
||||||
|
# 1. Redistributions of source code must retain the above copyright
|
||||||
|
# notice, this list of conditions and the following disclaimer.
|
||||||
|
# 2. Redistributions in binary form must reproduce the above copyright
|
||||||
|
# notice, this list of conditions and the following disclaimer in
|
||||||
|
# the documentation and/or other materials provided with the
|
||||||
|
# distribution.
|
||||||
|
# 3. Neither the name NuttX nor the names of its contributors may be
|
||||||
|
# used to endorse or promote products derived from this software
|
||||||
|
# without specific prior written permission.
|
||||||
|
#
|
||||||
|
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||||
|
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||||
|
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||||
|
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||||
|
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||||
|
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||||
|
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||||
|
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||||
|
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||||
|
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||||
|
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||||
|
# POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
#
|
||||||
|
|
||||||
|
if [ "$_" = "$0" ] ; then
|
||||||
|
echo "You must source this script, not run it!" 1>&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
WD=`pwd`
|
||||||
|
if [ ! -x "setenv.sh" ]; then
|
||||||
|
echo "This script must be executed from the top-level NuttX build directory"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "${PATH_ORIG}" ]; then
|
||||||
|
export PATH_ORIG="${PATH}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# This is the Cygwin path to the location where I installed the Atmel GCC
|
||||||
|
# toolchain under Windows. You will also have to edit this if you install
|
||||||
|
# this toolchain in any other location
|
||||||
|
#export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/Atmel/Atmel Toolchain/ARM GCC/Native/4.7.3.99/arm-gnu-toolchain/bin"
|
||||||
|
|
||||||
|
# This is the Cygwin path to the location where I installed the CodeSourcery
|
||||||
|
# toolchain under windows. You will also have to edit this if you install
|
||||||
|
# the CodeSourcery toolchain in any other location
|
||||||
|
#export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/CodeSourcery/Sourcery G++ Lite/bin"
|
||||||
|
#export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/CodeSourcery/Sourcery_CodeBench_Lite_for_ARM_EABI/bin"
|
||||||
|
# export TOOLCHAIN_BIN="/cygdrive/c/Users/MyName/MentorGraphics/Sourcery_CodeBench_Lite_for_ARM_EABI/bin"
|
||||||
|
|
||||||
|
# This is the location where I installed the ARM "GNU Tools for ARM Embedded Processors"
|
||||||
|
# You can this free toolchain here https://launchpad.net/gcc-arm-embedded
|
||||||
|
export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/GNU Tools ARM Embedded/4.9 2015q2/bin"
|
||||||
|
|
||||||
|
# This is the path to the location where I installed the devkitARM toolchain
|
||||||
|
# You can get this free toolchain from http://devkitpro.org/ or http://sourceforge.net/projects/devkitpro/
|
||||||
|
#export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/devkitARM/bin"
|
||||||
|
|
||||||
|
# This is the Cygwin path to the location where I build the buildroot
|
||||||
|
# toolchain.
|
||||||
|
# export TOOLCHAIN_BIN="${WD}/../buildroot/build_arm_nofpu/staging_dir/bin"
|
||||||
|
|
||||||
|
# Add the path to the toolchain to the PATH varialble
|
||||||
|
export PATH="${TOOLCHAIN_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||||
|
|
||||||
|
echo "PATH : ${PATH}"
|
||||||
@@ -297,8 +297,11 @@
|
|||||||
* -- ----- --------- -----
|
* -- ----- --------- -----
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define GPIO_USART6_RX GPIO_USART6_RX_1
|
#define GPIO_USART6_RX GPIO_USART6_RX_1
|
||||||
#define GPIO_USART6_TX GPIO_USART6_TX_1
|
#define GPIO_USART6_TX GPIO_USART6_TX_1
|
||||||
|
|
||||||
|
#define GPIO_USART3_RX GPIO_USART3_RX_3
|
||||||
|
#define GPIO_USART3_TX GPIO_USART3_TX_3
|
||||||
|
|
||||||
/* The STM32 F7 connects to a SMSC LAN8742A PHY using these pins:
|
/* The STM32 F7 connects to a SMSC LAN8742A PHY using these pins:
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user