Hi
I have two questions. I need first to put 20 bytes into a string[20]. In C++ i did that by this code:
Qt Code:
  1. string[0]='ab'; //ab is in Hex (0xab)
  2. string[1]='50'; //50 is in Hex (0x50)
  3. .
  4. .
  5. .
  6. string[19]='54' //54 is in Hex
To copy to clipboard, switch view to plain text mode 

After filling string[20], i must send it by serial port.
My first question is: how could i write above code in Qt to send by a serialport?
and my second question is: can i use QByteArray and then use QSerialPort::write(QByteArray)?