00001 #ifndef _CSCDBL1TPPARAMETERSCONDITIONS_H 00002 #define _CSCDBL1TPPARAMETERSCONDITIONS_H 00003 00004 #include <memory> 00005 #include <cmath> 00006 #include "FWCore/Framework/interface/SourceFactory.h" 00007 #include "FWCore/Framework/interface/Frameworkfwd.h" 00008 #include "FWCore/Framework/interface/ESProducer.h" 00009 #include "FWCore/Framework/interface/Event.h" 00010 #include "FWCore/Framework/interface/MakerMacros.h" 00011 #include "FWCore/Framework/interface/EventSetupRecordIntervalFinder.h" 00012 #include "FWCore/Framework/interface/ESHandle.h" 00013 #include "FWCore/Framework/interface/EventSetup.h" 00014 #include "FWCore/ParameterSet/interface/ParameterSet.h" 00015 00016 #include <DataFormats/MuonDetId/interface/CSCDetId.h> 00017 #include "CondFormats/CSCObjects/interface/CSCDBL1TPParameters.h" 00018 #include "CondFormats/DataRecord/interface/CSCDBL1TPParametersRcd.h" 00019 00020 class CSCDBL1TPParametersConditions: public edm::ESProducer, public edm::EventSetupRecordIntervalFinder { 00021 public: 00022 CSCDBL1TPParametersConditions(const edm::ParameterSet&); 00023 ~CSCDBL1TPParametersConditions(); 00024 00025 00026 inline static CSCDBL1TPParameters * prefillCSCDBL1TPParameters(); 00027 00028 typedef const CSCDBL1TPParameters * ReturnType; 00029 00030 ReturnType produceCSCDBL1TPParameters(const CSCDBL1TPParametersRcd&); 00031 00032 private: 00033 // ----------member data --------------------------- 00034 void setIntervalFor(const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue&, edm::ValidityInterval & ); 00035 CSCDBL1TPParameters *CSCl1TPParameters ; 00036 00037 }; 00038 00039 #include<fstream> 00040 #include<vector> 00041 #include<iostream> 00042 00043 // to workaround plugin library 00044 inline CSCDBL1TPParameters * CSCDBL1TPParametersConditions::prefillCSCDBL1TPParameters() 00045 { 00046 00047 CSCDBL1TPParameters * cnl1tp = new CSCDBL1TPParameters(); 00048 00049 cnl1tp->setAlctFifoTbins(16); 00050 cnl1tp->setAlctFifoPretrig(10); 00051 cnl1tp->setAlctDriftDelay(2); 00052 cnl1tp->setAlctNplanesHitPretrig(3);//was 2, new is 3 00053 cnl1tp->setAlctNplanesHitPattern(4); 00054 cnl1tp->setAlctNplanesHitAccelPretrig(3);//was 2, new is 3 00055 cnl1tp->setAlctNplanesHitAccelPattern(4); 00056 cnl1tp->setAlctTrigMode(2); 00057 cnl1tp->setAlctAccelMode(0); 00058 cnl1tp->setAlctL1aWindowWidth(7); 00059 00060 cnl1tp->setClctFifoTbins(12); 00061 cnl1tp->setClctFifoPretrig(7); 00062 cnl1tp->setClctHitPersist(4);//was 6, new is 4 00063 cnl1tp->setClctDriftDelay(2); 00064 cnl1tp->setClctNplanesHitPretrig(3);//was 2, new is 3 00065 cnl1tp->setClctNplanesHitPattern(4); 00066 cnl1tp->setClctPidThreshPretrig(2); 00067 cnl1tp->setClctMinSeparation(10); 00068 00069 //the new parameters 00070 cnl1tp->setTmbMpcBlockMe1a(0); 00071 cnl1tp->setTmbAlctTrigEnable(0); 00072 cnl1tp->setTmbClctTrigEnable(0); 00073 cnl1tp->setTmbMatchTrigEnable(1); 00074 cnl1tp->setTmbMatchTrigWindowSize(7); 00075 cnl1tp->setTmbTmbL1aWindowSize(7); 00076 00077 return cnl1tp; 00078 } 00079 00080 00081 #endif