修复路径问题
1. 配置文件创建在程序所在目录; 2. csv文件(ximea温度)输出路径改为:/home/programRunLog/hyperspectralLog;
This commit is contained in:
@ -9,7 +9,8 @@ XimeaImager::XimeaImager()
|
||||
|
||||
//connect(this, SIGNAL(recordFinished()),this, SLOT());
|
||||
|
||||
m_configfile.setConfigfilePath("ximea.cfg");
|
||||
QString ximeaCfgFile = QDir::cleanPath(QCoreApplication::applicationDirPath() + QDir::separator() + "ximea.cfg");
|
||||
m_configfile.setConfigfilePath(ximeaCfgFile.toStdString());
|
||||
if(!m_configfile.isConfigfileExist())
|
||||
m_configfile.createConfigFile();
|
||||
m_configfile.parseConfigfile();
|
||||
@ -80,7 +81,10 @@ void XimeaImager::openImger()
|
||||
m_iImagerState = 101;
|
||||
emit ximeaImageStatus(m_iImagerState);
|
||||
|
||||
m_ximeaTemperatureCSVPath = "/home/rock/programRunLog/ximeaTemperature.csv";
|
||||
QDateTime curDateTime = QDateTime::currentDateTime();
|
||||
QString currentTime = curDateTime.toString("yyyy_MM_dd_hh_mm_ss");
|
||||
m_ximeaTemperatureCSVPath = QDir::cleanPath(QString::fromStdString("/home/programRunLog/hyperspectralLog") + QDir::separator() + "ximeaTemperature_" + currentTime + ".csv");
|
||||
// m_ximeaTemperatureCSVPath = "/home/ximeaTemperature.csv";
|
||||
emit recordXimeaTemperatureSignal(m_ximeaTemperatureCSVPath);
|
||||
}
|
||||
catch(int xiApiErrorCodes)
|
||||
@ -480,6 +484,10 @@ void XimeaImager::startRecord(double TimeDifferenceBetweensOSAndSbg,QString base
|
||||
// {
|
||||
// break;
|
||||
// }
|
||||
// if(m_iFrameCounter/getFramerate() > 5*60) //这个判断会导致丢帧率的大幅升高:5% → 20%,推测原因:除法耗时;
|
||||
// {
|
||||
// break;
|
||||
// }
|
||||
|
||||
// unsigned char pixel = *(unsigned char*)image.bp;//Default value: XI_MONO8
|
||||
// unsigned short pixel =*(unsigned short*)image.bp;//XI_RAW16
|
||||
@ -669,6 +677,7 @@ void XimeaImager::processXiApiErrorCodes(int xiApiErrorCodes)
|
||||
ofstream ximeaErrorFile(ximeaError.toStdString().c_str(),ios::app);
|
||||
|
||||
ximeaErrorFile<< xiApiErrorCodes << "\n";
|
||||
std::cout<<"XimeaImager::processXiApiErrorCodes-----------:未处理ximea异常代码:"<< xiApiErrorCodes <<std::endl;
|
||||
|
||||
ximeaErrorFile.close();
|
||||
|
||||
|
Reference in New Issue
Block a user