Changed stream wait timeout counter to be 16-bit, so that very long timeout periods...
authorDean Camera <dean@fourwalledcubicle.com>
Tue, 3 Mar 2009 08:19:06 +0000 (08:19 +0000)
committerDean Camera <dean@fourwalledcubicle.com>
Tue, 3 Mar 2009 08:19:06 +0000 (08:19 +0000)
Mass Storage Host demo now uses a USB_STREAM_TIMEOUT_MS of two seconds to maintain compatibility with poorly designed devices.

Demos/MassStorageHost/MassStoreCommands.c
Demos/MassStorageHost/makefile

index c4b315b..f4143ad 100644 (file)
@@ -41,8 +41,9 @@
  *        may be neccesary to retry the functions in the module several times\r
  *        after they have returned and error to successfully send the command\r
  *        to the device. Some devices may also need to have the stream function\r
  *        may be neccesary to retry the functions in the module several times\r
  *        after they have returned and error to successfully send the command\r
  *        to the device. Some devices may also need to have the stream function\r
- *        timeout period extended beyond 100ms by defining USB_STREAM_TIMEOUT_MS\r
- *        to a larger value in the project makefile and passing it to the compiler\r
+ *        timeout period extended beyond 100ms (some badly designed devices exceeding\r
+ *        1.5 seconds occasionally) by defining USB_STREAM_TIMEOUT_MS to a\r
+ *        larger value in the project makefile and passing it to the compiler\r
  *        via the -D switch.\r
  */\r
  \r
  *        via the -D switch.\r
  */\r
  \r
index fb04798..2608b76 100644 (file)
@@ -180,6 +180,7 @@ CSTANDARD = -std=gnu99
 CDEFS  = -DF_CPU=$(F_CPU)UL -DF_CLOCK=$(F_CLOCK)UL -DBOARD=BOARD_$(BOARD)\r
 CDEFS += -DUSE_NONSTANDARD_DESCRIPTOR_NAMES -DNO_STREAM_CALLBACKS -DUSB_HOST_ONLY\r
 CDEFS += -DUSE_STATIC_OPTIONS="(USB_OPT_REG_ENABLED | USB_OPT_AUTO_PLL)"\r
 CDEFS  = -DF_CPU=$(F_CPU)UL -DF_CLOCK=$(F_CLOCK)UL -DBOARD=BOARD_$(BOARD)\r
 CDEFS += -DUSE_NONSTANDARD_DESCRIPTOR_NAMES -DNO_STREAM_CALLBACKS -DUSB_HOST_ONLY\r
 CDEFS += -DUSE_STATIC_OPTIONS="(USB_OPT_REG_ENABLED | USB_OPT_AUTO_PLL)"\r
+CDEFS += -DUSB_STREAM_TIMEOUT_MS=2000\r
 \r
 \r
 # Place -D or -U options here for ASM sources\r
 \r
 \r
 # Place -D or -U options here for ASM sources\r