Skip to content
This repository has been archived by the owner on Sep 1, 2024. It is now read-only.

Commit

Permalink
Inspector update to protect wrong CLCW processing (causing uncaught e…
Browse files Browse the repository at this point in the history
…xception)
  • Loading branch information
dariol83 committed Jan 24, 2023
1 parent cd031bb commit 8196f7e
Showing 1 changed file with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,14 @@ public static String dumpTransferFrame(TmTransferFrame t) {
if(t.isOcfPresent()) {
sb.append("\nCLCW ---------------------------------------------------------------\n");
// Assume CLCW
Clcw clcw = new Clcw(t.getOcfCopy());
sb.append(String.format("Version: %2d Status Field: %3d VCID: %2d COP in Effect: %-10s\n", clcw.getVersionNumber(), clcw.getStatusField(), clcw.getVirtualChannelId(), clcw.getCopInEffect().name()));
sb.append(String.format("No RF: %2d No Bitlock: %3d Lockout: %2d Retransmit: %2d\n", clcw.isNoRfAvailableFlag() ? 1 : 0, clcw.isNoBitlockFlag() ? 1 : 0, clcw.isLockoutFlag() ? 1 : 0, clcw.isRetransmitFlag() ? 1 : 0));
sb.append(String.format("FARM-B: %2d Report: %3d\n", clcw.getFarmBCounter(), clcw.getReportValue()));
try {
Clcw clcw = new Clcw(t.getOcfCopy());
sb.append(String.format("Version: %2d Status Field: %3d VCID: %2d COP in Effect: %-10s\n", clcw.getVersionNumber(), clcw.getStatusField(), clcw.getVirtualChannelId(), clcw.getCopInEffect().name()));
sb.append(String.format("No RF: %2d No Bitlock: %3d Lockout: %2d Retransmit: %2d\n", clcw.isNoRfAvailableFlag() ? 1 : 0, clcw.isNoBitlockFlag() ? 1 : 0, clcw.isLockoutFlag() ? 1 : 0, clcw.isRetransmitFlag() ? 1 : 0));
sb.append(String.format("FARM-B: %2d Report: %3d\n", clcw.getFarmBCounter(), clcw.getReportValue()));
} catch (IllegalArgumentException e) {
sb.append("Invalid CLCW field\n");
}
}

if(t.isFecfPresent()) {
Expand Down

0 comments on commit 8196f7e

Please sign in to comment.