We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents ced0629 + ca3c821 commit eefb9a8Copy full SHA for eefb9a8
libraries/HID/HID.cpp
@@ -54,6 +54,11 @@ int HID_::getDescriptor(USBSetup& setup)
54
return -1;
55
total += res;
56
}
57
+
58
+ // Reset the protocol on reenumeration. Normally the host should not assume the state of the protocol
59
+ // due to the USB specs, but Windows and Linux just assumes its in report mode.
60
+ protocol = HID_REPORT_PROTOCOL;
61
62
return total;
63
64
@@ -140,7 +145,7 @@ bool HID_::setup(USBSetup& setup)
140
145
141
146
HID_::HID_(void) : PluggableUSBModule(1, 1, epType),
142
147
rootNode(NULL), descriptorSize(0),
143
- protocol(1), idle(1)
148
+ protocol(HID_REPORT_PROTOCOL), idle(1)
144
149
{
150
epType[0] = EP_TYPE_INTERRUPT_IN;
151
PluggableUSB().plug(this);
0 commit comments