From ce7d4d1ca6faf644377f48e3f50e887ab28af1c5 Mon Sep 17 00:00:00 2001 From: Christof Arnosti Date: Sat, 14 Mar 2020 17:59:14 +0100 Subject: usb-serial-for-android: More fields in device descriptor As discussed in issue #2657, there are now more fields about the usb device information in android_usb_serial_device_descriptor. Additionally, the user-facing string now makes more sense: "vendor [:]" Where vendor is as reported by android, but shortened to 16 characters. Examples: FTDI [1:2] Silicon Labs [1:4] Signed-off-by: Christof Arnosti Signed-off-by: Dirk Hohndel --- core/serial_usb_android.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'core/serial_usb_android.h') diff --git a/core/serial_usb_android.h b/core/serial_usb_android.h index 7283950b3..f2c124712 100644 --- a/core/serial_usb_android.h +++ b/core/serial_usb_android.h @@ -9,6 +9,12 @@ struct android_usb_serial_device_descriptor { QAndroidJniObject usbDevice; /* the UsbDevice */ std::string className; /* the driver class name. If empty, then "autodetect" */ std::string uiRepresentation; /* The string that can be used for the user interface. */ + + // Device information + std::string manufacturer; + std::string product; + uint16_t pid; + uint16_t vid; }; std::vector serial_usb_android_get_devices(bool driverSelection); -- cgit v1.2.3-70-g09d2