Add extra LUFA TAR archive export exclusions.
[pub/USBasp.git] / Demos / Host / ClassDriver / AudioInputHost / AudioInputHost.c
index ab93721..3e4a69a 100644 (file)
@@ -1,13 +1,13 @@
 /*
              LUFA Library
 /*
              LUFA Library
-     Copyright (C) Dean Camera, 2011.
+     Copyright (C) Dean Camera, 2012.
 
   dean [at] fourwalledcubicle [dot] com
            www.lufa-lib.org
 */
 
 /*
 
   dean [at] fourwalledcubicle [dot] com
            www.lufa-lib.org
 */
 
 /*
-  Copyright 2011  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
 
   Permission to use, copy, modify, distribute, and sell this
   software and its documentation for any purpose is hereby granted
 
   Permission to use, copy, modify, distribute, and sell this
   software and its documentation for any purpose is hereby granted
@@ -96,7 +96,7 @@ ISR(TIMER0_COMPA_vect, ISR_BLOCK)
 
                LEDs_SetAllLEDs(LEDMask);
        }
 
                LEDs_SetAllLEDs(LEDMask);
        }
-       
+
        Pipe_SelectPipe(PrevPipe);
 }
 
        Pipe_SelectPipe(PrevPipe);
 }
 
@@ -174,6 +174,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
        {
                puts_P(PSTR("Error Enabling Audio Stream.\r\n"));
                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
        {
                puts_P(PSTR("Error Enabling Audio Stream.\r\n"));
                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
+               USB_Host_SetDeviceConfiguration(0);
                return;
        }
 
                return;
        }
 
@@ -184,6 +185,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
        {
                puts_P(PSTR("Error Setting Audio Sampling Frequency.\r\n"));
                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
        {
                puts_P(PSTR("Error Setting Audio Sampling Frequency.\r\n"));
                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
+               USB_Host_SetDeviceConfiguration(0);
                return;
        }
 
                return;
        }
 
@@ -191,7 +193,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
        TIMSK0  = (1 << OCIE0A);
        OCR0A   = ((F_CPU / 8 / 48000) - 1);
        TCCR0A  = (1 << WGM01);  // CTC mode
        TIMSK0  = (1 << OCIE0A);
        OCR0A   = ((F_CPU / 8 / 48000) - 1);
        TCCR0A  = (1 << WGM01);  // CTC mode
-       TCCR0B  = (1 << CS01);   // Fcpu/8 speed        
+       TCCR0B  = (1 << CS01);   // Fcpu/8 speed
 
        /* Set speaker as output */
        DDRC   |= (1 << 6);
 
        /* Set speaker as output */
        DDRC   |= (1 << 6);