Make sure that USB_STREAM_TIMEOUT_MS is set in the MassStorageHost ClassDriver demo, so that slow devices don't time out the data pipe. Increase pipe timeout in both MassStorageHost demos to 5 seconds to account for the really slow devices.
Fix TeensyHID bootloader not properly shutting down the USB interface to trigger a disconnection on the host before resetting the AVR.
This commit is contained in:
		
							parent
							
								
									3757b1760f
								
							
						
					
					
						commit
						2281750b5f
					
				
					 5 changed files with 11 additions and 6 deletions
				
			
		| 
						 | 
				
			
			@ -51,9 +51,9 @@ int main(void)
 | 
			
		|||
	
 | 
			
		||||
	while (RunBootloader)
 | 
			
		||||
	  USB_USBTask();
 | 
			
		||||
 | 
			
		||||
	/* Wait 100ms to give the host time to register the disconnection */
 | 
			
		||||
	_delay_ms(100);
 | 
			
		||||
	
 | 
			
		||||
	/* Turn off the USB interface, disconnect from the host */
 | 
			
		||||
	USB_ShutDown();
 | 
			
		||||
 | 
			
		||||
	/* Enable the watchdog and force a timeout to reset the AVR */
 | 
			
		||||
	wdt_enable(WDTO_250MS);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue