Important: Please read the Qt Code of Conduct -

Unable to read hex bytes from serial interface in Qt Creator

  • I am trying to read the data from modem in Qt through serial interface. While doing so, I am able to read the data till no hex byte is encountered. After that I fail to read the data!

    Sample Code attached here :

    QString a=0,Received_response=0

    Is there any limitation for QString (datatype) that it can't read the hex data?

    Or is there any other method to grab the hex bytes through serial interface in Qt ?

  • Moderators

    you need to be more specific. But I can say with a high certainty that you're doing stuff wrong, or at the very least not what you want to do.

    What is transferred via serial port?

    Is it ascii characters representing hex values or can it be any arbitrary byte ?

Log in to reply