summaryrefslogtreecommitdiff
path: root/nuttx/configs
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-02-29 21:53:28 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-02-29 21:53:28 +0000
commit5faa1bd9cefb4e7a2319faaa5b36da9140aba16a (patch)
tree358673f55511cec814532fbf08a11847936c38cf /nuttx/configs
parent286b14b0c9d2dbad599e80cac9c269c9cd96b408 (diff)
downloadpx4-nuttx-5faa1bd9cefb4e7a2319faaa5b36da9140aba16a.tar.gz
px4-nuttx-5faa1bd9cefb4e7a2319faaa5b36da9140aba16a.tar.bz2
px4-nuttx-5faa1bd9cefb4e7a2319faaa5b36da9140aba16a.zip
A little more work (but not much progress) on the PIC32 USB device driver
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@4440 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/configs')
-rw-r--r--nuttx/configs/sure-pic32mx/README.txt32
-rw-r--r--nuttx/configs/sure-pic32mx/nsh/appconfig39
-rw-r--r--nuttx/configs/sure-pic32mx/nsh/defconfig39
3 files changed, 92 insertions, 18 deletions
diff --git a/nuttx/configs/sure-pic32mx/README.txt b/nuttx/configs/sure-pic32mx/README.txt
index 0c91f3289..dabdd541d 100644
--- a/nuttx/configs/sure-pic32mx/README.txt
+++ b/nuttx/configs/sure-pic32mx/README.txt
@@ -459,8 +459,32 @@ Where <subdir> is one of the following:
Configures the NuttShell (nsh) located at apps/examples/nsh. The
Configuration enables only the serial NSH interface.
- The examples/usbterm program can be included as an NSH built-in
- function by defined the following in your .config file:
+ Several USB device configurations can be enabled and included
+ as NSH built-in built in functions. All require the following
+ basic setup in your .config to enable USB device support:
+
+ CONFIG_USBEV=y : Enable basic USB device support
+ CONFIG_PIC32MX_USBDEV=y : Enable PIC32 USB device support
- CONFIG_USBEV=y : Enable basic USB device support
- CONFIG_PIC32MX_USBDEV=y : Enable PIC32 USB device support
+ examples/usbterm - This option can be enabled by uncommenting
+ the following line in the appconfig file:
+
+ CONFIGURED_APPS += examples/usbterm
+
+ And by enabling one of the USB serial devices:
+
+ CONFIG_PL2303=y : Enable the Prolifics PL2303 emulation
+ CONFIG_CDCACM=y : or the CDC/ACM serial driver (not both)
+
+ examples/cdcacm - The examples/cdcacm program can be included as an
+ function by uncommenting the following line in the appconfig file:
+
+ CONFIGURED_APPS += examples/cdcacm
+
+ and defining the following in your .config file:
+
+ CONFIG_CDCACM=y : Enable the CDCACM device
+
+ examples/usbstorage - There are some hooks in the appconfig file
+ to enable the USB mass storage device. However, this device cannot
+ work until support for the SD card is also incorporated.
diff --git a/nuttx/configs/sure-pic32mx/nsh/appconfig b/nuttx/configs/sure-pic32mx/nsh/appconfig
index abf0b38a6..2263c5a3e 100644
--- a/nuttx/configs/sure-pic32mx/nsh/appconfig
+++ b/nuttx/configs/sure-pic32mx/nsh/appconfig
@@ -33,32 +33,45 @@
#
############################################################################
+############################################################################
# Path to example in apps/examples containing the user_start entry point
+############################################################################
CONFIGURED_APPS += examples/nsh
+############################################################################
# The NSH application library
+############################################################################
CONFIGURED_APPS += system/readline
CONFIGURED_APPS += nshlib
-# Applications configured as an NX built-in commands
+############################################################################
+# USB device configurations
+############################################################################
-ifeq ($(CONFIG_NET),y)
-CONFIGURED_APPS += netutils/uiplib
-CONFIGURED_APPS += netutils/resolv
-CONFIGURED_APPS += netutils/webclient
-CONFIGURED_APPS += netutils/tftpc
-endif
+ifeq ($(CONFIG_PIC32MX_USBDEV),y)
+
+# USB Mass Storage Class device configurations
-ifeq ($(CONFIG_PWM),y)
-CONFIGURED_APPS += examples/pwm
+ifeq ($(CONFIG_USBMSC),y)
+# Uncomment to enable the examples/usbstorage built-in
+# CONFIGURED_APPS += examples/usbstorage
endif
-ifeq ($(CONFIG_CAN),y)
-CONFIGURED_APPS += examples/can
+# USB CDC/ACM serial device configurations
+
+ifeq ($(CONFIG_CDCACM),y)
+# Uncomment to enable the examples/cdcacm built-in
+# CONFIGURED_APPS += examples/cdcacm
+# Uncomment the following to enable the examples/usbterm built-in
+# CONFIGURED_APPS += examples/usbterm
endif
-ifeq ($(CONFIG_PIC32MX_USBDEV),y)
-CONFIGURED_APPS += examples/usbterm
+# Prolifics PL2303 emulation configurations
+
+ifeq ($(CONFIG_PL2303),y)
+# Uncomment the following to enable the examples/usbterm built-in
+# CONFIGURED_APPS += examples/usbterm
+endif
endif
diff --git a/nuttx/configs/sure-pic32mx/nsh/defconfig b/nuttx/configs/sure-pic32mx/nsh/defconfig
index f90d09bcc..bd8e9a8b7 100644
--- a/nuttx/configs/sure-pic32mx/nsh/defconfig
+++ b/nuttx/configs/sure-pic32mx/nsh/defconfig
@@ -226,6 +226,13 @@ CONFIG_UART1_2STOP=0
CONFIG_UART2_2STOP=0
#
+# PIC32MX-specific USB device setup
+#
+CONFIG_PIC32MX_USBDEV_REGDEBUG=n
+CONFIG_PIC32MX_USBDEV_BDTDEBUG=n
+CONFIG_PIC32MX_USBDEV_PINGPONG=n
+
+#
# General build options
#
# CONFIG_RRLOAD_BINARY - make the rrload binary format used with
@@ -349,7 +356,6 @@ CONFIG_DEBUG_VERBOSE=n
CONFIG_DEBUG_SYMBOLS=n
CONFIG_DEBUG_SCHED=n
CONFIG_DEBUG_USB=n
-CONFIG_PIC32MX_USBDEV_REGDEBUG=n
CONFIG_HAVE_CXX=n
CONFIG_HAVE_CXXINITIALIZE=n
@@ -1032,6 +1038,37 @@ CONFIG_EXAMPLES_USBTERM_TRACECONTROLLER=n
CONFIG_EXAMPLES_USBTERM_TRACEINTERRUPTS=n
#
+# Settings for examples/cdcacm
+#
+# Configuration prequisites:
+#
+# CONFIG_USBDEV=y : USB device support must be enabled
+# CONFIG_CDCACM=y : The CDC/ACM driver must be built
+# CONFIG_NSH_BUILTIN_APPS : NSH built-in application support must be enabled
+#
+# Configuration options specific to this example:
+#
+# CONFIG_EXAMPLES_CDCACM_DEVMINOR
+# The minor number of the CDC/ACM device.
+# CONFIG_EXAMPLES_CDCACM_TRACEINIT
+# Show initialization events
+# CONFIG_EXAMPLES_CDCACM_TRACECLASS
+# Show class driver events
+# CONFIG_EXAMPLES_CDCACM_TRACETRANSFERS
+# Show data transfer events
+# CONFIG_EXAMPLES_CDCACM_TRACECONTROLLER
+# Show controller events
+# CONFIG_EXAMPLES_CDCACM_TRACEINTERRUPTS
+# Show interrupt-related events.
+#
+CONFIG_EXAMPLES_CDCACM_DEVMINOR=0
+CONFIG_EXAMPLES_CDCACM_TRACEINIT=n
+CONFIG_EXAMPLES_CDCACM_TRACECLASS=n
+CONFIG_EXAMPLES_CDCACM_TRACETRANSFERS=n
+CONFIG_EXAMPLES_CDCACM_TRACECONTROLLER=n
+CONFIG_EXAMPLES_CDCACM_TRACEINTERRUPTS=n
+
+#
# Stack and heap information
#
# CONFIG_BOOT_RUNFROMFLASH - Some configurations support XIP