[PHID] Fixes protocol on reenumeration
This commit is contained in:
parent
b8eeeff166
commit
281546bccb
|
@ -54,6 +54,11 @@ int HID_::getDescriptor(USBSetup& setup)
|
||||||
return -1;
|
return -1;
|
||||||
total += res;
|
total += res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Reset the protocol on reenumeration. Normally the host should not assume the state of the protocol
|
||||||
|
// due to the USB specs, but Windows and Linux just assumes its in report mode.
|
||||||
|
protocol = HID_REPORT_PROTOCOL;
|
||||||
|
|
||||||
return total;
|
return total;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -130,7 +135,7 @@ bool HID_::setup(USBSetup& setup)
|
||||||
|
|
||||||
HID_::HID_(void) : PluggableUSBModule(1, 1, epType),
|
HID_::HID_(void) : PluggableUSBModule(1, 1, epType),
|
||||||
rootNode(NULL), descriptorSize(0),
|
rootNode(NULL), descriptorSize(0),
|
||||||
protocol(1), idle(1)
|
protocol(HID_REPORT_PROTOCOL), idle(1)
|
||||||
{
|
{
|
||||||
epType[0] = EP_TYPE_INTERRUPT_IN;
|
epType[0] = EP_TYPE_INTERRUPT_IN;
|
||||||
PluggableUSB().plug(this);
|
PluggableUSB().plug(this);
|
||||||
|
|
Loading…
Reference in New Issue