summaryrefslogtreecommitdiff
path: root/nuttx
diff options
context:
space:
mode:
Diffstat (limited to 'nuttx')
-rwxr-xr-xnuttx/configs/mbed/README.txt50
-rwxr-xr-xnuttx/configs/nucleus2g/README.txt6
-rw-r--r--nuttx/drivers/usbhost/usbhost_storage.c4
3 files changed, 55 insertions, 5 deletions
diff --git a/nuttx/configs/mbed/README.txt b/nuttx/configs/mbed/README.txt
index 6098fc88b..c4122a6f6 100755
--- a/nuttx/configs/mbed/README.txt
+++ b/nuttx/configs/mbed/README.txt
@@ -12,6 +12,7 @@ Contents
NuttX buildroot Toolchain
USB Device Controller Functions
mbed Configuration Options
+ USB Host Configuration
Configurations
Development Environment
@@ -305,7 +306,7 @@ mbed Configuration Options
CONFIG_NET_MULTICAST - Enable receipt of multicast (and unicast) frames.
Automatically set if CONFIG_NET_IGMP is selected.
- LPC17xx USB Configuration
+ LPC17xx USB Device Configuration
CONFIG_LPC17_USBDEV_FRAME_INTERRUPT
Handle USB Start-Of-Frame events.
@@ -320,6 +321,53 @@ mbed Configuration Options
CONFIG_LPC17_USBDEV_DMA
Enable lpc17xx-specific DMA support
+ LPC17xx USB Host Configuration
+
+ CONFIG_USBHOST_OHCIRAM_SIZE
+ Total size of OHCI RAM (in AHB SRAM Bank 1)
+ CONFIG_USBHOST_NEDS
+ Number of endpoint descriptors
+ CONFIG_USBHOST_TDBUFFERS
+ Number of transfer descriptor buffers
+ CONFIG_USBHOST_TDBUFSIZE
+ Size of one transfer descriptor buffer
+ CONFIG_USBHOST_IOBUFSIZE
+ Size of one end-user I/O buffer. This can be zero if the
+ application can guarantee that all end-user I/O buffers
+ reside in AHB SRAM.
+
+USB Host Configuration
+^^^^^^^^^^^^^^^^^^^^^^
+
+The NuttShell (NSH) mbed can be modified in order to support USB
+host operations. To make these modifications, do the following:
+
+1. First configure to build the NSH configuration from the top-level
+ NuttX directory:
+
+ cd tools
+ ./configure mbed/nsh
+ cd ..
+
+2. Then edit the top-level .config file to enable USB host. Make the
+ following changes:
+
+ CONFIG_LPC17_USBHOST=n
+ CONFIG_USBHOST=n
+ CONFIG_SCHED_WORKQUEUE=y
+
+When this change is made, NSH should be extended to support USB flash
+devices. When a FLASH device is inserted, you should see a device
+appear in the /dev (psuedo) directory. The device name should be
+like /dev/sda, /dev/sdb, etc. The USB mass storage device, is present
+it can be mounted from the NSH command line like:
+
+ ls /dev
+ mount -t vfat /dev/sda /mnt/flash
+
+Files on the connect USB flash device should then be accessible under
+the mountpoint /mnt/flash.
+
Configurations
^^^^^^^^^^^^^^
diff --git a/nuttx/configs/nucleus2g/README.txt b/nuttx/configs/nucleus2g/README.txt
index 4d88654c5..42be0f1bf 100755
--- a/nuttx/configs/nucleus2g/README.txt
+++ b/nuttx/configs/nucleus2g/README.txt
@@ -434,6 +434,7 @@ Nucleus 2G Configuration Options
Enable lpc17xx-specific DMA support
LPC17xx USB Host Configuration
+
CONFIG_USBHOST_OHCIRAM_SIZE
Total size of OHCI RAM (in AHB SRAM Bank 1)
CONFIG_USBHOST_NEDS
@@ -450,8 +451,9 @@ Nucleus 2G Configuration Options
USB Host Configuration
^^^^^^^^^^^^^^^^^^^^^^
-The NuttShell (NSH) Nucleus 2G can be modified in order to support
-USB host operations. To make these modifications, do the following:
+The NuttShell (NSH) Nucleus 2G configuration can be modified in order
+to support USB host operations. To make these modifications, do the
+following:
1. First configure to build the NSH configuration from the top-level
NuttX directory:
diff --git a/nuttx/drivers/usbhost/usbhost_storage.c b/nuttx/drivers/usbhost/usbhost_storage.c
index e0f4dc4ad..5c44fd9f6 100644
--- a/nuttx/drivers/usbhost/usbhost_storage.c
+++ b/nuttx/drivers/usbhost/usbhost_storage.c
@@ -1085,14 +1085,14 @@ static inline int usbhost_cfgdesc(FAR struct usbhost_state_s *priv,
ret = DRVR_EPALLOC(priv->drvr, &boutdesc, &priv->bulkout);
if (ret != OK)
{
- udbg("ERROR: Failed to allocated Bulk OUT endpoint\n");
+ udbg("ERROR: Failed to allocate Bulk OUT endpoint\n");
return ret;
}
ret = DRVR_EPALLOC(priv->drvr, &bindesc, &priv->bulkin);
if (ret != OK)
{
- udbg("ERROR: Failed to allocated Bulk IN endpoint\n");
+ udbg("ERROR: Failed to allocate Bulk IN endpoint\n");
(void)DRVR_EPFREE(priv->drvr, priv->bulkout);
return ret;
}