mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-30 01:03:33 +08:00
Add a text for the new composite USB device
git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@4341 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
@@ -110,6 +110,71 @@ examples/can
|
||||
built-in, the default is 32. Otherwise messages are sent and received
|
||||
indefinitely.
|
||||
|
||||
examples/composite
|
||||
^^^^^^^^^^^^^^^^^^
|
||||
|
||||
This example test a USB composite device. The only supported composite is
|
||||
CDC/ACM serial with a USB mass storage device.
|
||||
|
||||
Required overall configuration:
|
||||
|
||||
CONFIG_USBDEV - USB device support
|
||||
CONFIG_USBDEV_COMPOSITE - USB composite device support
|
||||
CONFIG_CDCACM - USB CDC/ACM serial device support
|
||||
CONFIG_CDCACM_COMPOSITE - USB CDC/ACM serial composite device support
|
||||
CONFIG_USBMSC - USB mass storage device support
|
||||
CONFIG_USBMSC_COMPOSITE - USB mass storage composite device support
|
||||
|
||||
CONFIG_NSH_BUILTIN_APPS
|
||||
This example can be built as two NSH "built-in" commands if this option
|
||||
is selected: 'msconn' will connect the USB mass storage device; 'msdis'
|
||||
will disconnect the USB storage device.
|
||||
|
||||
Configuration options unique to this example:
|
||||
|
||||
CONFIG_EXAMPLES_COMPOSITE_DEBUGMM
|
||||
Enables some debug tests to check for memory usage and memory leaks.
|
||||
|
||||
CONFIG_EXAMPLES_COMPOSITE_NLUNS
|
||||
Defines the number of logical units (LUNs) exported by the USB storage
|
||||
driver. Each LUN corresponds to one exported block driver (or partition
|
||||
of a block driver). May be 1, 2, or 3. Default is 1.
|
||||
CONFIG_EXAMPLES_COMPOSITE_DEVMINOR1
|
||||
The minor device number of the block driver for the first LUN. For
|
||||
example, N in /dev/mmcsdN. Used for registering the block driver. Default
|
||||
is zero.
|
||||
CONFIG_EXAMPLES_COMPOSITE_DEVPATH1
|
||||
The full path to the registered block driver. Default is "/dev/mmcsd0"
|
||||
CONFIG_EXAMPLES_COMPOSITE_DEVMINOR2 and CONFIG_EXAMPLES_COMPOSITE_DEVPATH2
|
||||
Similar parameters that would have to be provided if CONFIG_EXAMPLES_COMPOSITE_NLUNS
|
||||
is 2 or 3. No defaults.
|
||||
CONFIG_EXAMPLES_COMPOSITE_DEVMINOR3 and CONFIG_EXAMPLES_COMPOSITE_DEVPATH2
|
||||
Similar parameters that would have to be provided if CONFIG_EXAMPLES_COMPOSITE_NLUNS
|
||||
is 3. No defaults.
|
||||
CONFIG_EXAMPLES_COMPOSITE_BUFLEN. Default 256.
|
||||
|
||||
CONFIG_EXAMPLES_COMPOSITE_TTYUSB - The minor number of the USB serial device.
|
||||
Default is zero (corresponding to /dev/ttyUSB0. Default is zero.
|
||||
CCONFIG_EXAMPLES_COMPOSITE_SERDEV - The string corresponding to
|
||||
CONFIG_EXAMPLES_COMPOSITE_TTYUSB. The default is "/dev/ttyUSB0".
|
||||
CONFIG_EXAMPLES_COMPOSITE_BUFSIZE - The size of the serial I/O buffer in
|
||||
bytes. Default 256 byters.
|
||||
|
||||
If CONFIG_USBDEV_TRACE is enabled (or CONFIG_DEBUG and CONFIG_DEBUG_USB), then
|
||||
the example code will also manage the USB trace output. The amount of trace output
|
||||
can be controlled using:
|
||||
|
||||
CONFIG_EXAMPLES_COMPOSITE_TRACEINIT
|
||||
Show initialization events
|
||||
CONFIG_EXAMPLES_COMPOSITE_TRACECLASS
|
||||
Show class driver events
|
||||
CONFIG_EXAMPLES_COMPOSITE_TRACETRANSFERS
|
||||
Show data transfer events
|
||||
CONFIG_EXAMPLES_COMPOSITE_TRACECONTROLLER
|
||||
Show controller events
|
||||
CONFIG_EXAMPLES_COMPOSITE_TRACEINTERRUPTS
|
||||
Show interrupt-related events.
|
||||
|
||||
examples/dhcpd
|
||||
^^^^^^^^^^^^^^
|
||||
|
||||
@@ -1046,7 +1111,7 @@ examples/usbstorage
|
||||
|
||||
CONFIG_EXAMPLES_USBMSC_BUILTIN
|
||||
This example can be built as two NSH "built-in" commands if this option
|
||||
is selection: 'msconn' will connect the USB mass storage device; 'msdis'
|
||||
is selected: 'msconn' will connect the USB mass storage device; 'msdis'
|
||||
will disconnect the USB storage device.
|
||||
CONFIG_EXAMPLES_USBMSC_NLUNS
|
||||
Defines the number of logical units (LUNs) exported by the USB storage
|
||||
|
||||
Reference in New Issue
Block a user