View Full Version : USB HID connect on QT?
caodungviet
28th April 2011, 10:31
please help me. i fighting with read generic data USB HID in a QT project on Linux or window.this project will receives company' name and read files in USB and after they will be send to interface of QT. i still do not know.thanks for help me!!
squidge
28th April 2011, 11:33
Show code and explain exactly which part doesn't work and what it should do.
wysota
28th April 2011, 11:55
Sorry but isn't HID used for devices such as mice and keyboards and not transferring files? Isn't mass storage what you want? If you're using a standard device then Windows will mount it by itself and you can access it as any other disk in your system.
caodungviet
28th April 2011, 12:19
thanks for reply,..I have not done it .. it's just an idea,if you have an example as this, please give me..thank you very much!!
wysota
28th April 2011, 12:38
We have no idea what you are trying to do so it is not possible to give you any examples.
QTHamzaYazidBelkhiria
9th April 2013, 17:18
Hi i am just starting on QT,
My aim is to make a QT application that reads data through USB port (HID) sent from a Micro-Controller,
Would you have any example to recommend ?
ChrisW67
9th April 2013, 22:19
Qt has no facilities for direct USB access. If your microcontroller presents like:
a keyboard or mouse, then you will receive the data through either mouse or keyboard events after it has been processed by the operating system;
a game controller, UPS or other HID device, then you will likely not see events in Qt; or
a virtual serial port (i.e. not HID) then you can use one of several Qt-based serial port classes to access the port.
If you need low-level direct USB access then you should look at using the third-party libusb (www.libusb.org/) or you could use your platform's USB API directly.
Pavlya
10th April 2013, 13:02
You can use HID API library: http://www.signal11.us/oss/hidapi/
QTHamzaYazidBelkhiria
12th April 2013, 15:58
Thanks so much Chris and Pavlya,
I found a QT example integrating the libusb but
i could not compile it well with my limited knowlege https://github.com/iia/Qt_libusb
I am a bit lost on how to use libusb on QT, any ideas ?
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.