Skip to content

Commit 6151972

Browse files
committed
[PUSB] Changed Interface + Endpoint to unsigned variables
The iterations in the for loop also use unsigned and the setup struct etc as well. There was no change in HID required since we just init the inherited variables via constructor and the type is never mentioned.
1 parent ef15667 commit 6151972

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

hardware/arduino/avr/cores/arduino/PluggableUSB.h

+5-5
Original file line numberDiff line numberDiff line change
@@ -27,23 +27,23 @@
2727

2828
class PUSBListNode {
2929
public:
30-
PUSBListNode(int8_t numEps, int8_t numIfs, uint8_t *epType) :
30+
PUSBListNode(uint8_t numEps, uint8_t numIfs, uint8_t *epType) :
3131
numEndpoints(numEps), numInterfaces(numIfs), endpointType(epType)
3232
{ }
3333

3434
inline uint8_t interface() const { return pluggedInterface; }
35-
inline int8_t endpoint() const { return pluggedEndpoint; }
35+
inline uint8_t endpoint() const { return pluggedEndpoint; }
3636

3737
protected:
3838
virtual bool setup(USBSetup& setup, uint8_t interfaceNum) = 0;
3939
virtual int getInterface(uint8_t* interfaceCount) = 0;
4040
virtual int getDescriptor(int8_t t) = 0;
4141

4242
uint8_t pluggedInterface;
43-
int8_t pluggedEndpoint;
43+
uint8_t pluggedEndpoint;
4444

45-
const int8_t numEndpoints;
46-
const int8_t numInterfaces;
45+
const uint8_t numEndpoints;
46+
const uint8_t numInterfaces;
4747
const uint8_t *endpointType;
4848

4949
PUSBListNode *next = NULL;

0 commit comments

Comments
 (0)