mirror of
http://172.16.0.230/r/SIF/TowerOptoSifAndSpectral.git
synced 2025-10-19 19:49:42 +08:00
添加了位置定标程序 及位置移动相关程序源码
This commit is contained in:
132
othersoft/shuttercali/source_rlx/sensor/SensorBase.h
Normal file
132
othersoft/shuttercali/source_rlx/sensor/SensorBase.h
Normal file
@ -0,0 +1,132 @@
|
||||
#pragma once
|
||||
|
||||
#include <QObject>
|
||||
/******************************************************
|
||||
* <20>ļ<EFBFBD><C4BC><EFBFBD> : SensorBase.cpp
|
||||
* <20><><EFBFBD><EFBFBD> : <20>豸<EFBFBD><E8B1B8><EFBFBD><EFBFBD>
|
||||
* <20><><EFBFBD><EFBFBD> :
|
||||
* <20><><EFBFBD><EFBFBD> : xin
|
||||
* <20><><EFBFBD><EFBFBD> : renlixin@iris-rs.cn
|
||||
* <20><><EFBFBD><EFBFBD> : 2021-1-15
|
||||
********************************************************
|
||||
* *
|
||||
* _ooOoo_ *
|
||||
* o8888888o *
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* O\ = /O *
|
||||
* ____/`---'\____ *
|
||||
* .' \\| |// `. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' | | *
|
||||
* \ .-\__ `-` ___/-. / *
|
||||
* ___`. .' /--.--\ `. . __ *
|
||||
* ."" '< `.___\_<|>_/___.' >'"". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `-. \_ __\ /__ _/ .-` / / *
|
||||
* ======`-.____`-.___\_____/___.-`____.-'====== *
|
||||
* `=---=' *
|
||||
* ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ *
|
||||
* <20><><EFBFBD>汣<EFBFBD><E6B1A3> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> *
|
||||
* *
|
||||
********************************************************/
|
||||
///һ<><D2BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>delete
|
||||
enum emDataType
|
||||
{
|
||||
DNVALUE=1,
|
||||
REFVALUE=2,
|
||||
DARKNESS=3
|
||||
};
|
||||
struct STROnePlot
|
||||
{
|
||||
long BandNum;
|
||||
float *Plot;
|
||||
bool isInit;
|
||||
float temp;
|
||||
float shutter;
|
||||
QStringList wavelenthlist;
|
||||
long maxDNvalue;
|
||||
bool hasDarkCorrect;
|
||||
emDataType DataType;
|
||||
STROnePlot() {
|
||||
BandNum = 0;
|
||||
isInit = false;
|
||||
hasDarkCorrect = false;
|
||||
Plot = nullptr;
|
||||
DataType = DNVALUE;
|
||||
}
|
||||
~STROnePlot() {
|
||||
if (!isInit)
|
||||
{
|
||||
delete[] Plot;
|
||||
isInit = false;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
};
|
||||
struct STRSensorInfo
|
||||
{
|
||||
QString SensorName;
|
||||
long maxValue;
|
||||
long BandNum;
|
||||
QString WavelenthStr;
|
||||
QStringList wavelenthlist;
|
||||
//double *wavelenth;
|
||||
bool isSensorInit;
|
||||
QString serialnumber;
|
||||
|
||||
};
|
||||
|
||||
class SensorBase : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
SensorBase();
|
||||
virtual ~SensorBase();
|
||||
//************************************
|
||||
// Method: <20><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
// FullName: SensorBase::initSensor
|
||||
// Access: virtual public
|
||||
// Returns: void
|
||||
// Qualifier:
|
||||
//************************************
|
||||
virtual bool initSensor(int id=0)=0;
|
||||
//************************************
|
||||
// Method: Settingshuttertime <20><><EFBFBD>û<EFBFBD><C3BB><EFBFBD>ʱ<EFBFBD><CAB1>
|
||||
// FullName: SensorBase::Settingshuttertime
|
||||
// Access: virtual public
|
||||
// Returns: void
|
||||
// Qualifier:
|
||||
// Parameter: int msc
|
||||
//************************************
|
||||
virtual void Settingshuttertime(float msc)=0;
|
||||
//************************************
|
||||
// Method: SettingTemprature <20><><EFBFBD><EFBFBD><EFBFBD>¶<EFBFBD>
|
||||
// FullName: SensorBase::SettingTemprature
|
||||
// Access: virtual public
|
||||
// Returns: void
|
||||
// Qualifier:
|
||||
// Parameter: float temp
|
||||
//************************************
|
||||
virtual void SettingTemprature(float temp)=0;
|
||||
virtual float GettingTempratrue() = 0;
|
||||
virtual STRSensorInfo GetSensorInfo()=0;
|
||||
virtual void SettingShutterOpen(bool isopen)=0;
|
||||
virtual void SettingSwitchShutter(bool isright)=0;
|
||||
virtual void GetOnePlot(STROnePlot &OnePlot,bool Dark=false)=0;
|
||||
virtual void CloseSensor()=0;
|
||||
|
||||
virtual void GetOneDark(STROnePlot &darkplot) = 0;
|
||||
|
||||
|
||||
|
||||
QString SensorType;
|
||||
int Sensorid;
|
||||
STRSensorInfo SensorInfo;
|
||||
STROnePlot DarkNess;
|
||||
|
||||
};
|
Reference in New Issue
Block a user