Skip to content

Commit 94eab3c

Browse files
committed
added CRORC orbitSor
1 parent 5104f2d commit 94eab3c

File tree

6 files changed

+14
-0
lines changed

6 files changed

+14
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -562,6 +562,7 @@ metric format for the CRORC and the CRU is different, as different parameters ar
562562
| `"pciAddress"` | - | string |
563563
| `"status"` | 0/1 (DOWN/UP) | int |
564564
| `"opticalPower"` | - | double |
565+
| `"orbitSor"` | - | int |
565566
566567
| Tag key | Value |
567568
| --------------------- | --------------------- |

doc/releaseNotes.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,3 +48,7 @@ This file describes the main feature changes for released versions of ReadoutCar
4848
- Added some counters for roc-status:
4949
- link (with --monitoring option only): pktProcessed, pktErrorProtocol, pktErrorCheck1, pktErrorCheck2, pktErrorOversize, orbitSor (including for UL link 15)
5050
- onu (with --onu option, all output modes, including --monitoring): glitchCounter
51+
52+
## v0.44.0 - 02/06/2023
53+
- Added some counters for roc-status:
54+
- link (with --monitoring option only): orbitSOR for CRORC

src/CommandLineUtilities/ProgramStatus.cxx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,7 @@ class ProgramStatus : public Program
162162
.addValue(card.pciAddress.toString(), "pciAddress")
163163
.addValue(link.status, "status")
164164
.addValue(opticalPower, "opticalPower")
165+
.addValue((uint64_t)link.orbitSor, "orbitSor")
165166
.addTag(tags::Key::SerialId, card.serialId.getSerial())
166167
.addTag(tags::Key::CRORC, card.sequenceId)
167168
.addTag(tags::Key::ID, id)

src/Crorc/Common.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ enum LinkStatus {
3232
struct Link {
3333
LinkStatus status = LinkStatus::Down;
3434
float opticalPower = 0.0;
35+
uint32_t orbitSor = 0;
3536
};
3637

3738
struct ReportInfo {

src/Crorc/Constants.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -429,6 +429,7 @@ static constexpr Register SERIAL_NUMBER(0x000000FC);
429429

430430
static constexpr Register ACQ_RATE(0x00000050);
431431
static constexpr Register PKTS_RECEIVED(0x00000054);
432+
static constexpr Register ORBIT_SOR(0x00000060);
432433

433434
} // namespace Registers
434435
} //namespace Crorc

src/Crorc/CrorcBar.cxx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,12 @@ Crorc::ReportInfo CrorcBar::report(bool forConfig)
146146
}
147147

148148
getOpticalPowers(linkMap);
149+
150+
for (auto& el : linkMap) {
151+
auto& link = el.second;
152+
link.orbitSor = readRegister(Crorc::Registers::ORBIT_SOR.index);
153+
}
154+
149155
Crorc::ReportInfo reportInfo = {
150156
linkMap,
151157
getCrorcId(),

0 commit comments

Comments
 (0)