Compare commits

...

12 Commits

  1. 2
      developHw.pro.user
  2. 155
      hdf5Scenario/hdf5Scenario.cpp
  3. 2
      include/model/hardware/core/lowLevelApi/TrxBoard.h
  4. 4
      include/model/hardware/core/lowLevelApi/TrxBoardUtils/ScenParamsRanges.h
  5. 2
      include/model/hardware/core/lowLevelApi/TrxBoardUtils/TrxBoardStructures.h
  6. 8
      include/model/hardware/core/lowLevelApi/register/dsp/Dsp.h
  7. 32
      include/model/hardware/core/lowLevelApi/register/dsp/registerDefinition/AtgcLut.h
  8. 44
      include/model/hardware/core/lowLevelApi/register/dsp/registerDefinition/MlaOffset.h
  9. 31
      include/model/hardware/core/lowLevelApi/register/dsp/registerDefinition/NoiseRejectValue.h
  10. 65
      include/model/hardware/core/lowLevelApi/register/dsp/registerDefinition/ReceiverConfigurationLut.h
  11. 12
      include/model/hardware/core/lowLevelApi/register/misc/Misc.h
  12. 2
      include/model/hardware/core/lowLevelApi/register/misc/registerDefinition/FrameLostCount.h
  13. 118
      include/model/hardware/core/lowLevelApi/register/misc/registerDefinition/StatusVector.h
  14. 55
      include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/Index.h
  15. 2
      include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/RxParams.h
  16. 2
      include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/RxParamsDegree.h
  17. 2
      include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/RxParamsDelay.h
  18. 2
      include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/RxParamsPos.h
  19. 10
      include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/SramStructures.h
  20. 2
      include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/TxParams.h
  21. 2
      include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/TxParamsFocus.h
  22. 2
      include/model/hardware/device/SonoDeviceConstant.h
  23. 8
      include/model/scenarioGenerator/core/scenario/type/misc/ReceiverConfig.h
  24. 2
      include/model/scenarioGenerator/dto/hardware/HwScenarioDependent.h
  25. 8
      include/model/scenarioGenerator/dto/hardware/SramIndex.h
  26. 104
      mainwindow.cpp
  27. 2
      mainwindow.h
  28. 70
      mainwindow.ui
  29. 56
      src/model/hardware/core/lowLevelApi/TrxBoard.cpp
  30. 2
      src/model/hardware/core/lowLevelApi/register/Register.cpp
  31. 24
      src/model/hardware/core/lowLevelApi/register/boardsCtrlMngt/BoardsCtrlMngt.cpp
  32. 22
      src/model/hardware/core/lowLevelApi/register/dsp/Dsp.cpp
  33. 12
      src/model/hardware/core/lowLevelApi/register/misc/Misc.cpp
  34. 13
      src/model/hardware/core/lowLevelApi/register/sram/Sram.cpp
  35. 22
      src/model/scenarioGenerator/core/scenario/B/BModeScenario.cpp
  36. 16
      src/model/scenarioGenerator/core/scenario/Bm/BmModeScenario.cpp

2
developHw.pro.user

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE QtCreatorProject>
<!-- Written by QtCreator 4.10.0, 2022-02-05T08:18:24. -->
<!-- Written by QtCreator 4.10.0, 2022-08-17T15:51:52. -->
<qtcreator>
<data>
<variable>EnvironmentId</variable>

155
hdf5Scenario/hdf5Scenario.cpp

@ -19,9 +19,9 @@ void Hdf5::hdf5Path(const string &h5Path)
void Hdf5::scenarioRead(ScenGenHardwareOutput_t &scenParams)
{
/****************** /sramParameters/frameType ******************/
datasetBranch <float_t>("/sramParameters/frameType", floatArray);
scenParams.frameType = static_cast<quint8>(floatArray[0]);
// /****************** /sramParameters/frameType ******************/
// datasetBranch <float_t>("/sramParameters/frameType", floatArray);
// scenParams.frameType = static_cast<quint8>(floatArray[0]);
/****************** /sramParameters/totalTxShotNo ******************/
datasetBranch <float_t>("/sramParameters/totalTxShotNo", floatArray);
@ -67,23 +67,35 @@ void Hdf5::scenarioRead(ScenGenHardwareOutput_t &scenParams)
for (quint32 var = 0; var < scenParams.totalTxShotNumber; var++)
scenParams.indexParams.firstLineInFrame.push_back(static_cast<bool>(floatArray[var]));
/**************** /sramParameters/indexParameters/lastLineInFrame ********************/
datasetBranch <float_t>("/sramParameters/indexParameters/lastLineInFrame", floatArray);
scenParams.indexParams.lastLineInFrame.clear();
/**************** /sramParameters/indexParameters/startOfSubBatch ********************/
datasetBranch <float_t>("/sramParameters/indexParameters/startOfSubBatch", floatArray);
scenParams.indexParams.startOfSubBatch.clear();
for (quint32 var = 0; var < scenParams.totalTxShotNumber; var++)
scenParams.indexParams.lastLineInFrame.push_back(static_cast<bool>(floatArray[var]));
scenParams.indexParams.startOfSubBatch.push_back(static_cast<bool>(floatArray[var]));
/**************** /sramParameters/indexParameters/dLineNum ********************/
datasetBranch <float_t>("/sramParameters/indexParameters/dLineNum", floatArray);
scenParams.indexParams.dLineNum.clear();
/**************** /sramParameters/indexParameters/endOfSubBatch ********************/
datasetBranch <float_t>("/sramParameters/indexParameters/endOfSubBatch", floatArray);
scenParams.indexParams.endOfSubBatch.clear();
for (quint32 var = 0; var < scenParams.totalTxShotNumber; var++)
scenParams.indexParams.dLineNum.push_back(static_cast<quint32>(floatArray[var]));
scenParams.indexParams.endOfSubBatch.push_back(static_cast<quint32>(floatArray[var]));
/**************** /sramParameters/indexParameters/dEnsembleNum ********************/
datasetBranch <float_t>("/sramParameters/indexParameters/dEnsembleNum", floatArray);
scenParams.indexParams.dEnsembleNum.clear();
/**************** /sramParameters/indexParameters/endOfSubFrame ********************/
datasetBranch <float_t>("/sramParameters/indexParameters/endOfSubFrame", floatArray);
scenParams.indexParams.endOfSubFrame.clear();
for (quint32 var = 0; var < scenParams.totalTxShotNumber; var++)
scenParams.indexParams.dEnsembleNum.push_back(static_cast<quint32>(floatArray[var]));
scenParams.indexParams.endOfSubFrame.push_back(static_cast<quint32>(floatArray[var]));
/**************** /sramParameters/indexParameters/endOfEnsemble ********************/
datasetBranch <float_t>("/sramParameters/indexParameters/endOfEnsemble", floatArray);
scenParams.indexParams.endOfEnsemble.clear();
for (quint32 var = 0; var < scenParams.totalTxShotNumber; var++)
scenParams.indexParams.endOfEnsemble.push_back(static_cast<quint32>(floatArray[var]));
/**************** /sramParameters/indexParameters/isLastSubBatch ********************/
datasetBranch <float_t>("/sramParameters/indexParameters/isLastSubBatch", floatArray);
scenParams.indexParams.isLastSubBatch.clear();
for (quint32 var = 0; var < scenParams.totalTxShotNumber; var++)
scenParams.indexParams.isLastSubBatch.push_back(static_cast<quint32>(floatArray[var]));
/**************** /sramParameters/txParameters/txFocusXPos ********************/
datasetBranch <float_t>("/sramParameters/txParameters/txFocusXPos", floatArray);
@ -544,22 +556,31 @@ void Hdf5::scenarioRead(ScenGenHardwareOutput_t &scenParams)
focusNo.push_back(static_cast<quint32>(floatArray[j]));
}
/**************** /registerParameters/receiverConfigProperties/lineFilterEn ********************/
datasetBranch <float_t>("/registerParameters/receiverConfigProperties/lineFilterEn", floatArray);
QList<quint32> lineFilterEn;
/**************** /registerParameters/receiverConfigProperties/iqDataCrossEn ********************/
datasetBranch <float_t>("/registerParameters/receiverConfigProperties/iqDataCrossEn", floatArray);
QList<quint32> iqDataCrossEn;
for (quint32 j = 0; j < scenParams.hwRegister.receiverConfigTypeNumber; j++)
{
lineFilterEn.push_back(static_cast<quint32>(floatArray[j]));
iqDataCrossEn.push_back(static_cast<quint32>(floatArray[j]));
}
/**************** /registerParameters/receiverConfigProperties/dpeEn ********************/
datasetBranch <float_t>("/registerParameters/receiverConfigProperties/dpeEn", floatArray);
QList<quint32> dpeEn;
/**************** /registerParameters/receiverConfigProperties/logEn ********************/
datasetBranch <float_t>("/registerParameters/receiverConfigProperties/logEn", floatArray);
QList<quint32> logEn;
for (quint32 j = 0; j < scenParams.hwRegister.receiverConfigTypeNumber; j++)
{
logEn.push_back(static_cast<quint32>(floatArray[j]));
}
/**************** /registerParameters/receiverConfigProperties/dTgcEn ********************/
datasetBranch <float_t>("/registerParameters/receiverConfigProperties/dTgcEn", floatArray);
QList<quint32> dTgcEn;
for (quint32 j = 0; j < scenParams.hwRegister.receiverConfigTypeNumber; j++)
{
dpeEn.push_back(static_cast<quint32>(floatArray[j]));
dTgcEn.push_back(static_cast<quint32>(floatArray[j]));
}
/**************** /registerParameters/receiverConfigProperties/ddcEn ********************/
@ -571,13 +592,22 @@ void Hdf5::scenarioRead(ScenGenHardwareOutput_t &scenParams)
ddcEn.push_back(static_cast<quint32>(floatArray[j]));
}
/**************** /registerParameters/receiverConfigProperties/wmfEn ********************/
datasetBranch <float_t>("/registerParameters/receiverConfigProperties/wmfEn", floatArray);
QList<quint32> wmfEn;
/**************** /registerParameters/receiverConfigProperties/frameType ********************/
datasetBranch <float_t>("/registerParameters/receiverConfigProperties/frameType", floatArray);
QList<quint32> frameType;
for (quint32 j = 0; j < scenParams.hwRegister.receiverConfigTypeNumber; j++)
{
frameType.push_back(static_cast<quint32>(floatArray[j]));
}
/**************** /registerParameters/receiverConfigProperties/noiseRejectEn ********************/
datasetBranch <float_t>("/registerParameters/receiverConfigProperties/noiseRejectEn", floatArray);
QList<quint32> noiseRejectEn;
for (quint32 j = 0; j < scenParams.hwRegister.receiverConfigTypeNumber; j++)
{
wmfEn.push_back(static_cast<quint32>(floatArray[j]));
noiseRejectEn.push_back(static_cast<quint32>(floatArray[j]));
}
/**************** /registerParameters/receiverConfigProperties ********************/
@ -586,24 +616,47 @@ void Hdf5::scenarioRead(ScenGenHardwareOutput_t &scenParams)
for (qint32 j = 0; j < scenParams.hwRegister.receiverConfigTypeNumber; j++)
{
receiverCfgObj.mla = receiverCfgMla.at(j);
receiverCfgObj.stb = stb.at(j);
receiverCfgObj.ddcEn = ddcEn.at(j);
receiverCfgObj.absEn = absEn.at(j);
receiverCfgObj.dpeEn = dpeEn.at(j);
receiverCfgObj.logEn = logEn.at(j);
receiverCfgObj.stbEn = stbEn.at(j);
receiverCfgObj.wmfEn = wmfEn.at(j);
receiverCfgObj.lpfSel = lpfSel.at(j);
receiverCfgObj.dTgcEn = dTgcEn.at(j);
receiverCfgObj.aTgcSel = aTgcSel.at(j);
receiverCfgObj.focusNo = focusNo.at(j);
receiverCfgObj.lineMode = lineMode.at(j);
receiverCfgObj.mla = receiverCfgMla.at(j);
receiverCfgObj.frameType = frameType.at(j);
receiverCfgObj.dcCancelEn = dcCancelEn.at(j);
receiverCfgObj.ncoFreqSel = ncoFreqSel.at(j);
receiverCfgObj.lineFilterEn = lineFilterEn.at(j);
receiverCfgObj.iqDataCrossEn = iqDataCrossEn.at(j);
receiverCfgObj.noiseRejectEn = noiseRejectEn.at(j);
receiverCfgObj.subtractFilterEn = subtractFilterEn.at(j);
scenParams.hwRegister.receiverConfigProps.push_back(receiverCfgObj);
}
scenParams.hwRegister.mlaOffsetAddr.clear();
/**************** /registerParameters/sramFrameParameters/bOffset *****************/
datasetBranch <float_t>("/registerParameters/sramFrameParameters/bOffset", floatArray);
scenParams.hwRegister.mlaOffsetAddr.push_back(static_cast<quint32>(floatArray[0]));
/**************** /registerParameters/sramFrameParameters/dOffset *****************/
datasetBranch <float_t>("/registerParameters/sramFrameParameters/dOffset", floatArray);
scenParams.hwRegister.mlaOffsetAddr.push_back(static_cast<quint32>(floatArray[0]));
/**************** /registerParameters/sramFrameParameters/bLastOffset *****************/
datasetBranch <float_t>("/registerParameters/sramFrameParameters/bLastOffset", floatArray);
scenParams.hwRegister.mlaOffsetAddr.push_back(static_cast<quint32>(floatArray[0]));
/**************** /registerParameters/sramFrameParameters/dLastOffset *****************/
datasetBranch <float_t>("/registerParameters/sramFrameParameters/dLastOffset", floatArray);
scenParams.hwRegister.mlaOffsetAddr.push_back(static_cast<quint32>(floatArray[0]));
/**************** /registerParameters/noiseRejectValue *****************/
datasetBranch <float_t>("/registerParameters/noiseRejectValue", floatArray);
scenParams.hwRegister.noiseRejectValue = static_cast<quint32>(floatArray[0]);
}
@ -624,19 +677,43 @@ void Hdf5::prbDependParamsRead(ScenPrbDepHardwareParam &prbDepParams)
prbDepParams.prbDepParams.apodizationLut.push_back(tempApodization);
}
/**************** /registerParameters/aTgcLut ********************/
datasetBranch <float_t>("/registerParameters/aTgcLut", floatArray);
prbDepParams.prbDepParams.atgcLut.clear();
QList <quint32> tempAtgc;
/************ /registerParameters/aTgcParameters/aTgcLut ****************/
datasetBranch <float_t>("/registerParameters/aTgcParameters/aTgcLut", floatArray);
QList<QList<quint32>> atgcLut;
for (quint32 i = 0; i < 4; i++)
{
QList<quint32> temp;
for (quint32 j = 0; j < 256; j++)
{
temp.push_back(static_cast<quint32>(floatArray[j + i * 256]));
}
atgcLut.push_back(temp);
}
/******* /registerParameters/aTgcParameters/aTgcCompensationLut *********/
datasetBranch <float_t>("/registerParameters/aTgcParameters/aTgcCompensationLut", floatArray);
QList<QVector<float>> atgcCompensationLut;
for (quint32 i = 0; i < 4; i++)
{
tempAtgc.clear();
for (quint32 j = 0; j < 128; j++)
QVector<float> temp;
for (quint32 j = 0; j < 256; j++)
{
tempAtgc.push_back(static_cast<quint32>(floatArray[j + i * 128]));
temp.push_back(floatArray[j + i * 256]);
}
prbDepParams.prbDepParams.atgcLut.push_back(tempAtgc);
atgcCompensationLut.push_back(temp);
}
/******************* /registerParameters/aTgc **********************/
for (qint8 i = 0; i < 4; i++)
{
Atgc atgcObj;
atgcObj.clear();
atgcObj.atgcLut = atgcLut.at(i);
atgcObj.atgcCompensateLut = atgcCompensationLut.at(i);
prbDepParams.prbDepParams.atgcLut.push_back(atgcObj);
}
/**************** /registerParameters/lpfLut ********************/

2
include/model/hardware/core/lowLevelApi/TrxBoard.h

@ -123,6 +123,8 @@ private:
ReceiverConfiguration* configLut;
QVector<QVector<float> > blendWeight;
quint8 receiverConfigTypeNumber;
QList<quint32> mlaOffsetAddr;
quint32 noiseReject;
ScenHwRegister();
~ScenHwRegister();
};

4
include/model/hardware/core/lowLevelApi/TrxBoardUtils/ScenParamsRanges.h

@ -20,8 +20,8 @@
/****************** SRAM *****************/
#define TOTAL_TX_SHOT_NUMBER_MAX 131072U
#define RX_BEAMFORMER_NUMBER_MAX 11264
#define FOCUS_TYPE_NUMBER_MAX 11264U
#define RX_BEAMFORMER_NUMBER_MAX 14563U
#define FOCUS_TYPE_NUMBER_MAX 14563U
/************* Scenario Index ************/
#define SCENARIO_INDEX_MAX 131072U

2
include/model/hardware/core/lowLevelApi/TrxBoardUtils/TrxBoardStructures.h

@ -57,7 +57,7 @@ struct ScenPrbDepHwRegister
{
QList<quint8> lpfScaleCoeff;
QList<QList<quint32>> lpfLut;
QList<QList<quint32>> atgcLut;
QList<Atgc> atgcLut;
QList<QList<quint32>> apodizationLut;
};

8
include/model/hardware/core/lowLevelApi/register/dsp/Dsp.h

@ -3,10 +3,12 @@
#include "registerDefinition/ReceiverConfigurationLut.h"
#include "registerDefinition/LineFilterCoefficient.h"
#include "registerDefinition/NoiseRejectValue.h"
#include "registerDefinition/StbCoefficient.h"
#include "registerDefinition/FrequencyLut.h"
#include "registerDefinition/BlendWeight.h"
#include "registerDefinition/ManualAtgc.h"
#include "registerDefinition/MlaOffset.h"
#include "registerDefinition/DtgcLut.h"
#include "registerDefinition/AtgcLut.h"
#include "registerDefinition/BfScale.h"
@ -27,10 +29,12 @@ class Dsp
private:
ReceiverConfigurationLut* _configLut;
LineFilterCoefficient* _lineFilterLut;
NoiseRejectValue* _noiseReject;
StbCoefficient* _stbLut;
FrequencyLut* _freqLut;
BlendWeight* _blendWeight;
ManualAtgc* _manualAtgc;
MlaOffset* _mlaOffset;
DtgcLut* _dtgcLut;
AtgcLut* _atgcLut;
BfScale* _bfScale;
@ -44,11 +48,13 @@ public:
void lineFilterCoefficient (QList<quint32>& lineFilterLut) const;
void lpfScaleCoefficient (QList<quint8>& lpfScaleCoeff) const;
void stbCoefficient (QList<quint32>& stbLut) const;
void mlaOffsetAddr(QList<quint32>& mlaLut) const;
void frequencyLut (QList<quint32>& freqLut) const;
void blendWeight (QList<QList<quint32>>& blendWeight) const;
void noiseReject(quint32& rejectValue) const;
void atgcMode (eAtgcMode mode, quint16 value) const;
void dtgcLut (QList<quint32>& dtgcLut) const;
void atgcLut (QList<QList<quint32>>& atgcLut) const;
void atgcLut (QList<Atgc> atgcLut) const;
void lpfLut (QList<QList<quint32>>& lpfLut) const;
};

32
include/model/hardware/core/lowLevelApi/register/dsp/registerDefinition/AtgcLut.h

@ -3,39 +3,59 @@
#include "model/hardware/core/lowLevelApi/register/Register.h"
#include "model/hardware/core/lowLevelApi/register/RegUtils.h"
#include "model/scenarioGenerator/core/general/Calculation.h"
#undef BAR
#define ATGC_LUT_MASK 0x00000FFF
#define ATGC_LUT_MASK 0x00000FFF
#define ATGC_COMPENSATE_LUT_MASK 0xFFFF0000
#define BAR 0
#define OFFSET 0x85000
#define LENGTH 128U
#define LENGTH 256U
struct Atgc
{
QList<quint32> atgcLut;
QVector<float> atgcCompensateLut;
void clear()
{
atgcLut.clear();
atgcCompensateLut.clear();
}
};
class AtgcLut : public Register
{
private:
QList<quint32> _atgcLut;
Atgc _atgc;
QVector<quint32> _atgcCompensateLutQ;
void prepareData(quint32 index) override
{
atgcLut->setValue(_atgcLut[static_cast<qint32>(index)]);
atgcLut->setValue(_atgc.atgcLut[static_cast<qint32>(index)]);
atgcCompensateLut->setValue(_atgcCompensateLutQ[static_cast<qint32>(index)]);
}
public:
Field* atgcLut;
Field* atgcCompensateLut;
void setAtgcLut (QList<quint32>& atgcLut) {
_atgcLut = atgcLut;
void setAtgcLut (Atgc atgc)
{
_atgc = atgc;
_atgcCompensateLutQ = Calculation::qntzr(_atgc.atgcCompensateLut, 0, 16, 8, 0, true, false);
}
AtgcLut(SonoDevice* device) : Register(BAR, OFFSET, device, LENGTH)
{
ADD_UNSIGNED_FIELD(atgcLut, ATGC_LUT_MASK);
ADD_UNSIGNED_FIELD(atgcCompensateLut, ATGC_COMPENSATE_LUT_MASK);
}
};
#undef ATGC_LUT_MASK
#undef ATGC_COMPENSATE_LUT_MASK
#undef BAR
#undef OFFSET

44
include/model/hardware/core/lowLevelApi/register/dsp/registerDefinition/MlaOffset.h

@ -0,0 +1,44 @@
#ifndef MLAOFFSET_H
#define MLAOFFSET_H
#include "model/hardware/core/lowLevelApi/register/Register.h"
#include "model/hardware/core/lowLevelApi/register/RegUtils.h"
#undef BAR
#define OFFSET_ADDR_MASK 0x001FFFFF
#define BAR 0
#define OFFSET 0X86020
#define LENGTH 4U
class MlaOffset : public Register
{
private:
QList<quint32> _mlaLut;
void prepareData(quint32 index) override
{
mlaOffsetLut->setValue(_mlaLut[static_cast<qint32>(index)]);
}
public:
Field* mlaOffsetLut;
void setMlaOffsetLut (QList<quint32>& mlaLut) {
_mlaLut = mlaLut;
}
MlaOffset(SonoDevice* device) : Register(BAR, OFFSET, device, LENGTH)
{
ADD_UNSIGNED_FIELD(mlaOffsetLut, OFFSET_ADDR_MASK);
}
};
#undef OFFSET_ADDR_MASK
#undef BAR
#undef OFFSET
#undef LENGTH
#endif // MLAOFFSET_H

31
include/model/hardware/core/lowLevelApi/register/dsp/registerDefinition/NoiseRejectValue.h

@ -0,0 +1,31 @@
#ifndef NOISEREJECTVALUE_H
#define NOISEREJECTVALUE_H
#include "model/hardware/core/lowLevelApi/register/Register.h"
#include "model/hardware/core/lowLevelApi/register/RegUtils.h"
#undef BAR
#define REJECT_VALUE_MASK 0x00FFFFFF
#define BAR 0
#define OFFSET 0x86034
class NoiseRejectValue : public Register
{
public:
Field* rejectValue;
NoiseRejectValue(SonoDevice* device) : Register(BAR, OFFSET, device)
{
ADD_UNSIGNED_FIELD(rejectValue, REJECT_VALUE_MASK);
}
};
#undef REJECT_VALUE_MASK
#undef BAR
#undef OFFSET
#undef LENGTH
#endif // NOISEREJECTVALUE_H

65
include/model/hardware/core/lowLevelApi/register/dsp/registerDefinition/ReceiverConfigurationLut.h

@ -17,10 +17,12 @@
#define LPF_SEL_PRP_MASK 0x00060000
#define ABS_EN_PRP_MASK 0x00080000
#define FOCUS_NO_PRP_MASK 0x00300000
#define LINE_FILTER_EN_PRP_MASK 0x00400000
#define NOISE_REJECTION_EN_PRP_MASK 0x00400000
#define DDC_EN_PRP_MASK 0x00800000
#define WMF_EN_PRP_MASK 0x01000000
#define DPE_EN_PRP_MASK 0x02000000
#define FRAME_TYPE_PRP_MASK 0x0F000000
#define IQ_DATA_CROSS_EN_PRP_MASK 0x10000000
#define LOG_EN_PRP_MASK 0x20000000
#define DTGC_EN_PRP_MASK 0x40000000
#define BAR 0U
#define OFFSET 0X80000
@ -39,10 +41,12 @@ struct ReceiverConfiguration
QList<quint32> lpfSel;
QList<quint32> absEn;
QList<quint32> focusNo;
QList<quint32> lineFilterEn;
QList<quint32> noiseRejectionEn;
QList<quint32> ddcEn;
QList<quint32> wmfEn;
QList<quint32> dpeEn;
QList<quint32> frameType;
QList<quint32> iqDataCrossEn;
QList<quint32> logEn;
QList<quint32> dTgcEn;
void clear()
{
mla.clear();
@ -56,10 +60,12 @@ struct ReceiverConfiguration
lpfSel.clear();
absEn.clear();
focusNo.clear();
lineFilterEn.clear();
noiseRejectionEn.clear();
ddcEn.clear();
wmfEn.clear();
dpeEn.clear();
frameType.clear();
iqDataCrossEn.clear();
logEn.clear();
dTgcEn.clear();
}
};
@ -98,17 +104,22 @@ private:
focusNoPrp->setValue(_configLut->focusNo.at(static_cast<qint32>(index)) - 1);
//value = _configLut->lineFilterEn.at(static_cast<qint32>(index)) ? 1 : 0;
lineFilterEnPrp->setValue(_configLut->lineFilterEn.at(static_cast<qint32>(index)));
//value = _configLut->noiseRejectionEn.at(static_cast<qint32>(index)) ? 1 : 0;
noiseRejectionEnPrp->setValue(_configLut->noiseRejectionEn.at(static_cast<qint32>(index)));
//value = _configLut->ddcEn.at(static_cast<qint32>(index)) ? 1 : 0;
ddcEnPrp->setValue(_configLut->ddcEn.at(static_cast<qint32>(index)));
//value = _configLut->wmfEn.at(static_cast<qint32>(index)) ? 1 : 0;
wmfEnPrp->setValue(_configLut->wmfEn.at(static_cast<qint32>(index)));
frameTypePrp->setValue(_configLut->frameType.at(static_cast<qint32>(index)));
//value = _configLut->dpeEn.at(static_cast<qint32>(index)) ? 1 : 0;
dpeEnPrp->setValue(_configLut->dpeEn.at(static_cast<qint32>(index)));
//value = _configLut->iqDataCrc.at(static_cast<qint32>(index)) ? 1 : 0;
iqDataCrossEncPrp->setValue(_configLut->iqDataCrossEn.at(static_cast<qint32>(index)));
//value = _configLut->logEn.at(static_cast<qint32>(index)) ? 1 : 0;
logEnPrp->setValue(_configLut->logEn.at(static_cast<qint32>(index)));
//value = _configLut->dTgcEnPrp.at(static_cast<qint32>(index)) ? 1 : 0;
dTgcEnPrp->setValue(_configLut->dTgcEn.at(static_cast<qint32>(index)));
}
public:
@ -123,10 +134,12 @@ public:
Field* lpfSelPrp;
Field* absEnPrp;
Field* focusNoPrp;
Field* lineFilterEnPrp;
Field* noiseRejectionEnPrp;
Field* ddcEnPrp;
Field* wmfEnPrp;
Field* dpeEnPrp;
Field* frameTypePrp;
Field* iqDataCrossEncPrp;
Field* logEnPrp;
Field* dTgcEnPrp;
void setReceiverConfigurationLut (ReceiverConfiguration* configLut)
{
@ -146,10 +159,12 @@ public:
ADD_UNSIGNED_FIELD(lpfSelPrp, LPF_SEL_PRP_MASK);
ADD_UNSIGNED_FIELD(absEnPrp, ABS_EN_PRP_MASK);
ADD_UNSIGNED_FIELD(focusNoPrp, FOCUS_NO_PRP_MASK);
ADD_UNSIGNED_FIELD(lineFilterEnPrp, LINE_FILTER_EN_PRP_MASK);
ADD_UNSIGNED_FIELD(noiseRejectionEnPrp, NOISE_REJECTION_EN_PRP_MASK);
ADD_UNSIGNED_FIELD(ddcEnPrp, DDC_EN_PRP_MASK);
ADD_UNSIGNED_FIELD(wmfEnPrp, WMF_EN_PRP_MASK);
ADD_UNSIGNED_FIELD(dpeEnPrp, DPE_EN_PRP_MASK);
ADD_UNSIGNED_FIELD(frameTypePrp, FRAME_TYPE_PRP_MASK);
ADD_UNSIGNED_FIELD(iqDataCrossEncPrp, IQ_DATA_CROSS_EN_PRP_MASK);
ADD_UNSIGNED_FIELD(logEnPrp, LOG_EN_PRP_MASK);
ADD_UNSIGNED_FIELD(dTgcEnPrp, DTGC_EN_PRP_MASK);
}
};
@ -164,10 +179,12 @@ public:
#undef LPF_SEL_PRP_MASK
#undef ABS_EN_PRP_MASK
#undef FOCUS_NO_PRP_MASK
#undef LINE_FILTER_EN_PRP_MASK
#undef NOISE_REJECTION_EN_PRP_MASK
#undef DDC_EN_PRP_MASK
#undef WMF_EN_PRP_MASK
#undef DPE_EN_PRP_MASK
#undef FRAME_TYPE_PRP_MASK
#undef IQ_DATA_CROSS_EN_PRP_MASK
#undef LOG_EN_PRP_MASK
#undef DTGC_EN_PRP_MASK
#undef BAR
#undef OFFSET

12
include/model/hardware/core/lowLevelApi/register/misc/Misc.h

@ -17,10 +17,10 @@ struct StatusVec
bool sram2ParityErr;
bool mpsErr;
bool scenPriErr;
bool scenGtErr;
bool scenSyncAckErr;
bool scenSramErr;
bool syncFifoErr;
bool syncPointErr;
bool mlaSyncFifoErr;
bool mlaSyncPointErr;
bool dintrlvFifoErr;
bool dintrlvPointErr;
bool pulserThd;
@ -28,7 +28,11 @@ struct StatusVec
bool pgErr;
bool probeDisconnectErr;
bool fanFault;
bool frameLost;
bool dintrlvFrameLost;
bool dintrlvOffsetAddrErr;
bool dintrlvSramOver4MErr;
bool ddcLpfReloadErr;
bool adcFlagSyncErr;
bool emulDmaTransferErr;
bool dmaCtrlTransferErr;
};

2
include/model/hardware/core/lowLevelApi/register/misc/registerDefinition/FrameLostCount.h

@ -9,7 +9,7 @@
#define LOST_COUNT 0x000000FF
#define BAR 0U
#define OFFSET 0x86028
#define OFFSET 0x8603C
class FrameLostCount : public Register
{

118
include/model/hardware/core/lowLevelApi/register/misc/registerDefinition/StatusVector.h

@ -7,24 +7,28 @@
#undef BAR
#define PROBE_DETECTION_INTERRUPT_MASK 0x00000001
#define SRAM_1_PARITY_Err_MASK 0x00000002
#define SRAM_2_PARITY_Err_MASK 0x00000004
#define MPS_Err_MASK 0x00000008
#define SCEN_RPI_Err_MASK 0x00000010
#define SCEN_GT_Err_MASK 0x00000020
#define SCEN_SRAM_Err_MASK 0x00000040
#define SYNC_FIFO_Err_MASK 0x00000080
#define SYNC_POINT_Err_MASK 0x00000100
#define DINTRLV_FIFO_Err_MASK 0x00000200
#define DINTRLV_POINT_Err_MASK 0x00000400
#define SRAM_1_PARITY_ERR_MASK 0x00000002
#define SRAM_2_PARITY_ERR_MASK 0x00000004
#define MPS_ERR_MASK 0x00000008
#define SCEN_RPI_ERR_MASK 0x00000010
#define SCEN_SYNC_ACK_ERR_MASK 0x00000020
#define SCEN_SRAM_ERR_MASK 0x00000040
#define MLA_SYNC_FIFO_ERR_MASK 0x00000080
#define MLA_SYNC_POINT_ERR_MASK 0x00000100
#define DINTRLV_FIFO_ERR_MASK 0x00000200
#define DINTRLV_POINT_ERR_MASK 0x00000400
#define PULSER_THD_MASK 0x00000800
#define THERMAL_Err_MASK 0x00001000
#define PG_Err_MASK 0x00002000
#define PROBE_DISCONNECT_Err_MASK 0x00004000
#define THERMAL_ERR_MASK 0x00001000
#define PG_ERR_MASK 0x00002000
#define PROBE_DISCONNECT_ERR_MASK 0x00004000
#define FAN_FAULT_MASK 0x00008000
#define FRAME_LOST_MASK 0x00020000
#define EMUL_DMA_TRANSFER_Err_MASK 0x40000000
#define DMA_CTRL_TRANSFER_Err_MASK 0x80000000
#define DINTRLV_FRAME_LOST_MASK 0x00020000
#define DINTRLV_OFFSET_ADDR_ERR_MASK 0x00040000
#define DINTRLV_SRAM_OVER_4M_ERR_MASK 0x00080000
#define DDC_LPF_RELOAD_ERR_MASK 0x00100000
#define ADC_FLAG_SYNC_ERR_MASK 0x00200000
#define EMUL_DMA_TRANSFER_ERR_MASK 0x40000000
#define DMA_CTRL_TRANSFER_ERR_MASK 0x80000000
#define BAR 0U
#define OFFSET 0x0
@ -37,10 +41,10 @@ public:
Field* sram2ParityErr;
Field* mpsErr;
Field* scenPriErr;
Field* scenGtErr;
Field* scenSyncAckErr;
Field* scenSramErr;
Field* syncFifoErr;
Field* syncPointErr;
Field* mlaSyncFifoErr;
Field* mlaSyncPointErr;
Field* dintrlvFifoErr;
Field* dintrlvPointErr;
Field* pulserThd;
@ -48,52 +52,64 @@ public:
Field* pgErr;
Field* probeDisconnectErr;
Field* fanFault;
Field* frameLost;
Field* dintrlvFrameLost;
Field* dintrlvOffsetAddrErr;
Field* dintrlvSramOver4MErr;
Field* ddcLpfReloadErr;
Field* adcFlagSyncErr;
Field* emulDmaTransferErr;
Field* dmaCtrlTransferErr;
StatusVector(SonoDevice* device) : Register(BAR, OFFSET, device)
{
ADD_UNSIGNED_FIELD(probeDetChanInterrupt, PROBE_DETECTION_INTERRUPT_MASK);
ADD_UNSIGNED_FIELD(sram1ParityErr, SRAM_1_PARITY_Err_MASK);
ADD_UNSIGNED_FIELD(sram2ParityErr, SRAM_2_PARITY_Err_MASK);
ADD_UNSIGNED_FIELD(mpsErr, MPS_Err_MASK);
ADD_UNSIGNED_FIELD(scenPriErr, SCEN_RPI_Err_MASK);
ADD_UNSIGNED_FIELD(scenGtErr, SCEN_GT_Err_MASK);
ADD_UNSIGNED_FIELD(scenSramErr, SCEN_SRAM_Err_MASK);
ADD_UNSIGNED_FIELD(syncFifoErr, SYNC_FIFO_Err_MASK);
ADD_UNSIGNED_FIELD(syncPointErr, SYNC_POINT_Err_MASK);
ADD_UNSIGNED_FIELD(dintrlvFifoErr, DINTRLV_FIFO_Err_MASK);
ADD_UNSIGNED_FIELD(dintrlvPointErr, DINTRLV_POINT_Err_MASK);
ADD_UNSIGNED_FIELD(sram1ParityErr, SRAM_1_PARITY_ERR_MASK);
ADD_UNSIGNED_FIELD(sram2ParityErr, SRAM_2_PARITY_ERR_MASK);
ADD_UNSIGNED_FIELD(mpsErr, MPS_ERR_MASK);
ADD_UNSIGNED_FIELD(scenPriErr, SCEN_RPI_ERR_MASK);
ADD_UNSIGNED_FIELD(scenSyncAckErr, SCEN_SYNC_ACK_ERR_MASK);
ADD_UNSIGNED_FIELD(scenSramErr, SCEN_SRAM_ERR_MASK);
ADD_UNSIGNED_FIELD(mlaSyncFifoErr, MLA_SYNC_FIFO_ERR_MASK);
ADD_UNSIGNED_FIELD(mlaSyncPointErr, MLA_SYNC_POINT_ERR_MASK);
ADD_UNSIGNED_FIELD(dintrlvFifoErr, DINTRLV_FIFO_ERR_MASK);
ADD_UNSIGNED_FIELD(dintrlvPointErr, DINTRLV_POINT_ERR_MASK);
ADD_UNSIGNED_FIELD(pulserThd, PULSER_THD_MASK);
ADD_UNSIGNED_FIELD(thermalErr, THERMAL_Err_MASK);
ADD_UNSIGNED_FIELD(pgErr, PG_Err_MASK);
ADD_UNSIGNED_FIELD(probeDisconnectErr, PROBE_DISCONNECT_Err_MASK);
ADD_UNSIGNED_FIELD(thermalErr, THERMAL_ERR_MASK);
ADD_UNSIGNED_FIELD(pgErr, PG_ERR_MASK);
ADD_UNSIGNED_FIELD(probeDisconnectErr, PROBE_DISCONNECT_ERR_MASK);
ADD_UNSIGNED_FIELD(fanFault, FAN_FAULT_MASK);
ADD_UNSIGNED_FIELD(frameLost, FRAME_LOST_MASK);
ADD_UNSIGNED_FIELD(emulDmaTransferErr, EMUL_DMA_TRANSFER_Err_MASK);
ADD_UNSIGNED_FIELD(dmaCtrlTransferErr, DMA_CTRL_TRANSFER_Err_MASK);
ADD_UNSIGNED_FIELD(dintrlvFrameLost, DINTRLV_FRAME_LOST_MASK);
ADD_UNSIGNED_FIELD(dintrlvOffsetAddrErr, DINTRLV_OFFSET_ADDR_ERR_MASK);
ADD_UNSIGNED_FIELD(dintrlvSramOver4MErr, DINTRLV_SRAM_OVER_4M_ERR_MASK);
ADD_UNSIGNED_FIELD(ddcLpfReloadErr, DDC_LPF_RELOAD_ERR_MASK);
ADD_UNSIGNED_FIELD(adcFlagSyncErr, ADC_FLAG_SYNC_ERR_MASK);
ADD_UNSIGNED_FIELD(emulDmaTransferErr, EMUL_DMA_TRANSFER_ERR_MASK);
ADD_UNSIGNED_FIELD(dmaCtrlTransferErr, DMA_CTRL_TRANSFER_ERR_MASK);
}
};
#undef PROBE_DETECTION_INTERRUPT_MASK
#undef SRAM_1_PARITY_Err_MASK
#undef SRAM_2_PARITY_Err_MASK
#undef MPS_Err_MASK
#undef SCEN_RPI_Err_MASK
#undef SCEN_GT_Err_MASK
#undef SCEN_SRAM_Err_MASK
#undef SYNC_FIFO_Err_MASK
#undef SYNC_POINT_Err_MASK
#undef DINTRLV_FIFO_Err_MASK
#undef DINTRLV_POINT_Err_MASK
#undef SRAM_1_PARITY_ERR_MASK
#undef SRAM_2_PARITY_ERR_MASK
#undef MPS_ERR_MASK
#undef SCEN_RPI_ERR_MASK
#undef SCEN_SYNC_ACK_ERR_MASK
#undef SCEN_SRAM_ERR_MASK
#undef MLA_SYNC_FIFO_ERR_MASK
#undef MLA_SYNC_POINT_ERR_MASK
#undef DINTRLV_FIFO_ERR_MASK
#undef DINTRLV_POINT_ERR_MASK
#undef PULSER_THD_MASK
#undef THERMAL_Err_MASK
#undef PG_Err_MASK
#undef PROBE_DISCONNECT_Err_MASK
#undef THERMAL_ERR_MASK
#undef PG_ERR_MASK
#undef PROBE_DISCONNECT_ERR_MASK
#undef FAN_FAULT_MASK
#undef FRAME_LOST_MASK
#undef EMUL_DMA_TRANSFER_Err_MASK
#undef DINTRLV_FRAME_LOST_MASK
#undef DINTRLV_OFFSET_ADDR_ERR_MASK
#undef DINTRLV_SRAM_OVER_4M_ERR_MASK
#undef DDC_LPF_RELOAD_ERR_MASK
#undef ADC_FLAG_SYNC_ERR_MASK
#undef EMUL_DMA_TRANSFER_ERR_MASK
#undef DMA_CTRL_TRANSFER_Err_MASK
#undef BAR

55
include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/Index.h

@ -11,10 +11,11 @@
#define RECEIVER_CONFIGURATION_INDEX_MASK 0x0000000000E00000
#define PULSE_PROPERTIES_INDEX_MASK 0x0000000007000000
#define FIRST_LINE_IN_FRAME_MASK 0x0000000008000000
#define LAST_LINE_IN_FRAME_MASK 0x0000000010000000
#define D_LINE_NUM_MASK 0x0000001FE0000000
#define D_ENSEMBLE_NUM_MASK 0x000003E000000000
#define FRAME_TYPE_MASK 0xFF00000000000000
#define START_OF_SUB_BATCH_MASK 0x0000000010000000
#define END_OF_SUB_BATCH_MASK 0x0000000020000000
#define END_OF_SUB_FRAME_MASK 0x0000000040000000
#define END_OF_ENSEMBLE_MASK 0x0000000080000000
#define IS_LAST_SUB_BATCH_MASK 0x0000000100000000
#define BAR 1U
#define OFFSET 0x0
@ -41,17 +42,20 @@ private:
value = _index->firstLineInFrame[static_cast<qint32>(index)] ? 1 : 0;
firstLineInFrame->setValueLong(value);
value = _index->lastLineInFrame[static_cast<qint32>(index)] ? 1 : 0;
lastLineInFrame->setValueLong(value);
value = _index->startOfSubBatch[static_cast<qint32>(index)] ? 1 : 0;
startOfSubBatch->setValueLong(value);
dLineNum->setValueLong(_index->dLineNum[static_cast<qint32>(index)]);
value = _index->endOfSubBatch[static_cast<qint32>(index)] ? 1 : 0;
endOfSubBatch->setValueLong(value);
dEnsembleNum->setValueLong(_index->dEnsembleNum[static_cast<qint32>(index)]);
value = _index->endOfSubFrame[static_cast<qint32>(index)] ? 1 : 0;
endOfSubFrame->setValueLong(value);
if (index==0)
frameType->setValueLong(_index->frameType);
else
frameType->setValueLong(0);
value = _index->endOfEnsemble[static_cast<qint32>(index)] ? 1 : 0;
endOfEnsemble->setValueLong(value);
value = _index->isLastSubBatch[static_cast<qint32>(index)] ? 1 : 0;
isLastSubBatch->setValueLong(value);
}
public:
@ -59,10 +63,11 @@ public:
Field* receiverConfigurationIndex;
Field* pulsePropertiesIndex;
Field* firstLineInFrame;
Field* lastLineInFrame;
Field* dLineNum;
Field* dEnsembleNum;
Field* frameType;
Field* startOfSubBatch;
Field* endOfSubBatch;
Field* endOfSubFrame;
Field* endOfEnsemble;
Field* isLastSubBatch;
void setIndex (SramIndex* index)
{
@ -75,10 +80,11 @@ public:
ADD_UNSIGNED_FIELD_LONG(receiverConfigurationIndex, RECEIVER_CONFIGURATION_INDEX_MASK);
ADD_UNSIGNED_FIELD_LONG(pulsePropertiesIndex, PULSE_PROPERTIES_INDEX_MASK );
ADD_UNSIGNED_FIELD_LONG(firstLineInFrame, FIRST_LINE_IN_FRAME_MASK );
ADD_UNSIGNED_FIELD_LONG(lastLineInFrame, LAST_LINE_IN_FRAME_MASK );
ADD_UNSIGNED_FIELD_LONG(dLineNum, D_LINE_NUM_MASK );
ADD_UNSIGNED_FIELD_LONG(dEnsembleNum, D_ENSEMBLE_NUM_MASK );
ADD_UNSIGNED_FIELD_LONG(frameType, FRAME_TYPE_MASK );
ADD_UNSIGNED_FIELD_LONG(startOfSubBatch, START_OF_SUB_BATCH_MASK );
ADD_UNSIGNED_FIELD_LONG(endOfSubBatch, END_OF_SUB_BATCH_MASK );
ADD_UNSIGNED_FIELD_LONG(endOfSubFrame, END_OF_SUB_FRAME_MASK );
ADD_UNSIGNED_FIELD_LONG(endOfEnsemble, END_OF_ENSEMBLE_MASK );
ADD_UNSIGNED_FIELD_LONG(isLastSubBatch, IS_LAST_SUB_BATCH_MASK );
}
};
@ -86,10 +92,11 @@ public:
#undef PULSE_PROPERTIES_INDEX_MASK
#undef RECEIVER_CONFIGURATION_INDEX_MASK
#undef FIRST_LINE_IN_FRAME_MASK
#undef LAST_LINE_IN_FRAME_MASK
#undef D_LINE_NUM_MASK
#undef D_ENSEMBLE_NUM_MASK
#undef FRAME_TYPE_MASK
#undef START_OF_SUB_BATCH_MASK
#undef END_OF_SUB_BATCH_MASK
#undef END_OF_SUB_FRAME_MASK
#undef END_OF_ENSEMBLE_MASK
#undef IS_LAST_SUB_BATCH_MASK
#undef BAR
#undef OFFSET

2
include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/RxParams.h

@ -15,7 +15,7 @@
#define BAR 1U
#define OFFSET 0x100010
#define LENGTH 11264U
#define LENGTH 14563U
class RxParams : public Register
{

2
include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/RxParamsDegree.h

@ -15,7 +15,7 @@
#define BAR 1U
#define OFFSET 0x100018
#define LENGTH 11264U
#define LENGTH 14563U
class RxParamsDegree : public Register
{

2
include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/RxParamsDelay.h

@ -14,7 +14,7 @@
#define BAR 1U
#define OFFSET 0x100028
#define LENGTH 11264U
#define LENGTH 14563U
class RxParamsDelay : public Register

2
include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/RxParamsPos.h

@ -15,7 +15,7 @@
#define BAR 1U
#define OFFSET 0x100020
#define LENGTH 11264U
#define LENGTH 14563U
class RxParamsPos : public Register

10
include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/SramStructures.h

@ -9,13 +9,13 @@ struct SramIndex {
QVector<quint32> receiverConfigurationIndex;
QVector<quint32> pulsePropertiesIndex;
QVector<bool> firstLineInFrame;
QVector<bool> lastLineInFrame;
QVector<quint32> dLineNum;
QVector<quint32> dEnsembleNum;
quint8 frameType;
QVector<bool> startOfSubBatch;
QVector<bool> endOfSubBatch;
QVector<bool> endOfSubFrame;
QVector<bool> endOfEnsemble;
QVector<bool> isLastSubBatch;
};
struct SramRx {
QVector<float> rxActiveElementStep;
QVector<quint32> interceptPointFiringTime;

2
include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/TxParams.h

@ -14,7 +14,7 @@
#define BAR 1U
#define OFFSET 0x100000
#define LENGTH 11264U
#define LENGTH 14563U
class TxParams : public Register

2
include/model/hardware/core/lowLevelApi/register/sram/registerDefinition/TxParamsFocus.h

@ -14,7 +14,7 @@
#define BAR 1U
#define OFFSET 0x100008
#define LENGTH 11264U
#define LENGTH 14563U
class TxParamsFocus : public Register
{

2
include/model/hardware/device/SonoDeviceConstant.h

@ -20,7 +20,7 @@
#define DMA_CTRL_REG 0x00000008
#define START_COMMAND 0x00000001
#define STOP_COMMAND 0x11111110
#define STOP_COMMAND 0xFFFFFFFE
#define COUNTER_MASK 0x0000001F

8
include/model/scenarioGenerator/core/scenario/type/misc/ReceiverConfig.h

@ -15,10 +15,12 @@ struct ReceiverConfig_t {
quint32 lpfSel;
quint32 absEn;
quint32 focusNo;
quint32 lineFilterEn;
quint32 noiseRejectEn;
quint32 ddcEn;
quint32 wmfEn;
quint32 dpeEn;
quint32 frameType;
quint32 iqDataCrossEn;
quint32 logEn;
quint32 dTgcEn;
};
#endif //RECEIVERCONFIG_H

2
include/model/scenarioGenerator/dto/hardware/HwScenarioDependent.h

@ -24,6 +24,8 @@ struct HwRegister_t {
QList<QVector<quint32>> lpfLut;
QList<QVector<quint32>> atgcLut;
QList<QVector<quint32>> apodizationLut;
QList<quint32> mlaOffsetAddr;
quint32 noiseRejectValue;
};

8
include/model/scenarioGenerator/dto/hardware/SramIndex.h

@ -8,9 +8,11 @@ struct SramIndex_t {
QVector<quint32> pulsePropertiesIndex;
QVector<quint32> receiverConfigurationIndex;
QVector<bool> firstLineInFrame;
QVector<bool> lastLineInFrame;
QVector<quint32> dLineNum;
QVector<quint32> dEnsembleNum;
QVector<bool> startOfSubBatch;
QVector<bool> endOfSubBatch;
QVector<bool> endOfSubFrame;
QVector<bool> endOfEnsemble;
QVector<bool> isLastSubBatch;
};
#endif //SRAMINDEX_H

104
mainwindow.cpp

@ -447,7 +447,7 @@ void MainWindow::timeout()
changeLabelTextColor(ui->l_mps, color);
delay(1);
bool frameLost = _vec->frameLost;
bool frameLost = _vec->dintrlvFrameLost;
ui->l_frameLost->setText(QVariant(frameLost).toString());
color = frameLost ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_frameLost, color);
@ -465,10 +465,10 @@ void MainWindow::timeout()
changeLabelTextColor(ui->l_pulserThd, color);
delay(1);
bool scenGtErr = _vec->scenGtErr;
ui->l_scenGt->setText(QVariant(scenGtErr).toString());
color = scenGtErr ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_scenGt, color);
bool scenSyncAckErr = _vec->scenSyncAckErr;
ui->l_scenSyncAck->setText(QVariant(scenSyncAckErr).toString());
color = scenSyncAckErr ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_scenSyncAck, color);
delay(1);
bool scenPriErr = _vec->scenPriErr;
@ -489,13 +489,13 @@ void MainWindow::timeout()
changeLabelTextColor(ui->l_scenSram, color);
delay(1);
bool syncFifoErr = _vec->syncFifoErr;
bool syncFifoErr = _vec->mlaSyncFifoErr;
ui->l_syncFifo->setText(QVariant(syncFifoErr).toString());
color = syncFifoErr ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_syncFifo, color);
delay(1);
bool syncPointErr = _vec->syncPointErr;
bool syncPointErr = _vec->mlaSyncPointErr;
ui->l_syncPoint->setText(QVariant(syncPointErr).toString());
color = syncPointErr ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_syncPoint, color);
@ -549,6 +549,30 @@ void MainWindow::timeout()
changeLabelTextColor(ui->l_prbDetChg, color);
delay(1);
bool adcFlagSyncErr = _vec->adcFlagSyncErr;
ui->l_adcFlagSync->setText(QVariant(adcFlagSyncErr).toString());
color = adcFlagSyncErr ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_adcFlagSync, color);
delay(1);
bool ddcLpfReloadErr = _vec->ddcLpfReloadErr;
ui->l_ddcLpfReload->setText(QVariant(ddcLpfReloadErr).toString());
color = ddcLpfReloadErr ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_ddcLpfReload, color);
delay(1);
bool dintrlvOffsetAddrErr = _vec->dintrlvOffsetAddrErr;
ui->l_dintrlvOffsetAddr->setText(QVariant(dintrlvOffsetAddrErr).toString());
color = dintrlvOffsetAddrErr ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_dintrlvOffsetAddr, color);
delay(1);
bool dintrlvSramOver4MErr = _vec->dintrlvSramOver4MErr;
ui->l_dintrlvSramOver4M->setText(QVariant(dintrlvSramOver4MErr).toString());
color = dintrlvSramOver4MErr ? Qt::red : Qt::green;
changeLabelTextColor(ui->l_dintrlvSramOver4M, color);
delay(1);
if(_statusLogEn)
{
emit statusLogPS(_usd->readWord(0, 0));
@ -2482,22 +2506,9 @@ void MainWindow::setScenario(const QString& h5Path)
throw SonoException("No file is selected.");
}
AfeConfig _afeConfig;
_afeConfig.lowNf = lowNfDisable;
_afeConfig.lnaHpf = lnaHpfEnable;
_afeConfig.pgaHpf = pgaHpfEnable;
_afeConfig.lpfProg = LpfProg10MHz;
_afeConfig.pgaGain = pgaGain30db;
_afeConfig.pgaClamp = pgaClampDisable;
_afeConfig.powModes = lowNoise;
_afeConfig.actTermEn = actTermEnable;
_afeConfig.lnaGainGbl = lnaGainGbl24db;
_afeConfig.lnaHpfProg = lnaHpfProg200Khz;
_afeConfig.gblActiveTerm = gblActiveTerm50;
_afeConfig.pgaClampLevel = minus2dbfs;
_afeConfig.activeTermIndRes = actTermIndRes0;
_afeConfig.activeTermIndResEn = actTermIndResDisable;
_afeConfig.inputClampLevel = inputClampLvlAuto;
AfeConfig afeConfigObj;
afeConfig(afeConfigObj);
Hdf5 hdf;
ScenGenHardwareOutput_t scenParams;
@ -2509,14 +2520,14 @@ void MainWindow::setScenario(const QString& h5Path)
hdf.scenarioRead(scenParams);
hdf.prbDependParamsRead(prbDepParams);
prbDepParams.afeCfg = _afeConfig;
prbDepParams.afeCfg = afeConfigObj;
stbLut = hdf.stbRead();
lineFilterLut = hdf.lineFilterRead();
//lineFilterLut = hdf.lineFilterRead();
_trx.setScenario(scenParams);
_trx.setProbeDependParams(prbDepParams);
_trx.setLineFilterCoefficient(lineFilterLut);
//_trx.setLineFilterCoefficient(lineFilterLut);
_trx.setStbCoefficient(stbLut);
}
catch(SonoException& e)
@ -3211,25 +3222,32 @@ void MainWindow::on_btn_afeRead_clicked()
}
/*************************************************************************************************/
void MainWindow::afeConfig(AfeConfig &afeConfig)
{
afeConfig.lowNf = lowNfDisable;
afeConfig.lnaHpf = lnaHpfEnable;
afeConfig.pgaHpf = pgaHpfEnable;
afeConfig.lpfProg = LpfProg10MHz;
afeConfig.pgaGain = pgaGain30db;
afeConfig.pgaClamp = pgaClampDisable;
afeConfig.powModes = lowNoise;
afeConfig.actTermEn = actTermEnable;
afeConfig.lnaGainGbl = lnaGainGbl24db;
afeConfig.lnaHpfProg = lnaHpfProg200Khz;
afeConfig.gblActiveTerm = gblActiveTerm50;
afeConfig.pgaClampLevel = minus2dbfs;
afeConfig.activeTermIndRes = actTermIndRes0;
afeConfig.activeTermIndResEn = actTermIndResDisable;
afeConfig.inputClampLevel = inputClampLvlAuto;
}
void MainWindow::setAfeConfig()
{
AfeConfig _afeConfig;
_afeConfig.lowNf = lowNfDisable;
_afeConfig.lnaHpf = lnaHpfEnable;
_afeConfig.pgaHpf = pgaHpfEnable;
_afeConfig.lpfProg = LpfProg10MHz;
_afeConfig.pgaGain = pgaGain30db;
_afeConfig.pgaClamp = pgaClampDisable;
_afeConfig.powModes = lowNoise;
_afeConfig.actTermEn = actTermEnable;
_afeConfig.lnaGainGbl = lnaGainGbl24db;
_afeConfig.lnaHpfProg = lnaHpfProg200Khz;
_afeConfig.gblActiveTerm = gblActiveTerm50;
_afeConfig.pgaClampLevel = minus2dbfs;
_afeConfig.activeTermIndRes = actTermIndRes0;
_afeConfig.activeTermIndResEn = actTermIndResDisable;
_afeConfig.inputClampLevel = inputClampLvlAuto;
_trx.setAfeConfig(_afeConfig);
AfeConfig afeConfigObj;
afeConfig(afeConfigObj);
_trx.setAfeConfig(afeConfigObj);
}
/*************************************************************************************************/

2
mainwindow.h

@ -152,6 +152,8 @@ private:
void changeLabelTextColor(QLabel* label, QColor color);
void afeConfig (AfeConfig &afeConfig);
void setAfeConfig (void);
void logPcie(QString logPath, quint32 logCount, QLCDNumber* lcdCounter);

70
mainwindow.ui

@ -42,7 +42,7 @@
<string/>
</property>
<property name="currentIndex">
<number>6</number>
<number>0</number>
</property>
<widget class="QWidget" name="tab_0">
<attribute name="title">
@ -4092,9 +4092,9 @@
</widget>
</item>
<item>
<widget class="QLabel" name="l_scenGt">
<widget class="QLabel" name="l_scenSyncAck">
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;Scen GT&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;Scen Sync Ack&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string>false</string>
@ -4168,7 +4168,7 @@
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_34">
<layout class="QHBoxLayout" name="horizontalLayout_107">
<item>
<widget class="QLabel" name="l_thermal">
<property name="toolTip">
@ -4209,6 +4209,60 @@
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="l_frameLost">
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;Frame Lost&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string>false</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="l_dintrlvOffsetAddr">
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;D Interleave Offset Addr&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string>false</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_34">
<item>
<widget class="QLabel" name="l_dintrlvSramOver4M">
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;D Interleave SRAM Over 4M&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string>false</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="l_ddcLpfReload">
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;DDC LPF Reload&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string>false</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="l_adcFlagSync">
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;ADC Flag Sync&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string>false</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="l_emulDmaTrans">
<property name="toolTip">
@ -4229,14 +4283,10 @@
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_42">
<item>
<widget class="QLabel" name="l_frameLost">
<widget class="QLabel" name="l_Reserved">
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;Frame Lost&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:7pt; font-weight:600; font-style:italic;&quot;&gt;Reserved&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string>false</string>

56
src/model/hardware/core/lowLevelApi/TrxBoard.cpp

@ -738,23 +738,30 @@ void TrxBoard::setScenario(ScenGenHardwareOutput_t& scenGenHw)
_scenParams->hwRegister->configLut->stb.append(k.stb);
_scenParams->hwRegister->configLut->absEn.append(k.absEn);
_scenParams->hwRegister->configLut->ddcEn.append(k.ddcEn);
_scenParams->hwRegister->configLut->dpeEn.append(k.dpeEn);
_scenParams->hwRegister->configLut->logEn.append(k.logEn);
_scenParams->hwRegister->configLut->stbEn.append(k.stbEn);
_scenParams->hwRegister->configLut->wmfEn.append(k.wmfEn);
_scenParams->hwRegister->configLut->lpfSel.append(k.lpfSel);
_scenParams->hwRegister->configLut->dTgcEn.append(k.dTgcEn);
_scenParams->hwRegister->configLut->aTgcSel.append(k.aTgcSel);
_scenParams->hwRegister->configLut->focusNo.append(k.focusNo);
_scenParams->hwRegister->configLut->lineMode.append(k.lineMode);
_scenParams->hwRegister->configLut->frameType.append(k.frameType);
_scenParams->hwRegister->configLut->ncoFreqSel.append(k.ncoFreqSel);
_scenParams->hwRegister->configLut->dcCancelerEn.append(k.dcCancelEn);
_scenParams->hwRegister->configLut->lineFilterEn.append(k.lineFilterEn);
_scenParams->hwRegister->configLut->iqDataCrossEn.append(k.iqDataCrossEn);
_scenParams->hwRegister->configLut->noiseRejectionEn.append(k.noiseRejectEn);
_scenParams->hwRegister->configLut->subtractFilterEn.append(k.subtractFilterEn);
}
_scenParams->indexParams->dLineNum = scenGenHw.indexParams.dLineNum;
_scenParams->indexParams->frameType = scenGenHw.frameType;
_scenParams->indexParams->dEnsembleNum = scenGenHw.indexParams.dEnsembleNum;
_scenParams->indexParams->lastLineInFrame = scenGenHw.indexParams.lastLineInFrame;
_scenParams->hwRegister->mlaOffsetAddr = scenGenHw.hwRegister.mlaOffsetAddr;
_scenParams->hwRegister->noiseReject = scenGenHw.hwRegister.noiseRejectValue;
_scenParams->indexParams->endOfEnsemble = scenGenHw.indexParams.endOfEnsemble;
_scenParams->indexParams->endOfSubBatch = scenGenHw.indexParams.endOfSubBatch;
_scenParams->indexParams->endOfSubFrame = scenGenHw.indexParams.endOfSubFrame;
_scenParams->indexParams->isLastSubBatch = scenGenHw.indexParams.isLastSubBatch;
_scenParams->indexParams->startOfSubBatch = scenGenHw.indexParams.startOfSubBatch;
_scenParams->indexParams->firstLineInFrame = scenGenHw.indexParams.firstLineInFrame;
_scenParams->indexParams->shotPropertiesIndex = scenGenHw.indexParams.shotPropertiesIndex;
_scenParams->indexParams->pulsePropertiesIndex = scenGenHw.indexParams.pulsePropertiesIndex;
@ -912,6 +919,10 @@ void TrxBoard::setScenario (ScenGenHardwareParam* _scenParams)
}
this->_dsp->blendWeight(blendWeightQ);
this->_dsp->mlaOffsetAddr(_scenParams->hwRegister->mlaOffsetAddr);
this->_dsp->noiseReject(_scenParams->hwRegister->noiseReject);
///////////////////////////////// Sram setting ///////////////////////////////
this->_sram->setSramIndex(_scenParams->totalTxShotNumber, _scenParams->indexParams);
@ -967,17 +978,42 @@ void TrxBoard::setDtgcLut(QVector<float>& dtgcLut)
void TrxBoard::setFramesMetaData(const QByteArray& metaData) const
{
qint32 metaLength = metaData.length();
if(!metaLength)
{
throw SonoException("Meta data array is empty.");
}
if(static_cast<quint32>(metaLength) > META_DATA_LENGTH * 8)
{
throw SonoException("Meta data byte array is out of range.");
}
QList<quint64> clear;
for(quint8 i=0; i < META_DATA_LENGTH; i++)
{
clear.append(0);
}
this->_sram->setSramMetaData(clear);
QList<quint64> data;
QByteArray temp;
qint32 num(0);
while(num < metaData.size())
while(metaLength)
{
for(quint8 j = 0; j < sizeof(quint64); j++)
{
temp.append(metaData[j + num]);
if(metaLength)
{
temp.append(metaData[j + num]);
metaLength--;
}
else
{
temp.append(qint8(0));
}
}
data.push_back(byteArray2UintLittleEndian<quint64>(temp));
temp.clear();
num += sizeof(quint64);

2
src/model/hardware/core/lowLevelApi/register/Register.cpp

@ -107,7 +107,7 @@ void Register::updateArray(bool isVariable, quint16 arrayLength) //update arr
value |= _fields[j]->getRegisterWriteValue();
}
_device->device.writeWord(_bar, _offset + i * 4, value);
_device->device.writeWord(_bar, _offset + i * 4, value);
}
}

24
src/model/hardware/core/lowLevelApi/register/boardsCtrlMngt/BoardsCtrlMngt.cpp

@ -800,18 +800,18 @@ void BoardsCtrlMngt::mpsHvSet(float& hva, float& hvb) const
_mpsDacs->hvaValue = hva;
}
//if(hvb > HVB_MAX_VALUE)
//{
//_mpsDacs->hvbValue = HVB_MAX_VALUE;
//}
//else if (hvb < HVB_Offset)
//{
//_mpsDacs->hvbValue = HVB_Offset;
//}
//else
//{
//_mpsDacs->hvbValue = hvb;
//}
// if(hvb > HVB_MAX_VALUE)
// {
// _mpsDacs->hvbValue = HVB_MAX_VALUE;
// }
// else if (hvb < HVB_Offset)
// {
// _mpsDacs->hvbValue = HVB_Offset;
// }
// else
// {
// _mpsDacs->hvbValue = hvb;
// }
_mpsDacs->hvbValue = HVB_Offset;
_mpsDacs->cwdValue = CWD_Offset;

22
src/model/hardware/core/lowLevelApi/register/dsp/Dsp.cpp

@ -4,10 +4,12 @@ Dsp::Dsp(SonoDevice *device)
{
_configLut = new ReceiverConfigurationLut (device);
_lineFilterLut = new LineFilterCoefficient (device);
_noiseReject = new NoiseRejectValue (device);
_stbLut = new StbCoefficient (device);
_freqLut = new FrequencyLut (device);
_blendWeight = new BlendWeight (device);
_manualAtgc = new ManualAtgc (device);
_mlaOffset = new MlaOffset (device);
_dtgcLut = new DtgcLut (device);
_atgcLut = new AtgcLut (device);
_bfScale = new BfScale (device);
@ -19,8 +21,10 @@ Dsp::~Dsp()
{
delete _lineFilterLut;
delete _blendWeight;
delete _noiseReject;
delete _manualAtgc;
delete _configLut;
delete _mlaOffset;
delete _freqLut;
delete _dtgcLut;
delete _atgcLut;
@ -108,13 +112,13 @@ void Dsp::dtgcLut(QList<quint32> &dtgcLut) const
this->_dtgcLut->updateArray();
}
void Dsp::atgcLut(QList<QList<quint32> > &atgcLut) const
void Dsp::atgcLut(QList<Atgc> atgcLut) const
{
quint32 baseOffset = this->_atgcLut->getCurrentOffset();
foreach (QList<quint32> temp, atgcLut)
foreach (Atgc tempObj, atgcLut)
{
this->_atgcLut->setAtgcLut(temp);
this->_atgcLut->setAtgcLut(tempObj);
this->_atgcLut->updateArray();
quint32 curOffset = this->_atgcLut->getCurrentOffset();
this->_atgcLut->changeOffset(curOffset + ATGC_OFFSET);
@ -137,3 +141,15 @@ void Dsp::lpfLut(QList<QList<quint32>> &lpfLut) const
this->_lpfLut->changeOffset(baseOffset);
}
void Dsp::mlaOffsetAddr(QList<quint32> &mlaLut) const
{
this->_mlaOffset->setMlaOffsetLut(mlaLut);
this->_mlaOffset->updateArray();
}
void Dsp::noiseReject(quint32 &rejectValue) const
{
this->_noiseReject->rejectValue->setValue(rejectValue);
this->_noiseReject->update();
}

12
src/model/hardware/core/lowLevelApi/register/misc/Misc.cpp

@ -46,21 +46,25 @@ void Misc::getStatusVector(StatusVec *status) const
status->pgErr = ((this->_status->pgErr->getValue()) != 0);
status->mpsErr = ((this->_status->mpsErr->getValue()) != 0);
status->fanFault = ((this->_status->fanFault->getValue()) != 0);
status->frameLost = ((this->_status->frameLost->getValue()) != 0);
status->pulserThd = ((this->_status->pulserThd->getValue()) != 0);
status->scenGtErr = ((this->_status->scenGtErr->getValue()) != 0);
status->scenPriErr = ((this->_status->scenPriErr->getValue()) != 0);
status->thermalErr = ((this->_status->thermalErr->getValue()) != 0);
status->syncFifoErr = ((this->_status->syncFifoErr->getValue()) != 0);
status->scenSramErr = ((this->_status->scenSramErr->getValue()) != 0);
status->syncPointErr = ((this->_status->syncPointErr->getValue()) != 0);
status->scenSyncAckErr = ((this->_status->scenSyncAckErr->getValue()) != 0);
status->mlaSyncFifoErr = ((this->_status->mlaSyncFifoErr->getValue()) != 0);
status->dintrlvFifoErr = ((this->_status->dintrlvFifoErr->getValue()) != 0);
status->adcFlagSyncErr = ((this->_status->adcFlagSyncErr->getValue()) != 0);
status->sram1ParityErr = ((this->_status->sram1ParityErr->getValue()) != 0);
status->sram2ParityErr = ((this->_status->sram2ParityErr->getValue()) != 0);
status->mlaSyncPointErr = ((this->_status->mlaSyncPointErr->getValue()) != 0);
status->ddcLpfReloadErr = ((this->_status->ddcLpfReloadErr->getValue()) != 0);
status->dintrlvPointErr = ((this->_status->dintrlvPointErr->getValue()) != 0);
status->dintrlvFrameLost = ((this->_status->dintrlvFrameLost->getValue()) != 0);
status->dmaCtrlTransferErr = ((this->_status->dmaCtrlTransferErr->getValue()) != 0);
status->emulDmaTransferErr = ((this->_status->emulDmaTransferErr->getValue()) != 0);
status->probeDisconnectErr = ((this->_status->probeDisconnectErr->getValue()) != 0);
status->dintrlvOffsetAddrErr = ((this->_status->dintrlvOffsetAddrErr->getValue()) != 0);
status->dintrlvSramOver4MErr = ((this->_status->dintrlvSramOver4MErr->getValue()) != 0);
status->probeDetChanInterrupt = ((this->_status->probeDetChanInterrupt->getValue()) != 0);
}

13
src/model/hardware/core/lowLevelApi/register/sram/Sram.cpp

@ -73,19 +73,20 @@ void Sram::setSramRx(QVector<quint8> &rxBeamFormerNumber, quint32 &focusTypeNumb
this->_rxDegree->changeOffset(rxDegreeBaseOffset); // return to base offset address
this->_rxPos->changeOffset(rxPosBaseOffset); // return to base offset address
this->_rxDelay->changeOffset(rxDelayBaseOffset); // return to base offset address
this->_rxDelay->changeOffset(rxDelayBaseOffset); // return to base offset address
}
void Sram::setSramMetaData(QList<quint64> &metaData) const
{
this->_metaData->setSoftwareMetaData(metaData);
this->_metaData->updateArrayLong(META_DATA_INTERVAL, META_DATA_LENGTH);
quint32 metaDataBaseOffset = this->_metaData->getCurrentOffset();
this->_metaData->changeOffset(META_DATA_OFFSET+metaDataBaseOffset);
this->_metaData->setSoftwareMetaData(metaData);
this->_metaData->updateArrayLong(META_DATA_INTERVAL, META_DATA_LENGTH);
for(quint8 i=0; i < 3; i++)
{
this->_metaData->changeOffset(i * META_DATA_OFFSET + metaDataBaseOffset);
this->_metaData->updateArrayLong(META_DATA_INTERVAL, static_cast<quint32>(metaData.length()));
}
this->_metaData->changeOffset(metaDataBaseOffset); // return to base offset address
}

22
src/model/scenarioGenerator/core/scenario/B/BModeScenario.cpp

@ -64,9 +64,9 @@ void BModeScenario::calcIndexParameters()
hardwareOuput.indexParams.receiverConfigurationIndex.clear();
hardwareOuput.indexParams.shotPropertiesIndex.clear();
hardwareOuput.indexParams.firstLineInFrame.clear();
hardwareOuput.indexParams.lastLineInFrame.clear();
hardwareOuput.indexParams.dLineNum.clear();
hardwareOuput.indexParams.dEnsembleNum.clear();
// hardwareOuput.indexParams.lastLineInFrame.clear();
// hardwareOuput.indexParams.dLineNum.clear();
// hardwareOuput.indexParams.dEnsembleNum.clear();
auto criFrameNumber = softwareOutput.scenarioDependent.criFrameNumber;
auto frameLineNumber = frameParams[0]->txLineNumber * criFrameNumber;
@ -112,15 +112,15 @@ void BModeScenario::calcIndexParameters()
hardwareOuput.indexParams.firstLineInFrame =
Calculation::repMat(hardwareOuput.indexParams.firstLineInFrame, criFrameNumber);
hardwareOuput.indexParams.lastLineInFrame.append(
Calculation::zeros<bool>(frameShotNumber - 1));
hardwareOuput.indexParams.lastLineInFrame.append(Calculation::ones<bool>(1));
// hardwareOuput.indexParams.lastLineInFrame.append(
// Calculation::zeros<bool>(frameShotNumber - 1));
// hardwareOuput.indexParams.lastLineInFrame.append(Calculation::ones<bool>(1));
hardwareOuput.indexParams.lastLineInFrame =
Calculation::repMat(hardwareOuput.indexParams.lastLineInFrame, criFrameNumber);
// hardwareOuput.indexParams.lastLineInFrame =
// Calculation::repMat(hardwareOuput.indexParams.lastLineInFrame, criFrameNumber);
hardwareOuput.indexParams.dLineNum = Calculation::zeros<quint32>(totalTxShotNumber);
hardwareOuput.indexParams.dEnsembleNum = Calculation::zeros<quint32>(totalTxShotNumber);
// hardwareOuput.indexParams.dLineNum = Calculation::zeros<quint32>(totalTxShotNumber);
// hardwareOuput.indexParams.dEnsembleNum = Calculation::zeros<quint32>(totalTxShotNumber);
}
/*************************************************************************************************/
@ -255,7 +255,7 @@ void BModeScenario::calcReceiverConfigProperties()
temp.lpfSel = 1;
temp.absEn = true;
temp.focusNo = frameParams[0]->focusNumber;
temp.lineFilterEn = true;
//temp.lineFilterEn = true;
hardwareOuput.hwRegister.receiverConfigProps.append(temp);
}

16
src/model/scenarioGenerator/core/scenario/Bm/BmModeScenario.cpp

@ -265,7 +265,7 @@ void BmModeScenario::calcIndexParameters()
hardwareOuput.indexParams.shotPropertiesIndex.clear();
hardwareOuput.indexParams.firstLineInFrame.clear();
hardwareOuput.indexParams.lastLineInFrame.clear();
// hardwareOuput.indexParams.lastLineInFrame.clear();
hardwareOuput.indexParams.firstLineInFrame.push_back(true);
@ -275,7 +275,7 @@ void BmModeScenario::calcIndexParameters()
{
hardwareOuput.indexParams.shotPropertiesIndex.push_back(1);
hardwareOuput.indexParams.firstLineInFrame.push_back(false);
hardwareOuput.indexParams.lastLineInFrame.push_back(false);
// hardwareOuput.indexParams.lastLineInFrame.push_back(false);
}
else
{
@ -291,14 +291,14 @@ void BmModeScenario::calcIndexParameters()
hardwareOuput.indexParams.firstLineInFrame.append(
Calculation::repElem<bool>({false}, bTxShotNumber - 1));
hardwareOuput.indexParams.lastLineInFrame.append(
Calculation::repElem<bool>({false}, bTxShotNumber - 1));
hardwareOuput.indexParams.lastLineInFrame.append(true);
// hardwareOuput.indexParams.lastLineInFrame.append(
// Calculation::repElem<bool>({false}, bTxShotNumber - 1));
// hardwareOuput.indexParams.lastLineInFrame.append(true);
}
}
hardwareOuput.indexParams.dLineNum = Calculation::zeros<quint32>(totalTxShotNumber);
hardwareOuput.indexParams.dEnsembleNum = Calculation::zeros<quint32>(totalTxShotNumber);
// hardwareOuput.indexParams.dLineNum = Calculation::zeros<quint32>(totalTxShotNumber);
// hardwareOuput.indexParams.dEnsembleNum = Calculation::zeros<quint32>(totalTxShotNumber);
}
/*************************************************************************************************/
@ -412,7 +412,7 @@ void BmModeScenario::calcReceiverConfigProperties()
ReceiverConfig_t temp;
temp.lineMode = lineModeVals[i];
temp.stbEn = stbEnVals[i];
temp.lineFilterEn = lineFilterEnVals[i];
//temp.lineFilterEn = lineFilterEnVals[i];
temp.mla = frameParams[i]->mla;
temp.aTgcSel = 1;
temp.stb = frameParams[i]->stb;

Loading…
Cancel
Save