QT在windows上输入汉字默认为GBK,用串口传输到单片机后必须转换为UTF-8
QString DevInfo = ui -> lineEdit_province->text();
QByteArray data = DevInfo.tolocal8Bit();
std::string str = std::string(data);
const char *Dev_Info = str.c_str();