source: branches/start/MagicSoft/Mars/mraw/MRawCrateData.cc@ 9492

Last change on this file since 9492 was 454, checked in by harald, 24 years ago
Import the first sources of the MAGIC Analysis and Reconstruction Software. T. Bretz and H. Kornmayer 20.December 2000
File size: 806 bytes
Line 
1#include "MRawCrateData.h"
2
3#include <iostream.h>
4#include <iomanip.h>
5
6#include <fstream.h>
7
8ClassImp(MRawCrateData)
9
10MRawCrateData::MRawCrateData() : fDAQCrateNumber(0), fFADCEvtNumber(0), fFADCClockTick(0)
11{
12}
13
14void MRawCrateData::ReadEvt(ifstream& fin)
15{
16 //
17 // read the information from a binary input stream about the CRATE DATA,
18 // like specified in a TDAS note
19 //
20 fin.read((Byte_t*)&fDAQCrateNumber, 2);
21 fin.read((Byte_t*)&fFADCEvtNumber, 4);
22 fin.read((Byte_t*)&fFADCClockTick, 4);
23}
24
25void MRawCrateData::Print(Option_t *t)
26{
27 //
28 // print all stored information to screen
29 //
30 cout << "Crate Number " << fDAQCrateNumber << ": ";
31 cout << "FADCEventNr=" << fFADCEvtNumber << " ";
32 cout << "FADCClockTick=" << fFADCClockTick << " (20MHz)" << endl;
33}
Note: See TracBrowser for help on using the repository browser.