diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2020-08-24 18:45:34 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2020-08-24 18:45:34 +0200 |
commit | 2b3e02411ecc09e7d41741b5587655c9b2f955b7 (patch) | |
tree | d839746371ecb8ed64ac81d2e37c11fcd25a00ac /backend/genesys/test_usb_device.cpp | |
parent | 787fb1d54ec9ee5fb941ae897fb201feb9cb2fd1 (diff) | |
parent | ad38bc6ecb80ddeb562841b33258dd53659b1da6 (diff) |
Update upstream source from tag 'upstream/1.0.31'
Update to upstream version '1.0.31'
with Debian dir aa7a39fe56343f5e164eec83783f4c923a394865
Diffstat (limited to 'backend/genesys/test_usb_device.cpp')
-rw-r--r-- | backend/genesys/test_usb_device.cpp | 25 |
1 files changed, 20 insertions, 5 deletions
diff --git a/backend/genesys/test_usb_device.cpp b/backend/genesys/test_usb_device.cpp index de2399e..1612eae 100644 --- a/backend/genesys/test_usb_device.cpp +++ b/backend/genesys/test_usb_device.cpp @@ -48,9 +48,11 @@ namespace genesys { -TestUsbDevice::TestUsbDevice(std::uint16_t vendor, std::uint16_t product) : +TestUsbDevice::TestUsbDevice(std::uint16_t vendor, std::uint16_t product, + std::uint16_t bcd_device) : vendor_{vendor}, - product_{product} + product_{product}, + bcd_device_{bcd_device} { } @@ -94,12 +96,25 @@ void TestUsbDevice::close() name_ = ""; } -void TestUsbDevice::get_vendor_product(int& vendor, int& product) +std::uint16_t TestUsbDevice::get_vendor_id() { DBG_HELPER(dbg); assert_is_open(); - vendor = vendor_; - product = product_; + return vendor_; +} + +std::uint16_t TestUsbDevice::get_product_id() +{ + DBG_HELPER(dbg); + assert_is_open(); + return product_; +} + +std::uint16_t TestUsbDevice::get_bcd_device() +{ + DBG_HELPER(dbg); + assert_is_open(); + return bcd_device_; } void TestUsbDevice::control_msg(int rtype, int reg, int value, int index, int length, |