summaryrefslogtreecommitdiff
path: root/nuttx
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-06-10 21:03:38 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-06-10 21:03:38 +0000
commit1376ded6e0aebc3d6d1062518ed99592e9cc1e63 (patch)
treeebffe4b73276f07d33faa7296227efd55947f4c5 /nuttx
parentab6d662a0d84dfb96eb966470cd91fc2bacc5a2b (diff)
downloadpx4-nuttx-1376ded6e0aebc3d6d1062518ed99592e9cc1e63.tar.gz
px4-nuttx-1376ded6e0aebc3d6d1062518ed99592e9cc1e63.tar.bz2
px4-nuttx-1376ded6e0aebc3d6d1062518ed99592e9cc1e63.zip
Add configuratin options to control the PIC32 configuration words
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3691 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx')
-rw-r--r--nuttx/TODO26
-rwxr-xr-xnuttx/configs/micropendous3/ostest/setenv.sh4
-rw-r--r--nuttx/configs/pcblogic-pic32mx/README.txt19
-rw-r--r--nuttx/configs/pcblogic-pic32mx/ostest/defconfig25
-rwxr-xr-xnuttx/configs/pcblogic-pic32mx/ostest/setenv.sh6
5 files changed, 75 insertions, 5 deletions
diff --git a/nuttx/TODO b/nuttx/TODO
index 7345d5b60..64cb151fa 100644
--- a/nuttx/TODO
+++ b/nuttx/TODO
@@ -1,4 +1,4 @@
-NuttX TODO List (Last updated June 6, 2011)
+NuttX TODO List (Last updated June 10, 2011)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
nuttx/
@@ -17,7 +17,7 @@ nuttx/
(1) Graphics subystem (graphics/)
(1) Pascal add-on (pcode/)
(1) Documentation (Documentation/)
- (4) Build system / Toolchains
+ (5) Build system / Toolchains
(7) Linux/Cywgin simulation (arch/sim)
(4) ARM (arch/arm/)
(1) ARM/C5471 (arch/arm/src/c5471/)
@@ -526,6 +526,28 @@ o Build system
Status: Open
Priority: Low
+ Descritpion: Logic in most setenv.sh files can create the following problem
+ on many platforms:
+
+ $ . ./setenv.sh
+ basename: invalid option -- 'b'
+ Try `basename --help' for more information.
+
+ The problem is that $0 is the current running shell which may include
+ a dash in front:
+
+ $ echo $0
+ -bash
+
+ But often is just /bin/bash (and the problem does not occur. The fix
+ is:
+
+ -if [ "$(basename $0)" = "setenv.sh" ]; then
+ +if [ "$_" = "$0" ] ; then
+ Status: Open
+ Priority: Low. Use of setenv.sh is optional and most platforms do not have
+ this problem. Scripts will be fixed one-at-a-time as is appropropriate.
+
o Linux/Cywgin simulation (arch/sim)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/nuttx/configs/micropendous3/ostest/setenv.sh b/nuttx/configs/micropendous3/ostest/setenv.sh
index 6c6e52c8e..fc11ea4c0 100755
--- a/nuttx/configs/micropendous3/ostest/setenv.sh
+++ b/nuttx/configs/micropendous3/ostest/setenv.sh
@@ -32,14 +32,14 @@
# POSSIBILITY OF SUCH DAMAGE.
#
-if [ "$(basename $0)" = "setenv.sh" ]; then
+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 toplevel NuttX build directory"
+ echo "This script must be executed from the top-level NuttX build directory"
exit 1
fi
diff --git a/nuttx/configs/pcblogic-pic32mx/README.txt b/nuttx/configs/pcblogic-pic32mx/README.txt
index c28737c83..6914184e9 100644
--- a/nuttx/configs/pcblogic-pic32mx/README.txt
+++ b/nuttx/configs/pcblogic-pic32mx/README.txt
@@ -376,6 +376,25 @@ PIC32MX Configuration Options
CONFIG_PIC32MX_FLASH - FLASH
CONFIG_PIC32MX_USB - USB
+ PIC32MX Configuration Settings
+ DEVCFG0:
+ CONFIG_PIC32MX_DEBUGGER - Background Debugger Enable. Default 3 (disabled). The
+ value 2 enables.
+ CONFIG_PIC32MX_ICESEL - In-Circuit Emulator/Debugger Communication Channel Select
+ Default 1 (PG2)
+ CONFIG_PIC32MX_PROGFLASHWP - Program FLASH write protect. Default 0xff (disabled)
+ CONFIG_PIC32MX_BOOTFLASHWP - Default 1 (disabled)
+ CONFIG_PIC32MX_CODEWP - Default 1 (disabled)
+ DEVCFG1: (All settings determined by selections in board.h)
+ DEVCFG2: (All settings determined by selections in board.h)
+ DEVCFG3:
+ CONFIG_PIC32MX_USBIDO - USB USBID Selection. Default 1 if USB enabled
+ (USBID pin is controlled by the USB module), but 0 (GPIO) otherwise.
+ CONFIG_PIC32MX_VBUSIO - USB VBUSON Selection (Default 1 if USB enabled
+ (VBUSON pin is controlled by the USB module, but 0 (GPIO) otherwise.
+ CONFIG_PIC32MX_WDENABLE - Enabled watchdog on power up. Default 0 (watchdog
+ can be enabled later by software).
+
The priority of interrupts may be specified. The value ranage of
priority is 4-31. The default (16) will be used if these any of these
are undefined.
diff --git a/nuttx/configs/pcblogic-pic32mx/ostest/defconfig b/nuttx/configs/pcblogic-pic32mx/ostest/defconfig
index 7966c1b49..318a60c93 100644
--- a/nuttx/configs/pcblogic-pic32mx/ostest/defconfig
+++ b/nuttx/configs/pcblogic-pic32mx/ostest/defconfig
@@ -146,6 +146,30 @@ CONFIG_PIC32MX_IOPORTF=y
CONFIG_PIC32MX_IOPORTG=y
#
+# PIC32MX Configuration Settings
+#
+# DEVCFG0:
+# CONFIG_PIC32MX_DEBUGGER - Background Debugger Enable. Default 3 (disabled). The
+# value 2 enables.
+# CONFIG_PIC32MX_ICESEL - In-Circuit Emulator/Debugger Communication Channel Select
+# Default 1 (PG2)
+# CONFIG_PIC32MX_PROGFLASHWP - Program FLASH write protect. Default 0xff (disabled)
+# CONFIG_PIC32MX_BOOTFLASHWP - Default 1 (disabled)
+# CONFIG_PIC32MX_CODEWP - Default 1 (disabled)
+# DEVCFG1: (All settings determined by selections in board.h)
+# DEVCFG2: (All settings determined by selections in board.h)
+# DEVCFG3:
+# CONFIG_PIC32MX_USBIDO - USB USBID Selection. Default 1 if USB enabled
+# (USBID pin is controlled by the USB module), but 0 (GPIO) otherwise.
+# CONFIG_PIC32MX_VBUSIO - USB VBUSON Selection (Default 1 if USB enabled
+# (VBUSON pin is controlled by the USB module, but 0 (GPIO) otherwise.
+# CONFIG_PIC32MX_WDENABLE - Enabled watchdog on power up. Default 0 (watchdog
+# can be enabled later by software).
+#
+CONFIG_PIC32MX_DEBUGGER=2
+CONFIG_PIC32MX_ICESEL=0
+
+#
# PIC32MX specific serial device driver settings
#
# CONFIG_UARTn_SERIAL_CONSOLE - selects the UARTn for the
@@ -295,6 +319,7 @@ CONFIG_HAVE_LIBM=n
CONFIG_DEBUG=n
CONFIG_DEBUG_VERBOSE=n
CONFIG_DEBUG_SYMBOLS=n
+CONFIG_DEBUG_SCHED=n
CONFIG_MM_REGIONS=1
CONFIG_ARCH_LOWPUTC=y
CONFIG_RR_INTERVAL=200
diff --git a/nuttx/configs/pcblogic-pic32mx/ostest/setenv.sh b/nuttx/configs/pcblogic-pic32mx/ostest/setenv.sh
index 7cdac129d..254434914 100755
--- a/nuttx/configs/pcblogic-pic32mx/ostest/setenv.sh
+++ b/nuttx/configs/pcblogic-pic32mx/ostest/setenv.sh
@@ -32,7 +32,7 @@
# POSSIBILITY OF SUCH DAMAGE.
#
-if [ "$(basename $0)" = "setenv.sh" ] ; then
+if [ "$_" = "$0" ] ; then
echo "You must source this script, not run it!" 1>&2
exit 1
fi
@@ -40,6 +40,10 @@ fi
if [ -z "${PATH_ORIG}" ]; then export PATH_ORIG="${PATH}"; fi
WD=`pwd`
+if [ ! -x "setenv.sh" ]; then
+ echo "This script must be executed from the top-level NuttX build directory"
+ exit 1
+fi
# This the Cygwin path to the location where I installed the MicroChip
# PIC32MX toolchain under windows. This is *not* the default install