OpenHantek
Loading...
Searching...
No Matches
finddevices.h
1// SPDX-License-Identifier: GPL-2.0+
2
3#pragma once
4
5#include <QString>
6#include <memory>
7#include <map>
8#include <list>
9
10#include "usbdevice.h"
11
12struct libusb_context;
13
24 public:
25 typedef std::map<UniqueUSBid, std::unique_ptr<USBDevice>> DeviceList;
26 FindDevices(libusb_context *context);
29 int updateDeviceList();
30 const DeviceList *getDevices();
36 std::unique_ptr<USBDevice> takeDevice(UniqueUSBid id);
37 private:
38 libusb_context *context;
39 DeviceList devices;
40 unsigned findIteration = 0;
41};
Search for Hantek devices. Use usually want to call updateDeviceList and then retrieve the list via g...
Definition finddevices.h:23
std::unique_ptr< USBDevice > takeDevice(UniqueUSBid id)
takeDevice
Definition finddevices.cpp:75
int updateDeviceList()
Definition finddevices.cpp:20