aboutsummaryrefslogtreecommitdiff
path: root/cores/arduino/PluggableUSB.h
diff options
context:
space:
mode:
authorCristian Maglie <c.maglie@arduino.cc>2015-09-30 16:48:11 +0200
committerCristian Maglie <c.maglie@arduino.cc>2015-10-02 11:59:23 +0200
commit27c1832acab4bcc4527340721733d53afde33a65 (patch)
tree0274f368d7ac224eef19e8f95a27680b2229dc64 /cores/arduino/PluggableUSB.h
parent90652295956b6f4bcccb740aeb4f7c546327e499 (diff)
[PUSB] The latest fields are now set via constructor
Diffstat (limited to 'cores/arduino/PluggableUSB.h')
-rw-r--r--cores/arduino/PluggableUSB.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/cores/arduino/PluggableUSB.h b/cores/arduino/PluggableUSB.h
index c08bc99..0f776c0 100644
--- a/cores/arduino/PluggableUSB.h
+++ b/cores/arduino/PluggableUSB.h
@@ -27,10 +27,9 @@
class PUSBListNode {
public:
- PUSBListNode() { }
- int8_t numEndpoints;
- int8_t numInterfaces;
- uint8_t *endpointType;
+ PUSBListNode(int8_t numEps, int8_t numIfs, uint8_t *epType) :
+ numEndpoints(numEps), numInterfaces(numIfs), endpointType(epType)
+ { }
inline uint8_t interface() const { return pluggedInterface; }
inline int8_t endpoint() const { return pluggedEndpoint; }
@@ -43,6 +42,10 @@ protected:
uint8_t pluggedInterface;
int8_t pluggedEndpoint;
+ const int8_t numEndpoints;
+ const int8_t numInterfaces;
+ const uint8_t *endpointType;
+
public:
PUSBListNode *next = NULL;