Skip to content

Commit d042047

Browse files
committed
Times can no longer be unsigned
1 parent 33374de commit d042047

5 files changed

Lines changed: 22 additions & 20 deletions

File tree

sbnobj/SBND/CRT/CRTCluster.cxx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ namespace sbnd {
1616
, fComposition (kUndefinedSet)
1717
{}
1818

19-
CRTCluster::CRTCluster(uint32_t _ts0, uint32_t _ts1, uint32_t _unixS, uint16_t _nHits, CRTTagger _tagger,
19+
CRTCluster::CRTCluster(int64_t _ts0, int64_t _ts1, uint32_t _unixS, uint16_t _nHits, CRTTagger _tagger,
2020
CoordSet _composition)
2121
: fTs0 (_ts0)
2222
, fTs1 (_ts1)
@@ -28,8 +28,8 @@ namespace sbnd {
2828

2929
CRTCluster::~CRTCluster() {}
3030

31-
uint32_t CRTCluster::Ts0() const { return fTs0; }
32-
uint32_t CRTCluster::Ts1() const { return fTs1; }
31+
int64_t CRTCluster::Ts0() const { return fTs0; }
32+
int64_t CRTCluster::Ts1() const { return fTs1; }
3333
uint32_t CRTCluster::UnixS() const { return fUnixS; }
3434
uint16_t CRTCluster::NHits() const { return fNHits; }
3535
CRTTagger CRTCluster::Tagger() const { return fTagger; }

sbnobj/SBND/CRT/CRTCluster.hh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ namespace sbnd::crt {
1616

1717
class CRTCluster {
1818

19-
uint32_t fTs0; // T0 counter [ns]
20-
uint32_t fTs1; // T1 counter [ns]
19+
int64_t fTs0; // T0 counter [ns]
20+
int64_t fTs1; // T1 counter [ns]
2121
uint32_t fUnixS; // Unixtime of event [s]
2222
uint16_t fNHits; // The number of strip hits forming the cluster
2323
CRTTagger fTagger; // The tagger this cluster exists on
@@ -27,13 +27,13 @@ namespace sbnd::crt {
2727

2828
CRTCluster();
2929

30-
CRTCluster(uint32_t _ts0, uint32_t _ts1, uint32_t _unixS, uint16_t _nHits, CRTTagger _tagger,
30+
CRTCluster(int64_t _ts0, int64_t _ts1, uint32_t _unixS, uint16_t _nHits, CRTTagger _tagger,
3131
CoordSet _composition);
3232

3333
virtual ~CRTCluster();
3434

35-
uint32_t Ts0() const;
36-
uint32_t Ts1() const;
35+
int64_t Ts0() const;
36+
int64_t Ts1() const;
3737
uint32_t UnixS() const;
3838
uint16_t NHits() const;
3939
CRTTagger Tagger() const;

sbnobj/SBND/CRT/CRTStripHit.cxx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ namespace sbnd {
2020
, fSaturated2 (false)
2121
{}
2222

23-
CRTStripHit::CRTStripHit(uint32_t _channel, uint32_t _ts0, uint32_t _ts1, uint32_t _s, double _pos,
23+
CRTStripHit::CRTStripHit(uint32_t _channel, int64_t _ts0, int64_t _ts1, uint32_t _s, double _pos,
2424
double _err, uint16_t _adc1, uint16_t _adc2)
2525
: fChannel (_channel)
2626
, fTs0 (_ts0)
@@ -35,7 +35,7 @@ namespace sbnd {
3535
fSaturated2 = fADC2 == 4095;
3636
}
3737

38-
CRTStripHit::CRTStripHit(uint32_t _channel, uint32_t _ts0, uint32_t _ts1, uint32_t _s, double _pos,
38+
CRTStripHit::CRTStripHit(uint32_t _channel, int64_t _ts0, int64_t _ts1, uint32_t _s, double _pos,
3939
double _err, uint16_t _adc1, uint16_t _adc2, bool _saturated1, bool _saturated2)
4040
: fChannel (_channel)
4141
, fTs0 (_ts0)
@@ -52,8 +52,8 @@ namespace sbnd {
5252
CRTStripHit::~CRTStripHit() {}
5353

5454
uint32_t CRTStripHit::Channel() const { return fChannel; }
55-
uint32_t CRTStripHit::Ts0() const { return fTs0; }
56-
uint32_t CRTStripHit::Ts1() const { return fTs1; }
55+
int64_t CRTStripHit::Ts0() const { return fTs0; }
56+
int64_t CRTStripHit::Ts1() const { return fTs1; }
5757
uint32_t CRTStripHit::UnixS() const { return fUnixS; }
5858
double CRTStripHit::Pos() const { return fPos; }
5959
double CRTStripHit::Error() const { return fErr; }

sbnobj/SBND/CRT/CRTStripHit.hh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ namespace sbnd::crt {
1717
class CRTStripHit {
1818

1919
uint32_t fChannel; // Channel ID for 1st SiPM
20-
uint32_t fTs0; // T0 counter [ns] - Time relative to pulse-per-second
21-
uint32_t fTs1; // T1 counter [ns] - Time relative to some beam signal
20+
int64_t fTs0; // T0 counter [ns] - Time relative to pulse-per-second
21+
int64_t fTs1; // T1 counter [ns] - Time relative to some beam signal
2222
uint32_t fUnixS; // Unixtime of event [s]
2323
double fPos; // Lateral position within strip [cm]
2424
double fErr; // Error on lateral position [cm]
@@ -31,17 +31,17 @@ namespace sbnd::crt {
3131

3232
CRTStripHit();
3333

34-
CRTStripHit(uint32_t _channel, uint32_t _ts0, uint32_t _ts1, uint32_t _s, double _pos,
34+
CRTStripHit(uint32_t _channel, int64_t _ts0, int64_t _ts1, uint32_t _s, double _pos,
3535
double _err, uint16_t _adc1, uint16_t _adc2);
3636

37-
CRTStripHit(uint32_t _channel, uint32_t _ts0, uint32_t _ts1, uint32_t _s, double _pos,
37+
CRTStripHit(uint32_t _channel, int64_t _ts0, int64_t _ts1, uint32_t _s, double _pos,
3838
double _err, uint16_t _adc1, uint16_t _adc2, bool _saturated1, bool _saturated2);
3939

4040
virtual ~CRTStripHit();
4141

4242
uint32_t Channel() const;
43-
uint32_t Ts0() const;
44-
uint32_t Ts1() const;
43+
int64_t Ts0() const;
44+
int64_t Ts1() const;
4545
uint32_t UnixS() const;
4646
double Pos() const;
4747
double Error() const;

sbnobj/SBND/CRT/classes_def.xml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,8 @@
6868

6969
<!-- CRTStripHit -->
7070

71-
<class name="sbnd::crt::CRTStripHit" ClassVersion="10">
71+
<class name="sbnd::crt::CRTStripHit" ClassVersion="11">
72+
<version ClassVersion="11" checksum="1377866194"/>
7273
<version ClassVersion="10" checksum="584045954"/>
7374
</class>
7475
<class name="std::vector<sbnd::crt::CRTStripHit>"/>
@@ -84,7 +85,8 @@
8485

8586
<!-- CRTCluster -->
8687

87-
<class name="sbnd::crt::CRTCluster" ClassVersion="10">
88+
<class name="sbnd::crt::CRTCluster" ClassVersion="11">
89+
<version ClassVersion="11" checksum="2461267624"/>
8890
<version ClassVersion="10" checksum="1135665496"/>
8991
</class>
9092
<class name="std::vector<sbnd::crt::CRTCluster>"/>

0 commit comments

Comments
 (0)