LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Detect USB Hub and device information programatically (https://www.linuxquestions.org/questions/linux-newbie-8/detect-usb-hub-and-device-information-programatically-4175445680/)

arunkumaraymuo 01-15-2013 05:45 AM

Detect USB Hub and device information programatically
 
I need to list existing USB hub and the devices connected in the hub.

I can able to print the USB Hub and devices connected in hub from terminal using the commands
Collapse | Copy Code

lsusb
lsusb -v


How can I do this programmatically. Is there any C++ classes available to use in my Qt application.

floppy_stuttgart 01-18-2013 12:50 PM

Start a spawn process
"lsusb -v > result.txt" or
"lsusb -v" to the output "tty" or other ?
Im not a specialist in programming (I had done it in FORTRAN 18years ago..).


All times are GMT -5. The time now is 05:52 AM.