Browse Source

add BlockingQueuedConnection and sig-slot check

mehrabi
mehrabi 3 years ago
parent
commit
aadd7e3ca3
  1. 4
      Plx/Plx.pro
  2. 10
      Plx/include/API/HonaAPI.h
  3. 34
      Plx/include/LowLevel/HonaLowLevelAPI.h
  4. 6
      Plx/include/LowLevel/Setting/Setting.h
  5. 25
      Plx/include/LowLevel/Utils/Utils.h
  6. 30
      Plx/include/Wrapper/PlxWrapper.h
  7. 3
      Plx/src/API/HonaAPI.cpp
  8. 202
      Plx/src/LowLevel/HonaLowLevelAPI.cpp
  9. 1
      Plx/src/Wrapper/PlxWrapper.cpp
  10. 21
      Test/MainWindow.cpp
  11. 7
      Test/MainWindow.h
  12. 10
      Test/MainWindow.ui
  13. 2
      Test/Test.pro
  14. 1
      Test/main.cpp
  15. 1
      ignore.save

4
Plx/Plx.pro

@ -41,7 +41,3 @@ INCLUDEPATH += $$PWD/../../Plxlibrary
DEPENDPATH += $$PWD/../../Plxlibrary
unix:!macx: PRE_TARGETDEPS += $$PWD/../../Plxlibrary/Library/libPlxApi.a
<<<<<<< HEAD
=======
>>>>>>> 64f6e7f618eb5a6f1f63a4c5f377b46f1e7bc126

10
Plx/include/API/HonaAPI.h

@ -4,10 +4,10 @@
#include <QObject>
#include "LowLevel/Setting/Setting.h"
#include "include/LowLevel/Exception/HonaAlreadyStartedException.h"
#include "include/LowLevel/Exception/HonaException.h"
#include "include/LowLevel/Utils/Utils.h"
#include "include/LowLevel/HonaLowLevelAPI.h"
#include "LowLevel/Exception/HonaAlreadyStartedException.h"
#include "LowLevel/Exception/HonaException.h"
#include "LowLevel/Utils/Utils.h"
#include "LowLevel/HonaLowLevelAPI.h"
class HonaAPI : public QObject
{
@ -39,7 +39,7 @@ public:
ApiResult init();
signals:
void honaDataResult(QList<HonaPacket> honaPacketList, quint32 hsruLoss, quint32 Doa);
void honaDataResult(QList<HonaPacket> &honaPacketList, quint32 hsruLoss, quint32 Doa);
};
#endif //HONAAPI_H

34
Plx/include/LowLevel/HonaLowLevelAPI.h

@ -1,24 +1,17 @@
#ifndef HONALOWLEVELAPI_H
#define HONALOWLEVELAPI_H
#include <QObject>
#include <QMutex>
#include <QWaitCondition>
#include "LowLevel/Setting/Setting.h"
#include "LowLevel/HonaPacket.h"
#include "LowLevel/Setting/Setting.h"
#include "HonaPacket.h"
#include "QWaitCondition"
#include "QMutex"
<<<<<<< HEAD
#include "include/LowLevel/HonaPacket.h"
#include "include/Wrapper/PlxWrapper.h"
=======
#include "LowLevel/Exception/HonaAlreadyStartedException.h"
#include "LowLevel/Exception/HonaException.h"
#include "Wrapper/PlxWrapper.h"
#include "LowLevel/Utils/Utils.h"
>>>>>>> 64f6e7f618eb5a6f1f63a4c5f377b46f1e7bc126
class HonaLowLevelAPI : public QObject
{
@ -35,20 +28,6 @@ private:
QList<HonaPacket> honaPacketList;
QMutex _mutex;
int _threadSforValue = 0;
<<<<<<< HEAD
bool _isReaderThreadFree = false;
bool _isUpdateThreadFree = false;
QVector<quint32> honaRegisterBuffer;
QList<HonaPacket> honaPacketList;
PlxWrapper plxwrapper;
quint32 hsruLoss = 0;
static quint32 packetLenInt123C;
static quint32 packetLenRes123C;
static quint32 packetLenIntS;
static quint32 packetLenResS;
=======
bool _isHsruMainThreadFree = false;
bool _isHsruReaderThreadFree = false;
bool _isHsruUpdateThreadFree = false;
@ -93,7 +72,6 @@ private:
HonaPacket tempHonaPacketRes123C;
HonaPacket tempHonaPacketIntS;
HonaPacket tempHonaPacketResS;
>>>>>>> 64f6e7f618eb5a6f1f63a4c5f377b46f1e7bc126
public:
qulonglong toaStartBoard = 0;
@ -148,12 +126,8 @@ private:
public:
void hsruReaderMethod();
QVector<quint32> hsruReadHonaBuffer(honaReceivers receiver);
quint32 hsruParserInt123C(quint32 honaData,QList<HonaPacket> honaPacketList);
signals:
void lowLevelHonaData(QList<HonaPacket> honaPacketList, quint32 hsruLoss, quint32 Doa);
void lowLevelHonaData(QList<HonaPacket> &honaPacketList, quint32 hsruLoss, quint32 Doa);
//uncrustify off
public slots:

6
Plx/include/LowLevel/Setting/Setting.h

@ -25,9 +25,9 @@ struct hsruSettings_t
quint32 honaRes123CTHR = 128;
quint32 honaIntSTHR = 20;
quint32 honaResSTHR = 20;
quint32 honaSPTHR = 20; //mode4
quint32 intM4_THR = 20; //mode4
quint32 resM4_THR = 20; //mode4
quint32 honaSPTHR = 20;
quint32 intM4_THR = 20;
quint32 resM4_THR = 20;
};
/***********************************************************************************************/

25
Plx/include/LowLevel/Utils/Utils.h

@ -1,8 +1,6 @@
#ifndef UTILS_H
#define UTILS_H
#include <QtCore>
/*************************************************************************************************/
enum ApiResult : quint8
{
@ -22,24 +20,13 @@ enum drxDeviceIfChannel : quint8
/*************************************************************************************************/
enum honaReceivers : quint8
{
<<<<<<< HEAD
int123C,
res123C,
intS,
resS,
int4, //Mode 4
res4, //Mode 4
singlePulse //Mode 4
=======
int123C,
res123C,
intS,
resS,
int4, //Mode 4
res4, //Mode 4
singlePulse //Mode 4
>>>>>>> 64f6e7f618eb5a6f1f63a4c5f377b46f1e7bc126
int4,
res4,
singlePulse
};
/*************************************************************************************************/
@ -71,13 +58,7 @@ enum honaPacketType : quint8
responseMode4,
singlePulseMode4
};
<<<<<<< HEAD
/*************************************************************************************************/
#endif // UTILS_H
=======
/*************************************************************************************************/
#endif //UTILS_H
>>>>>>> 64f6e7f618eb5a6f1f63a4c5f377b46f1e7bc126

30
Plx/include/Wrapper/PlxWrapper.h

@ -2,7 +2,6 @@
#define PLXWRAPPER_H
#include <QtGlobal>
#include "PlxPci_9054_Func.h"
<<<<<<< HEAD
class PlxWrapper
{
public:
@ -29,35 +28,6 @@ public:
bool deviceDisableInterrupt(void);
bool deviceWaitForInterrupt(quint32 timeout);
bool deviceGetChipType(quint8 revision, quint16 chipType);
=======
class PlxWrapper
{
public:
PlxWrapper();
bool deviceInit(quint32 devicekey);
bool deviceOpen(void);
bool deviceClose(void);
bool deviceReset(void);
bool deviceLoadE2pToFPGA(void);
bool deviceReadEeprom(quint16 offset, quint32 length, QVector<quint32>& data);
bool deviceWriteEeprom(quint16 offset, quint32 data);
bool deviceReadRegister(quint32 address, QVector<quint32>& data, quint32 length);
bool deviceReadRegister(quint32 address, quint32& data);
bool deviceWriteRegister(quint32 address, QVector<quint32>& data);
bool deviceWriteRegister(quint32 address, quint32 data);
bool deviceReadMemory(quint32 localAddress, QVector<quint32>& data, quint32 length);
bool deviceOpenPCIChannel(void);
bool deviceClosePCIChannel(void);
bool deviceEnableInterrupt(void);
bool deviceDisableInterrupt(void);
bool deviceWaitForInterrupt(quint32 timeout);
bool deviceGetChipType(quint8 revision, quint16 chipType);
>>>>>>> 64f6e7f618eb5a6f1f63a4c5f377b46f1e7bc126
};
#endif //PLXWRAPPER_H

3
Plx/src/API/HonaAPI.cpp

@ -1,7 +1,6 @@
#include "include/API/HonaAPI.h"
/*************************************************************************************************/
ApiResult HonaAPI::isHsruStarted()
{
try {
@ -166,7 +165,7 @@ ApiResult HonaAPI::hsruStop()
/*************************************************************************************************/
ApiResult HonaAPI::init()
{
connect(&_honaLowLevelAPI, &HonaLowLevelAPI::lowLevelHonaData, this, &HonaAPI::honaDataResult);
connect(&_honaLowLevelAPI, &HonaLowLevelAPI::lowLevelHonaData, this, &HonaAPI::honaDataResult,Qt::BlockingQueuedConnection);
try {
_honaLowLevelAPI.init();

202
Plx/src/LowLevel/HonaLowLevelAPI.cpp

@ -1,16 +1,8 @@
#include <QtConcurrent/QtConcurrent>
#include <include/LowLevel/Utils/Utils.h>
#include "include/LowLevel/HonaLowLevelAPI.h"
#include "include/Wrapper/PlxWrapper.h"
<<<<<<< HEAD
#include "qdebug.h"
#include "QTime"
#include "QtConcurrent/QtConcurrent"
=======
#include <QDebug>
quint32 HonaLowLevelAPI::packetLenInt4;
quint32 HonaLowLevelAPI::packetLenRes4;
quint32 HonaLowLevelAPI::packetLenSinglePulse;
@ -28,7 +20,6 @@ quint32 HonaLowLevelAPI::nextResS;
quint32 HonaLowLevelAPI::nextInt123C;
quint32 HonaLowLevelAPI::nextRes123C;
quint32 HonaLowLevelAPI::nextIntS;
>>>>>>> 64f6e7f618eb5a6f1f63a4c5f377b46f1e7bc126
bool HonaLowLevelAPI::getHsruIsStarted() const
{
@ -171,36 +162,6 @@ void HonaLowLevelAPI::init()
/*************************************************************************************************/
void HonaLowLevelAPI::writeSettingToRegisters(HonaSettings& settings)
{
<<<<<<< HEAD
honaRegisterBuffer.clear();
honaRegisterBuffer.insert(0,0x00000000);
/************************************************************************/
if(settings.hiruSettings.recordStard == recorderStart::selfTestCounter)
honaRegisterBuffer.insert(0,0x80000000);
else
honaRegisterBuffer.insert(0,0x7FFFFFFF);
/************************************************************************/
if(settings.hiruSettings.recordChannel == drxDeviceIfChannel::ifChannel12)
honaRegisterBuffer.insert(0,0x20000000);
else
honaRegisterBuffer.insert(0,0xDFFFFFFF);
/************************************************************************/
if(settings.hiruSettings.recordMode == recorderMode::dualChannel)
honaRegisterBuffer.insert(0,0x10000000);
else
honaRegisterBuffer.insert(0,0xEFFFFFFF);
/************************************************************************/
honaRegisterBuffer.insert(0,(honaRegisterBuffer.at(0)+ (settings.hiruSettings.threshold & 0x00000FFF)));
honaRegisterBuffer.insert(1,settings.hsruSettings.honaInt123CTHR);
honaRegisterBuffer.insert(2,settings.hsruSettings.honaRes123CTHR);
honaRegisterBuffer.insert(3,settings.hsruSettings.honaIntSTHR);
honaRegisterBuffer.insert(4,settings.hsruSettings.honaResSTHR);
honaRegisterBuffer.insert(5,settings.hsruSettings.honaSPTHR);
honaRegisterBuffer.insert(6,settings.hsruSettings.intM4_THR);
honaRegisterBuffer.insert(7,settings.hsruSettings.resM4_THR);
=======
honaRegisterBuffer.clear();
honaRegisterBuffer.insert(0, 0x00000000);
/************************************************************************/
@ -231,7 +192,6 @@ void HonaLowLevelAPI::writeSettingToRegisters(HonaSettings& settings)
honaRegisterBuffer.insert(5, settings.hsruSettings.honaSPTHR);
honaRegisterBuffer.insert(6, settings.hsruSettings.intM4_THR);
honaRegisterBuffer.insert(7, settings.hsruSettings.resM4_THR);
>>>>>>> 64f6e7f618eb5a6f1f63a4c5f377b46f1e7bc126
}
/*************************************************************************************************/
@ -243,8 +203,6 @@ void HonaLowLevelAPI::setConfig()
/*************************************************************************************************/
void HonaLowLevelAPI::hsruMainThread()
{
//try
//{
deviceReset();
setConfig();
deviceReset();
@ -255,13 +213,6 @@ void HonaLowLevelAPI::hsruMainThread()
QtConcurrent::run(this, &HonaLowLevelAPI::hsruReadThread);
QtConcurrent::run(this, &HonaLowLevelAPI::hsruUpdateThread);
//}
//catch(...)
//{
//_isHsruReaderThreadFree = true;
//_isHsruUpdateThreadFree = true;
//hsruStop();
//}
_mutex.lock();
_hsruStopEvent.wait(&_mutex);
@ -369,7 +320,6 @@ quint32 HonaLowLevelAPI::hiruGetDOA()
throw HonaException("DeviceReadRegister Doesnt Occur");
}
Doa = Doa & 0x0000FFFF;
return Doa;
}
@ -493,6 +443,7 @@ quint32 HonaLowLevelAPI::hsruParserRes123C(const QVector<quint32>& honaData,
else if(((honaData[Ind] & 0xF0000000) == 0x40000000) && (nextRes123C == 4))
{
tempHonaPacketRes123C.setPa1(honaData[Ind] & 0x0000FFFF);
tempHonaPacketRes123C.setPa2(tempHonaPacketRes123C.getPa2() +
((honaData[Ind] & 0x000F0000) >> 4));
tempHonaPacketRes123C.setPa3(tempHonaPacketRes123C.getPa3() +
@ -504,6 +455,7 @@ quint32 HonaLowLevelAPI::hsruParserRes123C(const QVector<quint32>& honaData,
tempHonaPacketRes123C.setCodeM(
(static_cast<qulonglong>(honaData[Ind] & 0x00001FFF)) << 51);
tempHonaPacketRes123C.setCodeL(0);
nextRes123C = 6;
}
@ -517,7 +469,6 @@ quint32 HonaLowLevelAPI::hsruParserRes123C(const QVector<quint32>& honaData,
nextRes123C = 0;
}
}
return lossFound;
}
@ -781,8 +732,7 @@ quint32 HonaLowLevelAPI::hsruParserInt4(const QVector<quint32>& honaData,
{
tempHonaPacketInt4.setPa4(honaData[Ind] & 0x0000FFFF);
tempHonaPacketInt4.setCodeL(tempHonaPacketInt4.getCodeL() +
((static_cast<qulonglong>(honaData[Ind] & 0x000F0000)) <<
12));
((static_cast<qulonglong>(honaData[Ind] & 0x000F0000)) << 12));
tempHonaPacketInt4.setm4Status(static_cast<quint8>((honaData[Ind] & 0x0F000000) >> 20));
nextInt4 = 7;
}
@ -801,6 +751,7 @@ quint32 HonaLowLevelAPI::hsruParserInt4(const QVector<quint32>& honaData,
return lossFound;
}
/*************************************************************************************************/
quint32 HonaLowLevelAPI::hsruParserRes4(const QVector<quint32>& honaData,
QList<HonaPacket>& honaPacketList)
{
@ -956,7 +907,6 @@ QVector<quint32> HonaLowLevelAPI::hsruReadHonaBuffer(honaReceivers receiver)
address = 0XA0000000;
else if(receiver == honaReceivers::singlePulse)
address = 0XB0000000;
else
throw HonaException("honaReceivers is Not Valid");
@ -982,147 +932,3 @@ bool HonaLowLevelAPI::isValid(HonaPacket hp)
}
/*************************************************************************************************/
/*************************************************************************************************/
void HonaLowLevelAPI::hsruReaderMethod()
{
DateTime dtStartSim = DateTime.Now;
hsruLoss = 0;
while (true)
{
if (_honaSettings.hsruSettings.isReal)
{
plxwrapper.deviceWaitForInterrupt(1000);
honaPacketList.clear();
hsruLoss = 0;
plxwrapper.deviceOpenPCIChannel();
hsruLoss += hsruParserInt123C(hsruReadHonaBuffer(honaReceivers::int123C),&honaPacketList);
hsruLoss += hsruParserRes123C(hsruReadHonaBuffer(honaReceivers::res123C),&honaPacketList);
hsruLoss += hsruParserIntS(hsruReadHonaBuffer(honaReceivers::intS),&honaPacketList);
hsruLoss += hsruParserResS(hsruReadHonaBuffer(honaReceivers::resS),&honaPacketList);
hsruLoss += hsruParserInt4(hsruReadHonaBuffer(honaReceivers::int4),&honaPacketList);
hsruLoss += hsruParserRes4(hsruReadHonaBuffer(honaReceivers::res4),&honaPacketList);
hsruLoss += hsruParserSinglePulse(hsruReadHonaBuffer(honaReceivers::singlePulse),&honaPacketList);
plxwrapper.deviceClosePCIChannel();
plxwrapper.deviceEnableInterrupt();
}
hsruReadDone.Set();
hsruUpdateAck.WaitOne();
}
}
/*************************************************************************************************/
QVector<quint32> HonaLowLevelAPI::hsruReadHonaBuffer(honaReceivers receiver)
{
QVector<quint32> honaData;
honaData.resize(16384);
quint32 address = 0;
if (receiver == honaReceivers::int123C)
address = 0X50000000;
else if (receiver == honaReceivers::res123C)
address = 0X60000000;
else if (receiver == honaReceivers::intS)
address = 0X70000000;
else if (receiver == honaReceivers::resS)
address = 0X80000000;
else if (receiver == honaReceivers::int4)// Mode4 :: added by H.H
address = 0X90000000;
else if (receiver == honaReceivers::res4)// Mode4 :: added by H.H
address = 0XA0000000;
else if (receiver == honaReceivers::singlePulse)// Mode4 :: added by H.H
address = 0XB0000000;
else
return false;
plxwrapper.deviceReadMemory(address, honaData,honaData.size());
//TODO for test (Debug)
WriteToFile(Receiver, honaData);
return honaData;
}
/*************************************************************************************************/
quint32 hsruParserInt123C(QVector<quint32> honaData,QList<HonaPacket> honaPacketList)
{
quint32 lossFound;
for (quint32 Ind = 0; Ind < honaData.length(); Ind++)
{
if ((honaData.at(Ind) & 0xFF000000) == 0x0F000000)
{
HonaPacket tempHonaPacketInt123C;
tempHonaPacketInt123C.setPacketType(honaPacketType.InterrogationMode123C);
packetLenInt123C = 6;
TempHonaPacketInt123C.PacketNumber = HonaData[Ind] & 0x0000FFFF;
if ((TempHonaPacketInt123C.PacketNumber != (LastPNInt123C + 1)) & (LastPNInt123C > 0))
// & (LastPNInt123C != 65535))
{
LossFound += ((TempHonaPacketInt123C.PacketNumber - LastPNInt123C + 65536)%65536 - 1);
}
LastPNInt123C = TempHonaPacketInt123C.PacketNumber;
if (NextInt123C > 0)
LossFound++;
NextInt123C = 1;
}
else if (((HonaData[Ind] & 0xF0000000) == 0x10000000) && (NextInt123C == 1))
{
TempHonaPacketInt123C.TOA = (ulong) (HonaData[Ind] & 0x0FFFFFFF);
NextInt123C = 2;
}
else if (((HonaData[Ind] & 0xF0000000) == 0x20000000) && (NextInt123C == 2))
{
TempHonaPacketInt123C.TOA += (((ulong) (HonaData[Ind] & 0x0000FFFF)) << 28);
TempHonaPacketInt123C.PA2 = ((HonaData[Ind] & 0x0FFF0000) >> 16);
NextInt123C = 3;
}
else if (((HonaData[Ind] & 0xF0000000) == 0x30000000) && (NextInt123C == 3))
{
TempHonaPacketInt123C.DOA = (HonaData[Ind] & 0x0000FFFF);
TempHonaPacketInt123C.PA3 = ((HonaData[Ind] & 0x0FFF0000) >> 16);
NextInt123C = 4;
}
else if (((HonaData[Ind] & 0xF0000000) == 0x40000000) && (NextInt123C == 4))
{
TempHonaPacketInt123C.PA1 = (HonaData[Ind] & 0x0000FFFF);
TempHonaPacketInt123C.PA2 += ((HonaData[Ind] & 0x000F0000) >> 4);
TempHonaPacketInt123C.PA3 += ((HonaData[Ind] & 0x00F00000) >> 8);
NextInt123C = 5;
}
else if (((HonaData[Ind] & 0xF0000000) == 0x50000000) && (NextInt123C == 5))
{
TempHonaPacketInt123C.CodeM = ((ulong) (HonaData[Ind] & 0x0000001F)) << 59;
TempHonaPacketInt123C.CodeL = 0;
NextInt123C = 6;
}
else if (HonaData[Ind] == 0xEEEEEEEE)
{
//Console.Write("-");
}
else
{
//Console.Write(".");
}
if (NextInt123C == PacketLenInt123C)
{
if (Isvalid(TempHonaPacketInt123C))
{
TempHonaPacketInt123C.TOA = (TempHonaPacketInt123C.TOA/8)/SimulationSpeed + toaStartBoard;
//toa converted to 100nsec
HonaPacketList.Add(TempHonaPacketInt123C);
}
NextInt123C = 0;
}
}
return LossFound;
}

1
Plx/src/Wrapper/PlxWrapper.cpp

@ -73,7 +73,6 @@ bool PlxWrapper::deviceReadRegister(quint32 address, QVector<quint32>& data, qui
for(auto i = 0U; i < length; i++)
{
data.append(temp[i]);
qDebug() << hex << temp[i];
}
}

21
Test/MainWindow.cpp

@ -1,6 +1,6 @@
#include "MainWindow.h"
#include "ui_MainWindow.h"
HonaAPI _honaAPI;
MainWindow::MainWindow(QWidget* parent)
: QMainWindow(parent)
@ -16,14 +16,21 @@ MainWindow::~MainWindow()
}
/*************************************************************************************************/
void MainWindow::honaDataResultUi(QList<HonaPacket> honaPacketList, quint32 hsruLoss, quint32 Doa)
void MainWindow::honaDataResultUi(QList<HonaPacket> &honaPacketList, quint32 hsruLoss, quint32 Doa)
{
qDebug() << "honaDataResultUi inside " << honaPacketList.length();
QString _str;
for(auto i = 0; i < honaPacketList.length(); i++)
{
_str = "[" + QString::number(i) + "] " + "0x hsruLoss" + QString::number(hsruLoss);
_str += "\n *********************************************";
_str += "\n[hsruLoss] :" + QString::number(hsruLoss, 16);
_str += "\n[getToa] :" + QString::number(honaPacketList[i].getToa(), 16);
_str += "\n[getDoa] :" + QString::number(honaPacketList[i].getDoa(), 16);
_str += "\n[getPa1] :" + QString::number(honaPacketList[i].getPa1(), 16);
_str += "\n[getPa2] :" + QString::number(honaPacketList[i].getPa2(), 16);
_str += "\n[getPa3] :" + QString::number(honaPacketList[i].getPa3(), 16);
_str += "\n[getPa4] :" + QString::number(honaPacketList[i].getPa4(), 16);
_str += "\n[getCode] :" + QString::number(honaPacketList[i].getCode(), 16);
_str += "\n[getCodeL] :" + QString::number(honaPacketList[i].getCodeL(), 16);
_str += "\n[getCodeM] :" + QString::number(honaPacketList[i].getCodeM(), 16);
}
ui->dataFromMemory->setText(_str);
@ -32,10 +39,6 @@ void MainWindow::honaDataResultUi(QList<HonaPacket> honaPacketList, quint32 hsru
void MainWindow::on_testPLX_clicked()
{
ApiResult _resultInit = _honaAPI.init();
//ApiResult _deviceReset = _honaAPI.deviceReset();
//HonaSettings settings;
//ApiResult _configResult = _honaAPI.setConfig(settings);
//ApiResult isHsruStarted = _honaAPI.isHsruStarted();
ApiResult _hsruStartResult = _honaAPI.hsruStart();
//********************************************************

7
Test/MainWindow.h

@ -19,7 +19,7 @@ class MainWindow : public QMainWindow
private:
Ui::MainWindow* ui;
int a;
HonaAPI _honaAPI;
public:
MainWindow(QWidget* parent = nullptr);
@ -27,12 +27,11 @@ public:
//uncrustify off
private slots:
void honaDataResultUi(QList<HonaPacket> honaPacketList, quint32 hsruLoss, quint32 Doa);
void honaDataResultUi(QList<HonaPacket> &honaPacketList, quint32 hsruLoss, quint32 Doa);
void on_testPLX_clicked();
void on_stopHsru_clicked();
//uncrustify on:
private:
//HonaAPI _honaAPI;
};
#endif //MAINWINDOW_H

10
Test/MainWindow.ui

@ -70,11 +70,17 @@
<property name="geometry">
<rect>
<x>50</x>
<y>160</y>
<y>140</y>
<width>451</width>
<height>261</height>
<height>301</height>
</rect>
</property>
<property name="verticalScrollBarPolicy">
<enum>Qt::ScrollBarAlwaysOn</enum>
</property>
<property name="sizeAdjustPolicy">
<enum>QAbstractScrollArea::AdjustToContentsOnFirstShow</enum>
</property>
</widget>
</widget>
<widget class="QMenuBar" name="menubar">

2
Test/Test.pro

@ -35,6 +35,7 @@ qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target
unix:!macx: LIBS += -L$$PWD/../../Plxlibrary/Library/ -lPlxApi
INCLUDEPATH += $$PWD/../../Plxlibrary/Library
@ -44,3 +45,4 @@ INCLUDEPATH += $$PWD/../../Plxlibrary
DEPENDPATH += $$PWD/../../Plxlibrary
unix:!macx: PRE_TARGETDEPS += $$PWD/../../Plxlibrary/Library/libPlxApi.a

1
Test/main.cpp

@ -5,6 +5,7 @@
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
MainWindow w;
w.show();
return a.exec();

1
ignore.save

@ -0,0 +1 @@
*.pro.user
Loading…
Cancel
Save