Commit e8ba366c authored by Andreas Persson's avatar Andreas Persson Committed by Sebastien Petitdemange

Don't enable AcquisitionStart trigger if FrameStart trigger is available

Signed-off-by: Sebastien Petitdemange's avatarSébastien Petitdemange <sebastien.petitdemange@esrf.fr>

New tag: basler-1.5.2
parent a079e461
......@@ -748,56 +748,37 @@ void Camera::setTrigMode(TrigMode mode)
try
{
if ( mode == IntTrig )
{
//- INTERNAL
GenApi::IEnumEntry *enumEntryFrameStart = Camera_->TriggerSelector.GetEntryByName("FrameStart");
if(enumEntryFrameStart && GenApi::IsAvailable(enumEntryFrameStart))
this->Camera_->TriggerSelector.SetValue( TriggerSelector_FrameStart );
else
this->Camera_->TriggerSelector.SetValue( TriggerSelector_AcquisitionStart );
this->Camera_->TriggerMode.SetValue( TriggerMode_Off );
GenApi::IEnumEntry *enumEntryFrameStart = Camera_->TriggerSelector.GetEntryByName("FrameStart");
if(enumEntryFrameStart && GenApi::IsAvailable(enumEntryFrameStart))
this->Camera_->TriggerSelector.SetValue( TriggerSelector_FrameStart );
if ( mode == IntTrig )
{
//- INTERNAL
this->Camera_->TriggerMode.SetValue( TriggerMode_Off );
this->Camera_->ExposureMode.SetValue(ExposureMode_Timed);
}
else if ( mode == ExtGate )
{
//- EXTERNAL - TRIGGER WIDTH
this->Camera_->TriggerSelector.SetValue( TriggerSelector_AcquisitionStart );
this->Camera_->TriggerMode.SetValue( TriggerMode_On );
GenApi::IEnumEntry *enumEntryFrameStart = Camera_->TriggerSelector.GetEntryByName("FrameStart");
if(enumEntryFrameStart && GenApi::IsAvailable(enumEntryFrameStart))
this->Camera_->TriggerSelector.SetValue( TriggerSelector_FrameStart );
this->Camera_->TriggerMode.SetValue( TriggerMode_On );
this->Camera_->AcquisitionFrameRateEnable.SetValue( false );
this->Camera_->ExposureMode.SetValue( ExposureMode_TriggerWidth );
}
else //ExtTrigSingle
{
//- EXTERNAL - TIMED
this->Camera_->TriggerSelector.SetValue( TriggerSelector_AcquisitionStart );
this->Camera_->TriggerMode.SetValue( TriggerMode_On );
GenApi::IEnumEntry *enumEntryFrameStart = Camera_->TriggerSelector.GetEntryByName("FrameStart");
if(enumEntryFrameStart && GenApi::IsAvailable(enumEntryFrameStart))
this->Camera_->TriggerSelector.SetValue( TriggerSelector_FrameStart );
this->Camera_->TriggerMode.SetValue( TriggerMode_On );
this->Camera_->AcquisitionFrameRateEnable.SetValue( false );
this->Camera_->ExposureMode.SetValue( ExposureMode_Timed );
}
}
catch (GenICam::GenericException &e)
catch (GenICam::GenericException &e)
{
// Error handling
THROW_HW_ERROR(Error) << e.GetDescription();
}
}
}
//-----------------------------------------------------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment