
网络编程
爱动漫的小明
这个作者很懒,什么都没留下…
展开
-
Qt串口通信,支持热插拔
.pro文件添加:QT += serialport //添加头文件 #include <QSerialPort> #include <QSerialPortInfo> //头文件声明类成员变量 QSerialPort m_pSerialPort; QComboBox* m_pComboBox; QTextEdit* m_pTextEdit; QLineEdit* m_pLineInput; //构造函数文件 QSerialPort m_pSerialPort = .原创 2021-05-08 10:51:54 · 1765 阅读 · 3 评论 -
Qt搭建多线程服务器
main.cpp 文件 #include "Widget.h" #include <QApplication> int main(int argc, char *argv[]) { QApplication a(argc, argv); Widget w; w.show(); return a.exec(); } 主线程 Widget.h文件 #ifndef WIDGET_H #define WIDGET_H #include <QWidg原创 2021-04-29 15:50:09 · 837 阅读 · 0 评论