Class UsbDevice
Defined in File UsbDevice.hpp
Nested Relationships
Nested Types
Class Documentation
-
class UsbDevice
Public Types
-
typedef std::function<void(const void *data, int size)> Callback
Public Functions
-
UsbDevice(uint16_t vid, uint16_t pid, uint8_t mi)
-
UsbDevice(uint16_t vid, uint16_t pid)
-
UsbDevice()
-
~UsbDevice()
-
void setDevceIds(uint16_t vid, uint16_t pid, uint8_t mi)
-
void close()
-
inline bool isOpen() const
-
bool bulkWrite(const void *data, int size, unsigned char endpoint, int timeout)
-
int bulkRead(void *data, int size, unsigned char endpoint, int timeout)
-
bool interruptWrite(const void *data, int size, unsigned char endpoint, int timeout)
-
int interruptRead(void *data, int size, unsigned char endpoint, int timeout)
-
void stopBulkReadThread(unsigned char endpoint)
-
void stopInterruptReadThread(unsigned char endpoint)
-
int getLastError(std::string &str) const
-
void setDebugLevel(uint8_t level)
Public Members
-
bool throw_errors_
Public Static Functions
-
class Location
Public Functions
-
inline Location()
-
inline Location(uint8_t bus, uint8_t port = 0, uint8_t addr = 0, uint16_t vid = 0, uint16_t pid = 0)
-
inline Location()
-
struct UsbIds
-
typedef std::function<void(const void *data, int size)> Callback