mirror of
https://github.com/felis/USB_Host_Shield_2.0.git
synced 2024-03-22 11:31:26 +01:00
Fixed some bugs introduced in e18eb57752
This commit is contained in:
parent
34ea983e88
commit
b4bb7c9244
3 changed files with 11 additions and 8 deletions
|
@ -221,14 +221,15 @@ uint8_t PS3USB::Init(uint8_t parent, uint8_t port, bool lowspeed) {
|
||||||
bPollEnable = true;
|
bPollEnable = true;
|
||||||
Notify(PSTR("\r\n"), 0x80);
|
Notify(PSTR("\r\n"), 0x80);
|
||||||
timer = millis();
|
timer = millis();
|
||||||
return 0; // successful configuration
|
return 0; // Successful configuration
|
||||||
|
|
||||||
/* diagnostic messages */
|
/* Diagnostic messages */
|
||||||
FailGetDevDescr:
|
FailGetDevDescr:
|
||||||
#ifdef DEBUG_USB_HOST
|
#ifdef DEBUG_USB_HOST
|
||||||
NotifyFailGetDevDescr();
|
NotifyFailGetDevDescr();
|
||||||
goto Fail;
|
goto Fail;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
FailSetDevTblEntry:
|
FailSetDevTblEntry:
|
||||||
#ifdef DEBUG_USB_HOST
|
#ifdef DEBUG_USB_HOST
|
||||||
NotifyFailSetDevTblEntry();
|
NotifyFailSetDevTblEntry();
|
||||||
|
@ -238,8 +239,8 @@ FailSetDevTblEntry:
|
||||||
FailSetConfDescr:
|
FailSetConfDescr:
|
||||||
#ifdef DEBUG_USB_HOST
|
#ifdef DEBUG_USB_HOST
|
||||||
NotifyFailSetConfDescr();
|
NotifyFailSetConfDescr();
|
||||||
goto Fail;
|
|
||||||
#endif
|
#endif
|
||||||
|
goto Fail;
|
||||||
|
|
||||||
FailUnknownDevice:
|
FailUnknownDevice:
|
||||||
#ifdef DEBUG_USB_HOST
|
#ifdef DEBUG_USB_HOST
|
||||||
|
@ -247,8 +248,8 @@ FailUnknownDevice:
|
||||||
#endif
|
#endif
|
||||||
rcode = USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED;
|
rcode = USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED;
|
||||||
|
|
||||||
#ifdef DEBUG_USB_HOST
|
|
||||||
Fail:
|
Fail:
|
||||||
|
#ifdef DEBUG_USB_HOST
|
||||||
Notify(PSTR("\r\nPS3 Init Failed, error code: "), 0x80);
|
Notify(PSTR("\r\nPS3 Init Failed, error code: "), 0x80);
|
||||||
NotifyFail(rcode);
|
NotifyFail(rcode);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -214,16 +214,17 @@ FailSetDevTblEntry:
|
||||||
FailSetConfDescr:
|
FailSetConfDescr:
|
||||||
#ifdef DEBUG_USB_HOST
|
#ifdef DEBUG_USB_HOST
|
||||||
NotifyFailSetConfDescr();
|
NotifyFailSetConfDescr();
|
||||||
goto Fail;
|
|
||||||
#endif
|
#endif
|
||||||
|
goto Fail;
|
||||||
|
|
||||||
FailUnknownDevice:
|
FailUnknownDevice:
|
||||||
#ifdef DEBUG_USB_HOST
|
#ifdef DEBUG_USB_HOST
|
||||||
NotifyFailUnknownDevice(VID, PID);
|
NotifyFailUnknownDevice(VID, PID);
|
||||||
#endif
|
#endif
|
||||||
rcode = USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED;
|
rcode = USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED;
|
||||||
|
|
||||||
#ifdef DEBUG_USB_HOST
|
|
||||||
Fail:
|
Fail:
|
||||||
|
#ifdef DEBUG_USB_HOST
|
||||||
Notify(PSTR("\r\nXbox Init Failed, error code: "), 0x80);
|
Notify(PSTR("\r\nXbox Init Failed, error code: "), 0x80);
|
||||||
NotifyFail(rcode);
|
NotifyFail(rcode);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -201,16 +201,17 @@ FailSetDevTblEntry:
|
||||||
FailSetConfDescr:
|
FailSetConfDescr:
|
||||||
#ifdef DEBUG_USB_HOST
|
#ifdef DEBUG_USB_HOST
|
||||||
NotifyFailSetConfDescr();
|
NotifyFailSetConfDescr();
|
||||||
goto Fail;
|
|
||||||
#endif
|
#endif
|
||||||
|
goto Fail;
|
||||||
|
|
||||||
FailUnknownDevice:
|
FailUnknownDevice:
|
||||||
#ifdef DEBUG_USB_HOST
|
#ifdef DEBUG_USB_HOST
|
||||||
NotifyFailUnknownDevice(VID, PID);
|
NotifyFailUnknownDevice(VID, PID);
|
||||||
#endif
|
#endif
|
||||||
rcode = USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED;
|
rcode = USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED;
|
||||||
|
|
||||||
#ifdef DEBUG_USB_HOST
|
|
||||||
Fail:
|
Fail:
|
||||||
|
#ifdef DEBUG_USB_HOST
|
||||||
Notify(PSTR("\r\nXbox 360 Init Failed, error code: "), 0x80);
|
Notify(PSTR("\r\nXbox 360 Init Failed, error code: "), 0x80);
|
||||||
NotifyFail(rcode);
|
NotifyFail(rcode);
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue