Results 1 to 4 of 4

Thread: Serial Programming with QT

  1. #1
    Join Date
    Dec 2007
    Posts
    33
    Thanks
    7
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Serial Programming with QT

    Hi again,

    i guess thats not really possible with QT but let me ask, maybe i just havent found the matching keywords.

    Is it possible to check the host system (which runs my application) for existing serial-interfaces (like Com1, Com2, etc...)

    My test-application has a QComboBox atm with static entries.
    Basicly it would make more sense to check at application-start for existing interfaces
    and in the next step feed those resources into my QComboBox.

    The only matching keyword during my search in this forum was: QextSerialPort

    Last time i messed around with that topic was with LabView, which was kinda easy...but i do not want to compare those worlds in any way.

    Any hints ?
    Best regards
    ape

  2. #2
    Join Date
    Feb 2006
    Location
    Romania
    Posts
    2,744
    Thanks
    8
    Thanked 541 Times in 521 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Serial Programming with QT

    Go with QextSerialPort. It's the easiest solution.

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

    Default Re: Serial Programming with QT

    Is it possible to check the host system (which runs my application) for existing serial-interfaces (like Com1, Com2, etc...)
    As marcel mentioned, QextSerialPort is recommended.
    Then you can just try the open the port, if it gets open, you know it exists.
    If not, it *might* still exist, but I don't know how your application could know about it then.
    ==========================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.

  4. #4
    Join Date
    Oct 2007
    Location
    Grenoble, France
    Posts
    80
    Thanked 9 Times in 9 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Serial Programming with QT

    Is it possible to check the host system (which runs my application) for existing serial-interfaces (like Com1, Com2, etc...)
    qextserialport-1.2win-alpha has QextSerialEnumerator class, which provides list of ports available in the system (it worked for me under Windows, unfortunetely not under Linux). Still this is unstable release. While using it I had some problems with port opening.
    You can check if it works for you, but if I were you I'd wait till it is stable
    Oh..I didn't checked svn snapshot, maybe it will work
    You have to run a level 3 diagnostic.

    Ashes to ashes, Qt to Qt ( wysota )

Similar Threads

  1. serial communication programming
    By jagadish in forum Qt Programming
    Replies: 1
    Last Post: 30th August 2007, 07:47
  2. serial port programming in qt
    By sar_van81 in forum Qt Programming
    Replies: 46
    Last Post: 13th June 2007, 12:27
  3. Replies: 12
    Last Post: 23rd March 2007, 09:23
  4. Using QGraphicsView with model/view programming
    By JLP in forum Qt Programming
    Replies: 3
    Last Post: 29th January 2007, 11:04
  5. Replies: 16
    Last Post: 7th March 2006, 15:57

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.