Results 1 to 2 of 2

Thread: How to scan for existing COM Ports on Windows without QExtSerialPort

  1. #1
    Join Date
    May 2011
    Posts
    2
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default How to scan for existing COM Ports on Windows without QExtSerialPort

    Hi,

    my app is currently using Qt & QExtSerialPort (via google code - not via the old sf.net) to fill a drop-down element with a list of all COM-ports the QExtSerial port-enumerator finds on a system.

    As the QExtSerialPort way of searching for existing COM ports (example: enumerator of QExtSerialPort) seems to cause trouble depending on the user-permissions, different driver installations as well as windows-registry entries and the related permissions once again i am wondering if there is another way to search for COM ports in a Qt project.

    So my main question is:

    Is there a known way (and maybe even an example) to search for COM ports on windows using Qt?

    Any idea/help is appreciated.

    Best regards
    apeish

  2. #2
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: How to scan for existing COM Ports on Windows without QExtSerialPort

    seems to cause trouble depending on the user-permissions,
    Can you elaborate more on that?
    QextSerialPort is using the windows API to find the ports on windows, so what ever permission problems you will have with QextSerialPort I guess you will have with out it as well.
    By the way this is not a Qt issue.
    You will find many examples on google.
    Here one that might be good, since it uses nine! various methods of enumerating the serial ports:
    http://www.naughter.com/enumser.html
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

Similar Threads

  1. Finding available COM ports with QextSerialPort
    By Ferric in forum Qt Programming
    Replies: 7
    Last Post: 26th October 2010, 20:16
  2. Converting existing Windows app
    By GrahamLabdon in forum Qt Programming
    Replies: 1
    Last Post: 22nd March 2010, 10:43
  3. Problem with qextserialport for Qt 4.5.2 for windows
    By viniciuscst in forum Qt Programming
    Replies: 1
    Last Post: 9th November 2009, 22:01
  4. Draging a non-existing file to the Windows Desktop
    By klaus1111 in forum Qt Programming
    Replies: 13
    Last Post: 20th September 2007, 12:47
  5. QExtSerialPort with com ports above com9
    By mightymark in forum Qt Programming
    Replies: 2
    Last Post: 29th May 2006, 09:16

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.