1 Star 0 Fork 0

xiongqiumin/DataGather

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
Config.h 1.53 KB
一键复制 编辑 原始数据 按行查看 历史
xiongqiumin 提交于 2020-12-23 17:45 . init
#pragma once
#include <array>
#include <QDataStream>
struct Param_HRF9828
{
Param_HRF9828();
int RangeIndex;
int DAQFreq;
double T0_Freq;
double T0_Duty;
double T1_Freq;
double T1_Duty;
double T2_Freq;
double T2_Duty;
std::array<double, 24> AO;
std::array<int, 14> DO;
std::array<QString, (24 + 14) * 2> Names;
std::array<double, (24) * 2> Coefs;
};
struct Param_USB9982
{
Param_USB9982();
int trigUnit();
int gatherSize(); //ɼС
int frameSize(); //floatС
bool Enable2G;
bool EnableInt;
bool EnableADD;
int CHCount;
int TriggerMode;
int TriggerSource;
int TriggerDelay;
int TriggerLevel;
int Thres;
int ADGain;
int ADDCnt;
int ADDThd;
int ClockDeci;
int ClockSel;
int GatherLength;
int GatherTime;
double PWMFreq;
};
QDataStream &operator<<(QDataStream &s, const Param_USB9982 &param);
QDataStream &operator>>(QDataStream &s, Param_USB9982 &param);
struct SaveConfig
{
SaveConfig();
bool saveFile;
QString savePre;
QString savePath;
int maxSize;
};
QDataStream &operator<<(QDataStream &s, const SaveConfig &param);
QDataStream &operator >> (QDataStream &s, SaveConfig &param);
class Config
{
public:
Config();
void save();
void load();
Param_HRF9828 hrf9828;
Param_USB9982 usb9982;
SaveConfig saveInfo;
protected:
void saveToStream(QDataStream &s);
void loadFromStream(QDataStream &s);
QByteArray backUp();
QByteArray m_backUp;
};
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/xiongqiumin/DataGather.git
[email protected]:xiongqiumin/DataGather.git
xiongqiumin
DataGather
DataGather
master

搜索帮助