2026年6月12日
This commit is contained in:
+10
-6
@@ -5,9 +5,9 @@
|
||||
#include <QThread>
|
||||
#include <QFile>
|
||||
#include "DevOp.h"
|
||||
#include <QElapsedTimer>
|
||||
#include <QElapsedTimer>
|
||||
#include <QEventLoop>
|
||||
#include <QCoreApplication>
|
||||
#include <QCoreApplication>
|
||||
#define MAX_LEN1 1024
|
||||
#define MAX_LEN2 224
|
||||
|
||||
@@ -60,15 +60,19 @@ void Serial::initSerialPort(const QString comport){
|
||||
serial->setStopBits(QSerialPort::OneStop);
|
||||
serial->setFlowControl(QSerialPort::NoFlowControl);
|
||||
if (serial->open(QIODevice::ReadWrite)) {
|
||||
if(comport == "/dev/ttyAS5")
|
||||
if(comport == "/dev/ttyAS5"){
|
||||
qDebug() << "FPGA串口打开成功";
|
||||
else
|
||||
}
|
||||
else{
|
||||
qDebug() << "STM32串口打开成功";
|
||||
}
|
||||
} else {
|
||||
if(comport == "/dev/ttyAS5")
|
||||
if(comport == "/dev/ttyAS5"){
|
||||
qDebug() << "FPGA串口打开失败:" << serial->errorString();
|
||||
else
|
||||
}
|
||||
else{
|
||||
qDebug() << "STM32串口打开失败:" << serial->errorString();
|
||||
}
|
||||
}
|
||||
this->FPGARecDataSavePtr=NULL;
|
||||
this->FPGARecDataLen=0;
|
||||
|
||||
Reference in New Issue
Block a user