Update README files
This commit is contained in:
parent
879d43a584
commit
a232ccc3ab
@ -1,22 +1,38 @@
|
|||||||
README
|
README
|
||||||
^^^^^
|
^^^^^
|
||||||
|
|
||||||
This is the README file for the port of NuttX to the Arduino Mega 2560 Rev3.
|
This is the README file for the port of NuttX to the Arduino Mega 2560 Rev3.
|
||||||
|
|
||||||
https://www.arduino.cc/en/Main/ArduinoBoardMega2560
|
https://www.arduino.cc/en/Main/ArduinoBoardMega2560
|
||||||
|
|
||||||
The board is based on ATMega2560 chip from Atmel
|
The board is based on ATMega2560 chip from Atmel
|
||||||
|
|
||||||
http://www.atmel.com/devices/atmega2560.aspx
|
|
||||||
|
|
||||||
|
http://www.atmel.com/devices/atmega2560.aspx
|
||||||
|
|
||||||
Toolchain
|
Toolchain
|
||||||
^^^^^^^^^
|
^^^^^^^^^
|
||||||
|
|
||||||
Right now only Atmel's AVR8 Toolchain is supported. You can get it from
|
Right now only Atmel's AVR8 Toolchain is supported. You can get it from
|
||||||
|
|
||||||
http://www.atmel.com/tools/atmelavrtoolchainforwindows.aspx
|
http://www.atmel.com/tools/atmelavrtoolchainforwindows.aspx
|
||||||
|
|
||||||
It is basically WinAVR compatible so sub-projects may define WinAVR as a
|
It is basically WinAVR compatible so sub-projects may define WinAVR as a
|
||||||
tool-chain but specify path to the Atmel AVR8 in path. See
|
tool-chain but specify path to the Atmel AVR8 in path. See
|
||||||
arduino-mega2560/hello for example.
|
arduino-mega2560/hello for example.
|
||||||
|
|
||||||
|
MEMX
|
||||||
|
^^^^
|
||||||
|
|
||||||
|
If you use the GCC AVR toolchain from the Atmel Studio, then you can
|
||||||
|
enable suppport for the MEMX storage:
|
||||||
|
|
||||||
|
CONFIG_AVR_HAS_MEMX_PTR=y
|
||||||
|
|
||||||
|
If this support is enabled, then all strings will be saved in FLASH and
|
||||||
|
standard string-oriented interfaces such printf() will change so that
|
||||||
|
they accept memx pointers.
|
||||||
|
|
||||||
|
This means that (1) ALL strings must lie in FLASH, and (2) since the
|
||||||
|
strings are moved from SRAM to FLASH, you will save a LOT of SRAM usage
|
||||||
|
in some configurations that use a lot of string memory (such as the
|
||||||
|
ostest and nsh configurations).
|
||||||
|
@ -37,6 +37,12 @@ include ${TOPDIR}/.config
|
|||||||
include ${TOPDIR}/tools/Config.mk
|
include ${TOPDIR}/tools/Config.mk
|
||||||
include ${TOPDIR}/arch/avr/src/avr/Toolchain.defs
|
include ${TOPDIR}/arch/avr/src/avr/Toolchain.defs
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_AVR_HAS_MEMX_PTR),y)
|
||||||
|
LDSCRIPT = memx.ld
|
||||||
|
else
|
||||||
|
LDSCRIPT = nomemx.ld
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(WINTOOL),y)
|
ifeq ($(WINTOOL),y)
|
||||||
# Windows-native toolchains
|
# Windows-native toolchains
|
||||||
DIRLINK = $(TOPDIR)/tools/copydir.sh
|
DIRLINK = $(TOPDIR)/tools/copydir.sh
|
||||||
@ -44,13 +50,13 @@ ifeq ($(WINTOOL),y)
|
|||||||
MKDEP = $(TOPDIR)/tools/mknulldeps.sh
|
MKDEP = $(TOPDIR)/tools/mknulldeps.sh
|
||||||
ARCHINCLUDES = -I. -isystem "${shell cygpath -w $(TOPDIR)/include}"
|
ARCHINCLUDES = -I. -isystem "${shell cygpath -w $(TOPDIR)/include}"
|
||||||
ARCHXXINCLUDES = $(ARCHINCLUDES) "${shell cygpath -w $(TOPDIR)/include/cxx}"
|
ARCHXXINCLUDES = $(ARCHINCLUDES) "${shell cygpath -w $(TOPDIR)/include/cxx}"
|
||||||
ARCHSCRIPT = -T "${shell cygpath -w $(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/scripts/nomemx.ld}"
|
ARCHSCRIPT = -T "${shell cygpath -w $(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/scripts/$(LDSCRIPT)}"
|
||||||
else
|
else
|
||||||
# Linux/Cygwin-native toolchain
|
# Linux/Cygwin-native toolchain
|
||||||
MKDEP = $(TOPDIR)/tools/mkdeps.sh
|
MKDEP = $(TOPDIR)/tools/mkdeps.sh
|
||||||
ARCHINCLUDES = -I. -isystem "$(TOPDIR)/include"
|
ARCHINCLUDES = -I. -isystem "$(TOPDIR)/include"
|
||||||
ARCHXXINCLUDES = $(ARCHINCLUDES) -isystem "$(TOPDIR)/include/cxx"
|
ARCHXXINCLUDES = $(ARCHINCLUDES) -isystem "$(TOPDIR)/include/cxx"
|
||||||
ARCHSCRIPT = -T$(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/scripts/nomemx.ld
|
ARCHSCRIPT = -T$(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/scripts/$(LDSCRIPT)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
CC = $(CROSSDEV)gcc
|
CC = $(CROSSDEV)gcc
|
||||||
@ -72,6 +78,12 @@ endif
|
|||||||
|
|
||||||
ARCHCFLAGS = -fno-builtin
|
ARCHCFLAGS = -fno-builtin
|
||||||
ARCHCXXFLAGS = -fno-builtin -fno-exceptions
|
ARCHCXXFLAGS = -fno-builtin -fno-exceptions
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_AVR_HAS_MEMX_PTR),y)
|
||||||
|
ARCHCFLAGS += -fdata-sections
|
||||||
|
ARCHCXXFLAGS += -fdata-sections
|
||||||
|
endif
|
||||||
|
|
||||||
ARCHWARNINGS = -Wall -Wstrict-prototypes -Wshadow -Wundef
|
ARCHWARNINGS = -Wall -Wstrict-prototypes -Wshadow -Wundef
|
||||||
ARCHWARNINGSXX = -Wall -Wshadow -Wundef
|
ARCHWARNINGSXX = -Wall -Wshadow -Wundef
|
||||||
ARCHDEFINES =
|
ARCHDEFINES =
|
||||||
|
@ -17,6 +17,7 @@ Contents
|
|||||||
o Windows Native Toolchains
|
o Windows Native Toolchains
|
||||||
o NuttX buildroot Toolchain
|
o NuttX buildroot Toolchain
|
||||||
o avr-libc
|
o avr-libc
|
||||||
|
o MEMX
|
||||||
o Teensy++ Configuration Options
|
o Teensy++ Configuration Options
|
||||||
o Configurations
|
o Configurations
|
||||||
|
|
||||||
@ -387,6 +388,23 @@ Build Notes:
|
|||||||
|
|
||||||
make install
|
make install
|
||||||
|
|
||||||
|
MEMX
|
||||||
|
^^^^
|
||||||
|
|
||||||
|
If you use the GCC AVR toolchain from the Atmel Studio, then you can
|
||||||
|
enable suppport for the MEMX storage:
|
||||||
|
|
||||||
|
CONFIG_AVR_HAS_MEMX_PTR=y
|
||||||
|
|
||||||
|
If this support is enabled, then all strings will be saved in FLASH and
|
||||||
|
standard string-oriented interfaces such printf() will change so that
|
||||||
|
they accept memx pointers.
|
||||||
|
|
||||||
|
This means that (1) ALL strings must lie in FLASH, and (2) since the
|
||||||
|
strings are moved from SRAM to FLASH, you will save a LOT of SRAM usage
|
||||||
|
in some configurations that use a lot of string memory (such as the
|
||||||
|
ostest and nsh configurations).
|
||||||
|
|
||||||
Teensy++ Configuration Options
|
Teensy++ Configuration Options
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user