From 9367670a535dbb0d2d24f90f97dbce0083de0500 Mon Sep 17 00:00:00 2001 From: "Ryan@SOLARIS_testStation" Date: Fri, 18 Oct 2024 17:54:43 -0400 Subject: [PATCH] bug fix of Scope, only-1-channel for QDC --- Scope.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Scope.cpp b/Scope.cpp index 372e719..65cde71 100644 --- a/Scope.cpp +++ b/Scope.cpp @@ -372,6 +372,8 @@ void Scope::StartScope(){ digi[ID]->SetBits(DPP::PHA::DPPAlgorithmControl2_G, DPP::PHA::Bit_DPPAlgorithmControl2::LocalShapeTriggerMode, 0, ch); digi[ID]->SetBits(DPP::PHA::DPPAlgorithmControl2_G, DPP::PHA::Bit_DPPAlgorithmControl2::LocalTrigValidMode, 0, ch); + + digi[ID]->WriteRegister(DPP::RegChannelEnableMask, (1 << ch)); } @@ -384,14 +386,17 @@ void Scope::StartScope(){ digi[ID]->SetBits(DPP::PSD::DPPAlgorithmControl2_G, DPP::PSD::Bit_DPPAlgorithmControl2::LocalShapeTriggerMode, 0, ch); digi[ID]->SetBits(DPP::PSD::DPPAlgorithmControl2_G, DPP::PSD::Bit_DPPAlgorithmControl2::LocalTrigValidMode, 0, ch); + + digi[ID]->WriteRegister(DPP::RegChannelEnableMask, (1 << ch)); } if( digi[ID]->GetDPPType() == DPPTypeCode::DPP_QDC_CODE ){ dppAlg = digi[ID]->GetSettingFromMemory(DPP::QDC::DPPAlgorithmControl, ch); digi[ID]->SetBits(DPP::QDC::DPPAlgorithmControl, DPP::QDC::Bit_DPPAlgorithmControl::TriggerMode, 0, ch); //set self-triiger + + digi[ID]->WriteRegister(DPP::RegChannelEnableMask, (1 << ch/8)); } - digi[ID]->WriteRegister(DPP::RegChannelEnableMask, (1 << ch)); //=========== start digi[ID]->WriteRegister(DPP::SoftwareClear_W, 1);