1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
18 #include "AliMUONTriggerIO.h"
22 #include "AliMpHelper.h"
23 #include "AliMpConstants.h"
25 #include "AliMpFiles.h"
26 #include "AliMpDDLStore.h"
27 #include "AliMpLocalBoard.h"
28 #include "AliMpTriggerCrate.h"
29 #include "AliMUONTriggerLut.h"
30 #include "AliMUONCalibParamNI.h"
31 #include "AliMUONVStore.h"
34 #include <Riostream.h>
37 /// \class AliMUONTriggerIO
39 /// Handles read/write of masks and LUT to/from online files,
40 /// to be used by Shuttle and Trigger DA.
42 /// \author Laurent Aphecetche, Christian Finck Subatech
43 /// \author Bogdan Vulpescu, LPC Clermont-Ferrand
46 ClassImp(AliMUONTriggerIO)
49 //_____________________________________________________________________________
50 AliMUONTriggerIO::AliMUONTriggerIO()
55 fDDLs(22) // FIXME should be in cst
59 fTriggerCrates.SetOwner(true);
60 fTriggerCrates.SetSize(AliMpConstants::LocalBoardNofChannels());
62 fLocalBoards.SetOwner(true);
63 fLocalBoards.SetSize(AliMpConstants::TotalNofLocalBoards()); // included non-notified boards
66 //_____________________________________________________________________________
67 AliMUONTriggerIO::AliMUONTriggerIO(const char* regionalFileToRead)
75 ReadRegional(regionalFileToRead,0);
78 //_____________________________________________________________________________
79 AliMUONTriggerIO::~AliMUONTriggerIO()
84 //_____________________________________________________________________________
86 AliMUONTriggerIO::DeCompAddress(UChar_t &ypos, UChar_t &ytri, UChar_t &xdev, UChar_t &xpos,
87 UShort_t address) const
89 /// decompose the 15-bits address
94 // UChar_t bitsXpos = 5;
96 UShort_t maskYpos = 0x000F; // ...0 00001111
97 UShort_t maskYtri = 0x0001; // ...0 00000001
98 UShort_t maskXdev = 0x001F; // ...0 00011111
99 UShort_t maskXpos = 0x001F; // ...0 00011111
101 ypos = address & maskYpos;
102 ytri = (address >> bitsYpos) & maskYtri;
103 xdev = (address >> (bitsYpos+bitsYtri)) & maskXdev;
104 xpos = (address >> (bitsYpos+bitsYtri+bitsXdev)) & maskXpos;
107 //_____________________________________________________________________________
109 AliMUONTriggerIO::FillLut(AliMUONTriggerLut& lut,
110 Int_t icirc, UChar_t istripX, UChar_t idev,
111 Int_t lutLpt[16][2], Int_t lutHpt[16][2])
113 /// Fill the LUT histograms
115 if (icirc == 0 && istripX == 0 && idev == 0)
117 AliDebug(1,"Copy board, not filled ...");
121 Short_t iLptPlus, iLptMinu, iLptUnde;
122 Short_t iHptPlus, iHptMinu, iHptUnde;
124 iLptPlus = iLptMinu = iLptUnde = 0;
125 iHptPlus = iHptMinu = iHptUnde = 0;
127 for (Int_t istripY=0; istripY<16; istripY++)
129 if (lutLpt[istripY][1] == 0 && lutLpt[istripY][0] ==1)
130 iLptMinu=iLptMinu+(1 << istripY);
131 if (lutLpt[istripY][1] == 1 && lutLpt[istripY][0] ==0)
132 iLptPlus=iLptPlus+(1 << istripY);
133 if (lutLpt[istripY][1] == 1 && lutLpt[istripY][0] ==1)
134 iLptUnde=iLptUnde+(1 << istripY);
136 if (lutHpt[istripY][1] == 0 && lutHpt[istripY][0] ==1)
137 iHptMinu=iHptMinu+(1 << istripY);
138 if (lutHpt[istripY][1] == 1 && lutHpt[istripY][0] ==0)
139 iHptPlus=iHptPlus+(1 << istripY);
140 if (lutHpt[istripY][1] == 1 && lutHpt[istripY][0] ==1)
141 iHptUnde=iHptUnde+(1 << istripY);
145 lut.SetContent("LptMinu",icirc,istripX,idev,iLptMinu);
146 lut.SetContent("LptUnde",icirc,istripX,idev,iLptUnde);
147 lut.SetContent("LptPlus",icirc,istripX,idev,iLptPlus);
149 lut.SetContent("HptMinu",icirc,istripX,idev,iLptMinu);
150 lut.SetContent("HptUnde",icirc,istripX,idev,iLptUnde);
151 lut.SetContent("HptPlus",icirc,istripX,idev,iLptPlus);
154 //_____________________________________________________________________________
156 AliMUONTriggerIO::LocalBoardId(Int_t index) const
158 /// Return the i-th localBoardId, or -1 if index is out of bounds
159 if ( index >= 0 && index < fLocalBoards.GetSize() )
161 AliMpLocalBoard* board = static_cast<AliMpLocalBoard*>(fLocalBoards.GetObject(index));
162 return board->GetId();
167 //_____________________________________________________________________________
169 AliMUONTriggerIO::ReadLocalMasks(const char* localFile, AliMUONVStore& localMasks) const
171 /// Fills the local masks store from file
173 if ( !NofLocalBoards() )
175 AliError("No local board to read");
179 FILE* fp = fopen(gSystem->ExpandPathName(localFile),"r");
182 AliError(Form("Could not read file %s",localFile));
186 UShort_t maskBuffer[8];
188 Int_t nLocalBoards(0);
190 while ( fread ( maskBuffer, 2, 8, fp ) )
192 Int_t localBoardId = LocalBoardId(nLocalBoards);
193 AliDebug(1,Form("LB %03d X1 %4x X2 %4x X3 %4x X4 %4x "
194 "Y1 %4x Y2 %4x Y3 %4x Y4 %4x",
207 AliMUONVCalibParam* localBoard = new AliMUONCalibParamNI(1,8,localBoardId,0,0);
208 for ( Int_t index = 0; index < 8; ++index )
210 localBoard->SetValueAsInt(index,0,maskBuffer[index]);
212 localMasks.Add(localBoard);
218 if ( nLocalBoards != NofLocalBoards() )
220 AliError(Form("Read %d out of %d local boards",
221 nLocalBoards, NofLocalBoards()));
229 //_____________________________________________________________________________
231 AliMUONTriggerIO::ReadLocalLUT(AliMUONTriggerLut& lut,
235 /// Read the LUT for one local board from an online file
240 UChar_t mask1 = 0xF0;
241 UChar_t mask2 = 0x0F;
242 UChar_t maskLpt = 0x0C;
243 UChar_t maskHpt = 0x03;
244 UChar_t lh, lpt, hpt;
246 UChar_t xpos, xdev, ypos, ytri;
248 Int_t lutLpt[16][2], lutHpt[16][2];
250 Int_t boardnr = localBoardId;
252 AliDebug(1,Form("Reading LUT values for local board %d",boardnr));
256 // create the 32767 addresses for the 4-bits lpt and hpt half-bytes
257 for (UShort_t ilut = 0; ilut < 0x7FFF; ilut += 2)
259 // read two lut addresses at once
260 fread(&buffer,1,1,flut);
262 // 1st 4-bits half-byte
264 lh = (buffer & mask1) >> 4;
266 // Lpt and Hpt response
267 lpt = (lh & maskLpt) >> 2;
270 // decompose the 15-bits address
271 DeCompAddress(ypos,ytri,xdev,xpos,address);
273 // calculate group of y-strips
276 lutLpt[ny][0] = lpt & 1;
277 lutLpt[ny][1] = (lpt & 2) >> 1;
278 lutHpt[ny][0] = hpt & 1;
279 lutHpt[ny][1] = (hpt & 2) >> 1;
284 // ytri == 1 means no trigger in y-direction
287 FillLut(lut,boardnr,xpos,xdev,lutLpt,lutHpt);
292 // 2nd 4-bits half-byte
294 lh = (buffer & mask2);
296 // Lpt and Hpt response
297 lpt = (lh & maskLpt) >> 2;
300 // decompose the 15-bits address
301 DeCompAddress(ypos,ytri,xdev,xpos,address);
303 // calculate group of y-strips
306 lutLpt[ny][0] = lpt & 1;
307 lutLpt[ny][1] = (lpt & 2) >> 1;
308 lutHpt[ny][0] = hpt & 1;
309 lutHpt[ny][1] = (hpt & 2) >> 1;
314 // ytri == 1 means no trigger in y-direction
317 FillLut(lut,boardnr,xpos,xdev,lutLpt,lutHpt);
324 //_____________________________________________________________________________
326 AliMUONTriggerIO::ReadLUT(const char* lutFileToRead, AliMUONTriggerLut& lut)
328 /// Fill the LUT object from online file
330 if ( !NofLocalBoards() )
332 AliError("No local board id defined. Must read a regional file first");
336 FILE* flut = fopen(gSystem->ExpandPathName(lutFileToRead),"rb");
339 AliError(Form("Could not read LUT file %s",lutFileToRead));
343 for ( Int_t i = 0; i < NofLocalBoards(); ++i )
345 ReadLocalLUT(lut,LocalBoardId(i),flut);
354 //_____________________________________________________________________________
356 AliMUONTriggerIO::ReadMasks(const char* localFile,
357 const char* regionalFile,
358 const char* globalFile,
359 AliMUONVStore* localMasks,
360 AliMUONVStore* regionalMasks,
361 AliMUONVCalibParam* globalMasks,
364 /// Fill the various masks store from files
368 AliError("Must have a regional file name to proceeed");
372 Int_t nCrates = ReadRegional(regionalFile,regionalMasks, warn);
374 if (!nCrates) return kFALSE;
376 if (localMasks && localFile)
378 Int_t nLocal = ReadLocalMasks(localFile,*localMasks);
379 AliDebug(1,Form("Read masks for %d local boards",nLocal));
382 Int_t nDarc = ReadGlobal(globalFile, globalMasks);
383 AliDebug(1,Form("Read disable for %d DARC boards",nDarc));
385 if (!nDarc) return kFALSE;
390 //_____________________________________________________________________________
392 AliMUONTriggerIO::ReadGlobal(const char* globalFile, AliMUONVCalibParam* globalMasks)
394 /// read the global crate file and file corresponding mask
395 /// the masks are disable bit for each crate, 8 per darc board
396 /// bit value 0 means enable, 1 means disable *
399 if (!AliMpDDLStore::ReadGlobalTrigger(fGlobalCrate, globalFile)) return 0;
401 UChar_t mask = fGlobalCrate.GetFirstDarcDisable();
402 ULong_t vmeAddr = fGlobalCrate.GetFirstDarcVmeAddr();
403 if (vmeAddr) nDarc++;
404 globalMasks->SetValueAsInt(0,0,mask);
406 mask = fGlobalCrate.GetSecondDarcDisable();
407 vmeAddr = fGlobalCrate.GetSecondDarcVmeAddr();
408 if (vmeAddr) nDarc++;
409 globalMasks->SetValueAsInt(1,0,mask);
414 //_____________________________________________________________________________
416 AliMUONTriggerIO::ReadRegional(const char* regionalFile, AliMUONVStore* regionalMasks, Bool_t warn)
418 /// Read regional file to fill the regional mask store *AND*
419 /// determine the order in which local boards will appear in local
422 if (!AliMpDDLStore::ReadRegionalTrigger(fTriggerCrates, fLocalBoards,
423 fDDLs, regionalFile, false)) return 0;
427 for (Int_t iCrate = 0; iCrate < fTriggerCrates.GetSize(); ++iCrate)
430 AliMpTriggerCrate* crate = static_cast<AliMpTriggerCrate*>(fTriggerCrates.GetObject(iCrate));
434 AliMpTriggerCrate* triggerCrate = AliMpDDLStore::Instance()->GetTriggerCrate(crate->GetName());
438 AliError(Form("Mapping error : could not get crate %s", crate->GetName()));
445 if (regionalMasks != 0x0)
447 masks = crate->GetMask();
449 AliMUONVCalibParam* regionalBoard = new AliMUONCalibParamNI(1, 1, crate->GetId(), 0, 0);
450 regionalBoard->SetValueAsInt(0, 0, masks);
451 regionalMasks->Add(regionalBoard);
458 //_____________________________________________________________________________
460 AliMUONTriggerIO::WriteLUT(const AliMUONTriggerLut& lut,
461 const char* lutFileToWrite)
463 /// Convert an offline lut into an online (binary) lut file
465 if ( !NofLocalBoards() )
467 AliError("No local board id defined. Must read a regional file first");
471 FILE* flut = fopen(gSystem->ExpandPathName(lutFileToWrite),"wb");
474 AliError(Form("Could not create output LUT file %s",lutFileToWrite));
478 for ( Int_t i = 0; i < NofLocalBoards(); ++i )
480 WriteLocalLUT(lut,LocalBoardId(i),flut);
488 //_____________________________________________________________________________
490 AliMUONTriggerIO::WriteMasks(const char* localFile,
491 const char* regionalFile,
492 const char* globalFile,
493 AliMUONVStore* localMasks,
494 AliMUONVStore* regionalMasks,
495 AliMUONVCalibParam* globalMasks) const
499 ok = WriteLocalMasks(localFile, *localMasks);
500 ok &= WriteRegional(regionalFile, regionalMasks);
501 ok &= WriteGlobal(globalFile, globalMasks);
506 //_____________________________________________________________________________
508 AliMUONTriggerIO::WriteGlobal(const char* globalFile, AliMUONVCalibParam* globalMasks) const
510 /// write global file
511 /// if no global masks defined take the one of configuration
516 out.open(globalFile);
519 AliError(Form("Could not create output regional file %s", globalFile));
523 out << fGlobalCrate.GetName() << endl;
526 out << fGlobalCrate.GetJtagName() << endl;
527 out << Form("0x%08x", fGlobalCrate.GetJtagVmeAddr()) << endl;
528 out << Form("%d %d %d", fGlobalCrate.GetJtagClockDiv(),
529 fGlobalCrate.GetJtagRxPhase(), fGlobalCrate.GetJtagRdDelay()) << endl;
531 for (Int_t i = 0; i < fGlobalCrate.GetJtagNofLines(); ++i)
532 out << Form("%d ", fGlobalCrate.GetEnableJtag(i));
536 for (Int_t i = 0; i < fGlobalCrate.GetJtagNofLines(); ++i)
539 for (Int_t j = 0; j < fGlobalCrate.GetJtagNofLines(); ++j)
540 out << Form(" %s", fGlobalCrate.GetJtagCrateName(i,j).Data()) << endl;
544 out << fGlobalCrate.GetFirstDarcName() << endl;
545 out << Form("0x%08x", fGlobalCrate.GetFirstDarcVmeAddr()) << endl;
546 out << fGlobalCrate.GetFirstDarcType() << endl;
547 if (globalMasks != 0x0)
548 disable = globalMasks->ValueAsInt(0);
550 disable = fGlobalCrate.GetFirstDarcDisable();
551 out << Form("0x%02x", disable) << endl;
552 out << Form("0x%x", fGlobalCrate.GetFirstDarcL0Delay()) << endl;
553 out << Form("0x%x", fGlobalCrate.GetFirstDarcL1TimeOut()) << endl;
556 out << fGlobalCrate.GetSecondDarcName() << endl;
557 out << Form("0x%08x", fGlobalCrate.GetSecondDarcVmeAddr()) << endl;
558 out << fGlobalCrate.GetSecondDarcType() << endl;
559 if (globalMasks != 0x0)
560 disable = globalMasks->ValueAsInt(1);
562 disable = fGlobalCrate.GetSecondDarcDisable();
563 out << Form("0x%02x", disable) << endl;
564 out << Form("0x%x", fGlobalCrate.GetSecondDarcL0Delay()) << endl;
565 out << Form("0x%x", fGlobalCrate.GetSecondDarcL1TimeOut()) << endl;
568 out << fGlobalCrate.GetGlobalName() << endl;
569 out << Form("0x%08x", fGlobalCrate.GetGlobalVmeAddr()) << endl;
570 for (Int_t i = 0; i < fGlobalCrate.GetGlobalNofRegisters(); ++i)
571 out << Form("0x%x", fGlobalCrate.GetGlobalRegister(i)) << endl;
574 out << fGlobalCrate.GetFetName() << endl;
575 out << Form("0x%08x", fGlobalCrate.GetFetVmeAddr()) << endl;
576 for (Int_t i = 0; i < fGlobalCrate.GetFetNofRegisters(); ++i)
577 out << Form("0x%x", fGlobalCrate.GetFetRegister(i)) << endl;
583 //_____________________________________________________________________________
585 AliMUONTriggerIO::WriteRegional(const char* regionalFile, AliMUONVStore* regionalMasks) const
588 /// write regional mask with the current configuration
589 /// if regional masks not defined, take the one from current configuration
592 out.open(regionalFile);
596 AliError(Form("Could not create output regional file %s",regionalFile));
600 for (Int_t iCrate = 0; iCrate < fTriggerCrates.GetSize(); ++iCrate)
602 AliMpTriggerCrate* crate = static_cast<AliMpTriggerCrate*>(fTriggerCrates.GetObject(iCrate));
604 out << crate->GetName() << endl;
605 out << Form("%02x", crate->GetId()) << endl;
606 out << crate->GetMode() << endl;
607 out << crate->GetCoinc() << endl;
610 if (regionalMasks != 0x0)
612 AliMUONVCalibParam* maskParam =
613 static_cast<AliMUONVCalibParam*>(regionalMasks->FindObject(crate->GetId()));
614 masks = maskParam->ValueAsInt(0,0);
618 masks = crate->GetMask();
621 out << Form("%04x", masks) << endl;
623 for (Int_t iLocal = 0; iLocal < crate->GetNofLocalBoards(); ++iLocal)
625 Int_t localBoardId = crate->GetLocalBoardId(iLocal);
627 AliMpLocalBoard* board = static_cast<AliMpLocalBoard*>(fLocalBoards.GetValue(localBoardId));
629 out << Form("%02d ", board->GetSlot())
631 << Form(" %03d ", localBoardId)
632 << Form("%03x", board->GetSwitch())
636 for (Int_t i = 0; i < board->GetNofDEs(); ++i)
637 out << Form("%4d ", board->GetDEId(i));
640 // print copy card numbers
641 out << Form(" %4d %4d", board->GetInputXfrom(), board->GetInputXto());
642 out << Form(" %4d %4d", board->GetInputYfrom(), board->GetInputYto());
643 out << Form(" %4d", board->GetTC()) << endl;
651 //_____________________________________________________________________________
653 AliMUONTriggerIO::WriteLocalMasks(const char* localFile, AliMUONVStore& localMasks) const
656 /// removing/adding enable for a local board need a update of the configuration
657 /// before calling this method
658 /// mask are written for all boards including the copy card (Ch.F.)
660 FILE* fp = fopen(gSystem->ExpandPathName(localFile),"wb");
663 AliError(Form("Could not create output local file %s",localFile));
667 UShort_t maskBuffer[8];
669 for (Int_t iCrate = 0; iCrate < fTriggerCrates.GetSize(); ++iCrate)
671 AliMpTriggerCrate* crate = static_cast<AliMpTriggerCrate*>(fTriggerCrates.GetObject(iCrate));
673 UShort_t mask = crate->GetMask(); // getting mask from current config
675 for (Int_t iLocal = 0; iLocal < crate->GetNofLocalBoards(); ++iLocal)
677 Int_t localBoardId = crate->GetLocalBoardId(iLocal);
679 if ( (mask >> iLocal ) & 0x1 )
681 AliMUONVCalibParam* localMask =
682 static_cast<AliMUONVCalibParam*>(localMasks.FindObject(localBoardId));
684 for (Int_t index = 0; index < 8; ++index)
686 maskBuffer[index] = localMask->ValueAsInt(index,0);
689 fwrite ( maskBuffer, 2, 8, fp);
701 //_____________________________________________________________________________
703 AliMUONTriggerIO::WriteLocalLUT(const AliMUONTriggerLut& lut,
707 /// loop over the address for the 4-bits lpt and hpt decisions
709 const Int_t kMaskYpos = 0x0F;
710 const Int_t kMaskYtri = 0x01;
711 const Int_t kMaskXdev = 0x1F;
712 const Int_t kMaskXpos = 0x1F;
714 for (Int_t i = 0; i < 32768; ++i)
716 Int_t lutLpt[2] = { 0 };
717 Int_t lutHpt[2] = { 0 };
720 Int_t iYpos = i & kMaskYpos;
721 Int_t iYtri = ( i >> 4 ) & kMaskYtri;
722 Int_t iXdev = ( i >> ( 4 + 1 ) ) & kMaskXdev;
723 Int_t iXpos = ( i >> ( 4 + 1 + 5 ) ) & kMaskXpos;
725 // iYtri == 1 means no trigger in y-direction
728 lut.GetLutOutput(localBoardId,iXpos,iXdev,iYpos,lutLpt,lutHpt);
738 buffer += lutLpt[1] << 7;
739 buffer += lutLpt[0] << 6;
740 buffer += lutHpt[1] << 5;
741 buffer += lutHpt[0] << 4;
744 buffer += lutLpt[1] << 3;
745 buffer += lutLpt[0] << 2;
746 buffer += lutHpt[1] << 1;
747 buffer += lutHpt[0] << 0;
748 fwrite(&buffer,1,1,flut);
753 //_____________________________________________________________________________
755 AliMUONTriggerIO::GetTriggerCrate(TString name, Bool_t warn) const
757 /// Return trigger crate with given name
759 AliMpTriggerCrate* crate
760 = (AliMpTriggerCrate*) fTriggerCrates.GetValue(name.Data());
762 if ( ! crate && warn ) {
764 << "Trigger crate with name = " << name.Data() << " not defined." << endl;
770 //_____________________________________________________________________________
772 AliMUONTriggerIO::GetLocalBoard(Int_t localBoardId, Bool_t warn) const
774 /// Return bus patch with given Id
776 AliMpLocalBoard* localBoard
777 = (AliMpLocalBoard*) fLocalBoards.GetValue(localBoardId);
779 if ( ! localBoard && warn ) {
781 << "Local board with Id = " << localBoardId << " not defined." << endl;
786 //______________________________________________________________________________
788 AliMUONTriggerIO::GetDDL(Int_t ddlId, Bool_t warn) const
790 /// Return DDL for given ddlId
793 = (AliMpDDL*)fDDLs.At(ddlId);
795 if ( ! ddl && warn ) {
797 << "DDL with Id = " << ddlId << " not defined." << endl;
803 //_____________________________________________________________________________
805 AliMUONTriggerIO::UpdateMapping(Bool_t writeFile) const
807 /// check if mapping in database different from current Mtg configuration
808 /// Update mapping in databse and read regional crate file in repository (ext .out
809 /// to avoid overwriting). This case has a low probability to happen.
811 // Assuming that crates do not change
813 if (!AliMpDDLStore::Instance(kFALSE))
815 AliMpCDB::LoadDDLStore();
818 Bool_t modified = false;
820 TExMapIter itr = AliMpDDLStore::Instance()->GetLocalBoardItr();
824 while(itr.Next(key, value))
826 AliMpLocalBoard* boardMapping = reinterpret_cast<AliMpLocalBoard*>(value);
828 Int_t localBoardId = boardMapping->GetId();
829 AliMpLocalBoard* board = static_cast<AliMpLocalBoard*>(fLocalBoards.GetValue(localBoardId));
831 if (board->GetCrate().CompareTo(boardMapping->GetCrate()) != 0)
833 AliWarning(Form("Crate Name different for board %d (%s %s)", localBoardId, boardMapping->GetCrate().Data(),
834 board->GetCrate().Data()));
835 boardMapping->SetCrate( board->GetCrate() );
839 if ((board->GetSlot()) != boardMapping->GetSlot())
841 AliWarning(Form("Slot different for board %d (%d %d)", localBoardId, boardMapping->GetSlot(), board->GetSlot()+1));
842 boardMapping->SetSlot(board->GetSlot());
846 if (boardMapping->GetSwitch() != board->GetSwitch()) {
847 AliWarning(Form("Switch different for board %d (0x%x 0x%x)", localBoardId,
848 boardMapping->GetSwitch(), board->GetSwitch()));
849 boardMapping->SetSwitch(board->GetSwitch());
856 AliMpCDB::WriteDDLStore(false);
857 AliWarning("Wrote new version of mapping in databse");
860 TString file = AliMpFiles::LocalTriggerBoardMapping();
862 WriteRegional(file.Data(), 0x0);
863 AliWarning(Form("Wrote regional file %s", file.Data()));