*Trigger information stored in muDst*

For W analysis I need the following :

* bXing7, full bXing48, 8bit-Spin
* 32triggerBits, offline trigger ID
* full DSM tree infor for the barrel: Layer 0,1,2, lastDsm
* full raw L2ResultArray (I can unpack details myself)
* BBC: TDC & ADC from 16 small tails
* ZDC: 3 tower ADC, 16 SMD ADC

----
VPD low threshold in QT->DSM
=  yes in StVpdTriggerDetector

VPD high threshold in QT->DSM
= currently data is NOT stored in mudst
 But hardware (signal splitter) is not here yet neither

VPD in TOF electronics
= I assume its in TOF mudst class... but you need to ask TOF experts.

----
----
'''Below is actual the code with names of variables as of 2006.'''
......
 StTriggerData2005 trgAkio5(trgD, mRunNo);

 //....................
 mJetT->lastDsm= *(trgAkio5.getDsm3());

 //....................
 mJetT->tcuBits= trgAkio5.tcuBits();
 mJetT->L1sum0=trgD->TrgSum.L1Sum[0];
 mJetT->L2sum0=trgD->TrgSum.L2Sum[0];

 mJetT->bx7=trgAkio5.bunchId7Bit();
 mJetT->bx48=trgAkio5.bunchId48Bit();
 mJetT->spin8=trgAkio5.spinBit() ;

 // raw 48 bit bXing
 mJetT->bXingHi=trgD->TrgSum.DSMdata.BCdata[3];
 mJetT->bXingLo1=trgD->TrgSum.DSMdata.BCdata[10];
 mJetT->bXingLo0=trgD->TrgSum.DSMdata.BCdata[11];


 mJetT->bbcTimeDiff=trgAkio5.bbcTimeDifference();
 mJetT->runId=mRunNo;
 mJetT->eveId=mEveInp;
 mJetT->token=trgAkio5.token();

 int j;
 // ETOW  L0 DSM data
 for(j=0;j<TrgJetTree::EpSize;j++) {
   mJetT->eemcHT[j] =trgAkio5.eemcHighTower(j,0);
   mJetT->eemcTPS[j]=trgAkio5.eemcJetPatch(j,0);
 }

 // BTOW  L0 DSM data
 for(j=0;j<TrgJetTree::BpSize;j++) {
   mJetT->bemcHT[j] =trgAkio5.bemcHighTower(j,0);
   mJetT->bemcTPS[j]=trgAkio5.bemcJetPatch(j,0);
 }

//................. unpack  L2Result[]....
 int l2jetOff=trgAkio5.L2ResultsOffset(l2Dijet);
 const unsigned int *l2res=trgD->TrgSum.L2Result;
  for (int k=0;k<32;k++) printf("k=%2d  val=0x%04x\n",k,l2res[k]);
  L2jetResults2006 *jetRes= ( L2jetResults2006 *) &l2res[l2jetOff];
  L2jetResults2006_print(jetRes);
  unsigned char cSum=L2jetResults2006_doCheckSum(jetRes);
  assert(cSum==0);


 //............BBC
 int i;
 for(i=0;i<TrgJetTree::mxBbc;i++) {
   int ew=0;
   for(ew=0;ew<TrgJetTree::EastWest; ew++) {
     mJetT->bbcAdc[ew][i]=trgAkio5.bbcADC((StBeamDirection)ew,i+1);
     mJetT->bbcTdc[ew][i]=trgAkio5.bbcTDC((StBeamDirection)ew,i+1);
     if(i<8)mJetT->bbcAdcL[ew][i]=trgAkio5.bbcADC((StBeamDirection)ew,16+i+1);
   }
 }

 //.............ZDC
 int ew=0;
 for(ew=0;ew<TrgJetTree::EastWest; ew++) {
   for(i=0;i<TrgJetTree::mxZdc;i++) {
     mJetT->zdcAdc[ew][i]=trgAkio5.zdcADC((StBeamDirection)ew,i+1);
   }
   mJetT->zdcAdcSum[ew]=trgAkio5.zdcUnAttenuated((StBeamDirection)ew);
   mJetT->zdcTdc[ew]=trgAkio5.zdcTDC((StBeamDirection)ew);
 }
 //............ZDC-SMD vs. raw channel
 for(i=0; i<TrgJetTree::mxZdcSmdRaw; i++) {
   mJetT->zdcSmdRaw[i]= trgD->rawTriggerDet[0].ZDCSMD[i];
 }
 for(i=0; i<-16; i++) {
   aa[i]= trgAkio5.zdcAtChannel(i));
 }