Results 1 to 7 of 7

Thread: Using QtSerialPort results in "APPCRASH"

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Mar 2013
    Posts
    29
    Thanks
    4
    Thanked 4 Times in 2 Posts

    Question Using QtSerialPort results in "APPCRASH"

    Hi,

    i'm trying to use the QtSerialPort Libary (http://qt-project.org/wiki/QtSerialPort). The install process worked fine (with Perl installed).
    The problem is, as soon as i start my test program (debug or release mode) it crashes with this error:

    Problemsignatur:
    Problemereignisname: APPCRASH
    Anwendungsname: Test.exe
    Anwendungsversion: 0.0.0.0
    Anwendungszeitstempel: 51a3623c
    Fehlermodulname: Qt5Cored.dll
    Fehlermodulversion: 5.0.2.0
    Fehlermodulzeitstempel: 516367ae
    Ausnahmecode: c0000005
    Ausnahmeoffset: 00021f3b
    Betriebsystemversion: 6.1.7601.2.1.0.256.48
    Gebietsschema-ID: 1031
    Zusatzinformation 1: 0a9e
    Zusatzinformation 2: 0a9e372d3b4ad19135b953a78882e789
    Zusatzinformation 3: 0a9e
    Zusatzinformation 4: 0a9e372d3b4ad19135b953a78882e789


    .cpp file:
    Qt Code:
    1. #include <QtCore/QCoreApplication>
    2. #include <QtCore/QDebug>
    3.  
    4. #include <QtSerialPort/QSerialPort>
    5. #include <QtSerialPort/QSerialPortInfo>
    6.  
    7. QT_USE_NAMESPACE
    8.  
    9. int main(int argc, char *argv[])
    10. {
    11. QCoreApplication a(argc, argv);
    12.  
    13. qDebug() << "Begin";
    14.  
    15. // Example use QSerialPortInfo
    16. foreach (const QSerialPortInfo &info, QSerialPortInfo::availablePorts()) {
    17. qDebug() << "Name : " << info.portName();
    18. qDebug() << "Description : " << info.description();
    19. qDebug() << "Manufacturer: " << info.manufacturer();
    20.  
    21. // Example use QSerialPort
    22. QSerialPort serial;
    23. serial.setPort(info);
    24. if (serial.open(QIODevice::ReadWrite))
    25. serial.close();
    26. }
    27.  
    28. qDebug() << "End";
    29. return a.exec();
    30. }
    To copy to clipboard, switch view to plain text mode 

    .pro file:
    Qt Code:
    1. #-------------------------------------------------
    2. #
    3. # Project created by QtCreator 2013-05-10T15:50:24
    4. #
    5. #-------------------------------------------------
    6.  
    7. QT += core
    8.  
    9. QT -= gui
    10.  
    11. QT += serialport
    12.  
    13. TARGET = Test
    14. CONFIG += console
    15. CONFIG -= app_bundle
    16.  
    17. TEMPLATE = app
    18.  
    19.  
    20. SOURCES += main.cpp
    To copy to clipboard, switch view to plain text mode 


    My setup is:
    Windows 7 Prof. 64 bit
    Qt 5.0.2 32 bit
    QtSerialPort Stable (f301591)


    Any ideas?

  2. #2
    Join Date
    Feb 2011
    Location
    Bangalore
    Posts
    207
    Thanks
    20
    Thanked 28 Times in 27 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Using QtSerialPort results in "APPCRASH"

    Your exe is not able to find the correct dll for QSerialPort. It is able to link properly but absence of dll causes it to crash. Check the dll with right name (QSerialPort0.dll / QSerialPort.dll, check the wiki...) is available in the path of executable.

Similar Threads

  1. Compiling Qt 4.8.2 results in "ld.exe: final link failed: Memory exhausted"
    By themagician in forum Installation and Deployment
    Replies: 8
    Last Post: 26th July 2012, 20:53
  2. Replies: 1
    Last Post: 12th October 2010, 14:43
  3. Replies: 1
    Last Post: 7th April 2010, 21:46
  4. Replies: 3
    Last Post: 8th July 2008, 19:37
  5. Translation QFileDialog standart buttons ("Open"/"Save"/"Cancel")
    By victor.yacovlev in forum Qt Programming
    Replies: 4
    Last Post: 24th January 2008, 19:05

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
  •  
Qt is a trademark of The Qt Company.