Skip to content
This repository has been archived by the owner on May 18, 2023. It is now read-only.

Commit

Permalink
changed trigger type in EB banks to long to match new RUN::config
Browse files Browse the repository at this point in the history
  • Loading branch information
raffaelladevita committed Dec 13, 2017
1 parent 665d1a3 commit 25217db
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ public static DataBank getEventBank(DetectorEvent detectorEvent, DataEvent event
DataBank bank = event.createBank(bank_name, 1);
bank.setInt("NRUN", 0, detectorEvent.getEventHeader().getRun());
bank.setInt("NEVENT", 0, detectorEvent.getEventHeader().getEvent());
bank.setInt("TRG", 0, detectorEvent.getEventHeader().getTrigger());
bank.setLong("TRG", 0, detectorEvent.getEventHeader().getTrigger());
bank.setFloat("STTime", 0, (float) detectorEvent.getEventHeader().getStartTime());
bank.setFloat("RFTime", 0, (float) detectorEvent.getEventHeader().getRfTime());
return bank;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ public class DetectorHeader {

private int run = 0;
private int event = 0;
private int trigger = 0;
private long trigger = 0;
private double rfTime = 0.0;
private double startTime = -1000.0;

Expand All @@ -31,7 +31,7 @@ public double getStartTime(){
return this.startTime;
}

public int getTrigger() {
public long getTrigger() {
return trigger;
}

Expand All @@ -51,7 +51,7 @@ public void setStartTime(double starttime){
this.startTime = starttime;
}

public void setTrigger(int trigger) {
public void setTrigger(long trigger) {
this.trigger = trigger;
}
}
4 changes: 2 additions & 2 deletions etc/bankdefs/hipo/EVENT.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
{"name":"TYPE", "id":4, "type":"int8", "info":"Event Type (Data or MC)"},
{"name":"EvCAT", "id":5, "type":"int16", "info":"Event Category, if >0: e-, e-p, e-pi+....."},
{"name":"NPGP", "id":6, "type":"int16", "info":"Number of Final (Timed-based) Reconstructed Particles*100 + Number of Geometrically Reconstructed Particles"},
{"name":"TRG", "id":7, "type":"int32", "info":"Trigger Type (CLAS12_e-, FT_CLAS12_h, CLAS12_H,...) + Prescale Factor for that Trigger"},
{"name":"TRG", "id":7, "type":"int64", "info":"Trigger Type (CLAS12_e-, FT_CLAS12_h, CLAS12_H,...) + Prescale Factor for that Trigger"},
{"name":"BCG", "id":8, "type":"float", "info":"Beam charge, gated (Coulomb)"},
{"name":"LT", "id":9, "type":"double", "info":"Lifetime"},
{"name":"STTime", "id":10, "type":"float", "info":"Event Start Time (ns)"},
Expand Down Expand Up @@ -191,7 +191,7 @@
{"name":"TYPE", "id":4, "type":"int8", "info":"Event Type (Data or MC)"},
{"name":"EvCAT", "id":5, "type":"int16", "info":"Event Category, if >0: e-, e-p, e-pi+....."},
{"name":"NPGP", "id":6, "type":"int16", "info":"Number of Final (Timed-based) Reconstructed Particles*100 + Number of Geometrically Reconstructed Particles"},
{"name":"TRG", "id":7, "type":"int32", "info":"Trigger Type (CLAS12_e-, FT_CLAS12_h, CLAS12_H,...) + Prescale Factor for that Trigger"},
{"name":"TRG", "id":7, "type":"int64", "info":"Trigger Type (CLAS12_e-, FT_CLAS12_h, CLAS12_H,...) + Prescale Factor for that Trigger"},
{"name":"BCG", "id":8, "type":"float", "info":"Faraday Cup Gated (Coulomb)"},
{"name":"LT", "id":9, "type":"double", "info":"Clock"},
{"name":"STTime", "id":10, "type":"float", "info":"Event Start Time (ns)"},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public static DetectorHeader readHeader(DataEvent event) {
DataBank bank = event.getBank("RUN::config");
dHeader.setRun(bank.getInt("run", 0));
dHeader.setEvent(bank.getInt("event", 0));
dHeader.setTrigger(bank.getInt("trigger", 0));
dHeader.setTrigger(bank.getLong("trigger", 0));
}
return dHeader;
}
Expand Down

0 comments on commit 25217db

Please sign in to comment.