Add missing device deconfiguration-on-error statements to the host mode demos and...
[pub/USBasp.git] / Demos / Host / ClassDriver / JoystickHostWithParser / JoystickHostWithParser.c
index e74dfe0..d118c85 100644 (file)
@@ -206,6 +206,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
        {
                puts_P(PSTR("Error Setting Report Protocol Mode or Not a Valid Joystick.\r\n"));
                LEDs_SetAllLEDs(LEDMASK_USB_ERROR);
+               USB_Host_SetDeviceConfiguration(0);
                return;
        }