Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. how to use libusb to detect usb ports in qt
Qt 6.12 LTS is out! See what's new in the release blog

how to use libusb to detect usb ports in qt

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
4 Posts 2 Posters 1.3k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    Chakravarthi.N
    wrote on last edited by
    #1

    I have to use libusb with Qt in order to detect USB ports for Linux and Windows at the same code.Please, could you recommend me?

    1 Reply Last reply
    0
    • artwawA Offline
      artwawA Offline
      artwaw
      wrote on last edited by
      #2

      Ports or connected devices? I might be wrong on this but I think you can only enumerate connected devices (and set hot plug notifications) with libusb?

      For more information please re-read.

      Kind Regards,
      Artur

      C 1 Reply Last reply
      0
      • artwawA artwaw

        Ports or connected devices? I might be wrong on this but I think you can only enumerate connected devices (and set hot plug notifications) with libusb?

        C Offline
        C Offline
        Chakravarthi.N
        wrote on last edited by Chakravarthi.N
        #3

        @artwaw thanks for your response . and i need to detect usb port number and device name .could you suggest me code in windows side

        artwawA 1 Reply Last reply
        0
        • SGaistS SGaist referenced this topic on
        • C Chakravarthi.N

          @artwaw thanks for your response . and i need to detect usb port number and device name .could you suggest me code in windows side

          artwawA Offline
          artwawA Offline
          artwaw
          wrote on last edited by
          #4

          @Chakravarthi-N You can enumerate devices using this method https://libusb.sourceforge.io/api-1.0/group__libusb__dev.html#gac0fe4b65914c5ed036e6cbec61cb0b97

          Bus and port numbers can also be obtained using methods like this one https://libusb.sourceforge.io/api-1.0/group__libusb__dev.html#gaf2718609d50c8ded2704e4051b3d2925

          For more information please re-read.

          Kind Regards,
          Artur

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt
          • Unsolved