diff --git a/source/CaptureThread/AbstractFSController.cpp b/source/CaptureThread/AbstractFSController.cpp index 38b9aa3..8496078 100644 --- a/source/CaptureThread/AbstractFSController.cpp +++ b/source/CaptureThread/AbstractFSController.cpp @@ -226,7 +226,7 @@ int CAbstractFSController::PerformAutoExposure() dFactor = dTemp / (iDeviceDepth * m_fsInfo.fMaxFactor); iExposureTime = (float)(iExposureTime / dFactor); } - if (/*fExposureTime > 100 || */iExposureTime < 10) + if (/*fExposureTime > 100 || */iExposureTime < m_daDeviceAttr.iMinIntegrationTimeInMS) { bFlagIsAutoExposureOK = false; bFlagIsAutoExposureFailed = true; @@ -236,12 +236,12 @@ int CAbstractFSController::PerformAutoExposure() bIsLastValueOverflow = bIsValueOverflow; fLastExposureTime = fTempExposureTime; - if (iExposureTime > 120000) + if (iExposureTime > m_daDeviceAttr.iMaxIntegrationTimeInMS - 1) { bFlagIsAutoExposureOK = false; bFlagIsAutoExposureFailed = true; - float fPredictedExposureTime = 120000; - iRes = m_pFSCtrl->SetExposureTime(120000); + float fPredictedExposureTime = m_daDeviceAttr.iMaxIntegrationTimeInMS-1; + iRes = m_pFSCtrl->SetExposureTime(m_daDeviceAttr.iMaxIntegrationTimeInMS-1); if (iRes != 0) { qDebug() << "Err:PerformAutoExposure Failed.Exit Code:3" << " Thread ID:" << m_iThreadID; @@ -250,7 +250,7 @@ int CAbstractFSController::PerformAutoExposure() else { //qDebug() << "Warning:PerformAutoExposure exceed max integration time.Will be limited to 30sec"; - qDebug() << "Warning:PerformAutoExposure exceed max integration time.Will be limited to " << m_daDeviceAttr.iMaxIntegrationTimeInMS << "MS" << " Thread ID:" << m_iThreadID; + qDebug() << "Warning:PerformAutoExposure exceed max integration time.Will be limited to " << m_daDeviceAttr.iMaxIntegrationTimeInMS-1 << "MS" << " Thread ID:" << m_iThreadID; } bFlagIsOverMaxExposureTime = true; break; diff --git a/source/CaptureThread/MainDataGrabber.cpp b/source/CaptureThread/MainDataGrabber.cpp index d8b14a9..92ac2cd 100644 --- a/source/CaptureThread/MainDataGrabber.cpp +++ b/source/CaptureThread/MainDataGrabber.cpp @@ -499,7 +499,7 @@ int CMainDataGrabber::GrabOnceFinished() //emit SignalPushOneDataFrame(vecData); m_pmduUploader->SetData(vecData); - // emit SignalPushOneDataFrame(); + emit SignalPushOneDataFrame(); m_pdfpSaver->SetData(vecData); m_pdfpSaver->WriteDataFile(); m_iFlagIsCapturing = 0;