Merge branch 'master' of bitbucket.org:nuttx/nuttx

This commit is contained in:
Gregory Nutt 2019-07-08 06:42:59 -06:00
commit 96daade19b
13 changed files with 96 additions and 0 deletions

View File

@ -281,6 +281,13 @@ config RRLOAD_BINARY
Create nuttx.rr in the rrload binary format used with
BSPs from www.ridgerun.com using the tools/mkimage.sh script.
config CXD56_BINARY
bool "spk binary format"
default n
---help---
Create nuttx.spk binary format used on spresense board and boards
based on cxd56xx arch.
config INTELHEX_BINARY
bool "Intel HEX binary format"
default n

View File

@ -26,6 +26,7 @@ CONFIG_COMPOSITE_MSFT_OS_DESCRIPTORS=y
CONFIG_COMPOSITE_PRODUCTID=0x0bc2
CONFIG_COMPOSITE_VENDORID=0x054c
CONFIG_COMPOSITE_VENDORSTR="Sony"
CONFIG_CXD56_BINARY=y
CONFIG_CXD56_DMAC_SPI4_RX=y
CONFIG_CXD56_DMAC_SPI4_TX=y
CONFIG_CXD56_I2C0=y

View File

@ -19,6 +19,7 @@ CONFIG_BOARD_LOOPSPERMSEC=5434
CONFIG_BOOT_RUNFROMISRAM=y
CONFIG_BUILTIN=y
CONFIG_CLOCK_MONOTONIC=y
CONFIG_CXD56_BINARY=y
CONFIG_CXD56_ADC=y
CONFIG_CXD56_CISIF=y
CONFIG_CXD56_HPADC0=y

View File

@ -17,6 +17,7 @@ CONFIG_BOARD_LOOPSPERMSEC=5434
CONFIG_BOOT_RUNFROMISRAM=y
CONFIG_BUILTIN=y
CONFIG_CLOCK_MONOTONIC=y
CONFIG_CXD56_BINARY=y
CONFIG_CXD56_I2C0=y
CONFIG_CXD56_I2C=y
CONFIG_CXD56_SPI4=y

View File

@ -21,6 +21,7 @@ CONFIG_BOOT_RUNFROMISRAM=y
CONFIG_BUILTIN=y
CONFIG_CLOCK_MONOTONIC=y
CONFIG_CODECS_HASH_MD5=y
CONFIG_CXD56_BINARY=y
CONFIG_CXD56_SDIO=y
CONFIG_CXD56_USBDEV=y
CONFIG_DEBUG_FULLOPT=y

View File

@ -39,6 +39,7 @@ DEPPATH = --dep-path .
ASRCS =
CSRCS =
CSRCS += cxd56_main.c
CSRCS += cxd56_boot.c
CSRCS += cxd56_clock.c
CSRCS += cxd56_bringup.c

View File

@ -0,0 +1,56 @@
/****************************************************************************
* bsp/board/spresense/src/spresense_main.c
*
* Copyright 2018 Sony Semiconductor Solutions Corporation
*
* 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 of Sony Semiconductor Solutions Corporation 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.
*
****************************************************************************/
/****************************************************************************
* Included Files
****************************************************************************/
#include <nuttx/config.h>
#include <nuttx/compiler.h>
/****************************************************************************
* Public Functions
****************************************************************************/
/* This function is provided outside exported SDK, therefore here is defined
* as weak symbol to avoid link error.
*/
int nsh_main(int argc, char *argv[]);
int weak_function spresense_main(int argc, char *argv[])
{
return nsh_main(argc, argv);
}

View File

@ -26,6 +26,7 @@ CONFIG_COMPOSITE_MSFT_OS_DESCRIPTORS=y
CONFIG_COMPOSITE_PRODUCTID=0x0bc2
CONFIG_COMPOSITE_VENDORID=0x054c
CONFIG_COMPOSITE_VENDORSTR="Sony"
CONFIG_CXD56_BINARY=y
CONFIG_CXD56_I2C0=y
CONFIG_CXD56_I2C=y
CONFIG_CXD56_SDIO=y

View File

@ -19,6 +19,7 @@ CONFIG_BOARD_LOOPSPERMSEC=5434
CONFIG_BOOT_RUNFROMISRAM=y
CONFIG_BUILTIN=y
CONFIG_CLOCK_MONOTONIC=y
CONFIG_CXD56_BINARY=y
CONFIG_CXD56_I2C0=y
CONFIG_CXD56_I2C=y
CONFIG_CXD56_SDIO=y

View File

@ -20,6 +20,7 @@ CONFIG_BOOT_RUNFROMISRAM=y
CONFIG_BUILTIN=y
CONFIG_CLOCK_MONOTONIC=y
CONFIG_CODECS_HASH_MD5=y
CONFIG_CXD56_BINARY=y
CONFIG_CXD56_DMAC_SPI5_RX=y
CONFIG_CXD56_DMAC_SPI5_TX=y
CONFIG_CXD56_SDIO=y

1
tools/.gitignore vendored
View File

@ -20,3 +20,4 @@
/*.dSYM
/.k2h-body.dat
/.k2h-apndx.dat
/cxd56

View File

@ -442,6 +442,18 @@ ifeq ($(CONFIG_RAW_BINARY),y)
@echo "CP: $(NUTTXNAME).bin"
$(Q) $(OBJCOPY) $(OBJCOPYARGS) -O binary $(BIN) $(NUTTXNAME).bin
endif
ifeq ($(CONFIG_CXD56_BINARY),y)
$(Q) if [ ! -f "tools/cxd56/mkspk" ] ; then \
echo ""; \
echo "Please run the following command to clone the needed tools"; \
echo "git clone https://github.com/sonydevworld/cxd56/ tools/cxd56"; \
echo ""; \
echo "run make again to create the nuttx.spk image."; \
else \
echo "Generating: $(NUTTXNAME).spk"; \
tools/cxd56/mkspk -c2 nuttx nuttx nuttx.spk; \
fi
endif
ifeq ($(CONFIG_UBOOT_UIMAGE),y)
@echo "MKIMAGE: uImage"
$(Q) mkimage -A $(CONFIG_ARCH) -O linux -C none -T kernel -a $(CONFIG_UIMAGE_LOAD_ADDRESS) \

View File

@ -451,6 +451,18 @@ ifeq ($(CONFIG_RAW_BINARY),y)
@echo "CP: $(NUTTXNAME).bin"
$(Q) $(OBJCOPY) $(OBJCOPYARGS) -O binary $(BIN) $(NUTTXNAME).bin
endif
ifeq ($(CONFIG_CXD56_BINARY),y)
$(Q) if [ ! -f "tools/cxd56/mkspk.exe" ] ; then \
echo ""; \
echo "Please run the following command to clone the needed tools"; \
echo "git clone https://github.com/sonydevworld/cxd56/ tools\cxd56"; \
echo ""; \
echo "run make again to create the nuttx.spk image."; \
else \
echo "Generating: $(NUTTXNAME).spk"; \
tools\cxd56\mkspk.exe -c2 nuttx nuttx nuttx.spk; \
fi
endif
# $(BIN)
#