iusbdevice.h 402 B

123456789101112131415161718192021222324
  1. #ifndef IUSBDEVICE_H
  2. #define IUSBDEVICE_H
  3. #include <stdint.h>
  4. #include <vector>
  5. namespace noolitelib
  6. {
  7. using Data = std::vector<unsigned char>;
  8. class IUsbDevice
  9. {
  10. public:
  11. virtual ~IUsbDevice() = default;
  12. virtual void openDevice(uint16_t vendorId, uint16_t productId) = 0;
  13. virtual void close() = 0;
  14. virtual bool sendDataToDevice(const Data &data) = 0;
  15. };
  16. }
  17. #endif // IUSBDEVICE_H