diff --git a/Documentation/README.html b/Documentation/README.html index baf534cf50..8751b6b37c 100644 --- a/Documentation/README.html +++ b/Documentation/README.html @@ -8,7 +8,7 @@

NuttX README Files

-

Last Updated: November 1, 2016

+

Last Updated: November 4, 2016

@@ -150,6 +150,8 @@ nuttx/ | | `- README.txt | |- mirtoo/ | | `- README.txt + | |- misoc/ + | | `- README.txt | |- moteino-mega/ | | `- README.txt | |- mx1ads/ diff --git a/README.txt b/README.txt index 6203ab4cd1..d2a9a7b9fe 100644 --- a/README.txt +++ b/README.txt @@ -1366,6 +1366,8 @@ nuttx/ | | `- README.txt | |- mirtoo/ | | `- README.txt + | |- misoc/ + | | `- README.txt | |- moteino-mega/ | | `- README.txt | |- mx1ads/ diff --git a/arch/misoc/src/lm32/lm32.h b/arch/misoc/src/lm32/lm32.h index a04fb5e571..7b125578f0 100644 --- a/arch/misoc/src/lm32/lm32.h +++ b/arch/misoc/src/lm32/lm32.h @@ -109,8 +109,9 @@ * Public Data ****************************************************************************/ -extern volatile uint32_t *g_current_regs; +#ifndef __ASSEMBLY__ +extern volatile uint32_t *g_current_regs; extern uint32_t g_idle_topstack; /**************************************************************************** @@ -121,8 +122,6 @@ extern uint32_t g_idle_topstack; * Public Functions ****************************************************************************/ -#ifndef __ASSEMBLY__ - /* Low level initialization provided by board-level logic ******************/ void lm32_board_initialize(void); diff --git a/configs/misoc/README.txt b/configs/misoc/README.txt new file mode 100644 index 0000000000..1c20544513 --- /dev/null +++ b/configs/misoc/README.txt @@ -0,0 +1,54 @@ +Misoc README +============ + +Buildroot Toolchain +=================== + + A GNU GCC-based toolchain is assumed. The files */setenv.sh should + be modified to point to the correct path to the LM32 GCC toolchain (if + different from the default in your PATH variable). + + If you have no LM32 toolchain, one can be cloned from the NuttX + Bitbucket GIT repository (https://bitbucket.org/nuttx/buildroot). + This GNU toolchain builds and executes in the Linux or Cygwin environment. + + 1. You must have already configured Nuttx in /nuttx. + + cd tools + ./configure.sh misoc/ + + 2. Clone the latest buildroot package into + + git clone git@bitbucket.org:nuttx/buildroot.git + + or + + git clone https://patacongo@bitbucket.org/nuttx/buildroot.git + + 3. cd + + 4. cp lm32-elf-defconfig-6.1.0 .config + + 5. make oldconfig + + 6. make + + 7. Edit setenv.h, if necessary, so that the PATH variable includes + the path to the newly built binaries. + + By default, the tools will be at: + + /build_lm32/staging_dir/bin + + That location can be changed by reconfiguring the .config file. + + See the file configs/README.txt in the buildroot source tree. That has more + detailed PLUS some special instructions that you will need to follow if you + are building a LM32 toolchain for Cygwin under Windows. Also included in + that README file is a FAQ of frequent build issues that their work-arounds. + + In order to use the buildroot toolchain, you also must set the following + in your .config file: + + CONFIG_LM3S_TOOLCHAIN_BUILDROOT=y + diff --git a/configs/misoc/hello/defconfig b/configs/misoc/hello/defconfig index f7b4a0082d..b859e4ab2d 100644 --- a/configs/misoc/hello/defconfig +++ b/configs/misoc/hello/defconfig @@ -16,7 +16,7 @@ CONFIG_HOST_LINUX=y # # Build Configuration # -CONFIG_APPS_DIR="../apps" +# CONFIG_APPS_DIR="../apps" CONFIG_BUILD_FLAT=y # CONFIG_BUILD_2PASS is not set @@ -108,6 +108,8 @@ CONFIG_MISOC_UART1=y CONFIG_MISOC_UART=y CONFIG_MISOC_UART_RX_BUF_SIZE=64 CONFIG_MISOC_UART_TX_BUF_SIZE=64 +# CONFIG_LM32_TOOLCHAIN_BUILDROOT is not set +CONFIG_LM32_TOOLCHAIN_GNUL=y # # Architecture Options @@ -546,10 +548,10 @@ CONFIG_EXAMPLES_HELLO_STACKSIZE=2048 # CONFIG_EXAMPLES_NRF24L01TERM is not set # CONFIG_EXAMPLES_NSH is not set # CONFIG_EXAMPLES_NULL is not set +# CONFIG_EXAMPLES_NX is not set # CONFIG_EXAMPLES_NXFFS is not set # CONFIG_EXAMPLES_NXHELLO is not set # CONFIG_EXAMPLES_NXIMAGE is not set -# CONFIG_EXAMPLES_NX is not set # CONFIG_EXAMPLES_NXLINES is not set # CONFIG_EXAMPLES_NXTERM is not set # CONFIG_EXAMPLES_NXTEXT is not set diff --git a/configs/misoc/hello/setenv.sh b/configs/misoc/hello/setenv.sh index c66c878239..7ba5ee60e7 100644 --- a/configs/misoc/hello/setenv.sh +++ b/configs/misoc/hello/setenv.sh @@ -48,17 +48,11 @@ if [ -z "${PATH_ORIG}" ]; then export PATH_ORIG="${PATH}" fi -# This is the Cygwin path to the location where I installed the WinAVR -# toolchain under windows. This is *not* the default install -# location so you will probably have to edit this. You will also have -# to edit this if you install the Linux AVR toolchain as well -#export TOOLCHAIN_BIN="/cygdrive/c/WinAVR/bin" - # This is the Cygwin path to the location where I build the buildroot # toolchain. -#export TOOLCHAIN_BIN="${WD}/../buildroot/build_avr/staging_dir/bin" +export TOOLCHAIN_BIN="${WD}/../buildroot/build_lm32/staging_dir/bin" # Add the path to the toolchain to the PATH varialble -#export PATH="${TOOLCHAIN_BIN}:/sbin:/usr/sbin:${PATH_ORIG}" +export PATH="${TOOLCHAIN_BIN}:/sbin:/usr/sbin:${PATH_ORIG}" echo "PATH : ${PATH}"