Skip to content

Add Flight Test Telemetry example plugin (PCM, MIL-STD-1553, TSPI, faults, IRIG 106 Ch10 adapter) - #16

Closed
erikrozi wants to merge 2 commits into
masterfrom
devin/1788814796-flight-test-telemetry-plugin
Closed

erikrozi wants to merge 2 commits into
masterfrom
devin/1788814796-flight-test-telemetry-plugin

Conversation

@erikrozi

@erikrozi erikrozi commented Sep 7, 2026

Copy link
Copy Markdown

Describe your changes:

Adds an opt-in example plugin, openmct.plugins.example.FlightTest, under example/flightTest/ for aircraft flight-test / mission-systems integration telemetry — the kind of ground-station display used during a test event. It follows the example/generator, example/eventGenerator and example/faultManagement conventions and the structure of #14.

Enable it (not installed by default in index.html, so the e2e tree baseline is unchanged):

openmct.install(openmct.plugins.example.FlightTest());
// to see exceedances as faults, also:
openmct.install(openmct.plugins.FaultManagement());

Object tree

Flight Test Telemetry
└── Test Article TA-01
    ├── PCM Parameters           pressure altitude, IAS, AOA, pitch/roll/yaw, Nz, N1, N2, EGT, fuel flow, fuel quantity
    ├── MIL-STD-1553 Bus Health  Bus A / Bus B message rate, word errors, no-response count, status (NOMINAL/DEGRADED/FAILED)
    ├── TSPI                     latitude, longitude, geometric altitude, ground speed
    └── Test Card Events         event stream ("TP-04 wind-up turn 4g start", "TP-04 complete", "Bus B failover", ...)

Modules

Module Purpose
plugin.js Registers the two types, the root, object/telemetry/limit providers and the fault source; starts/stops fault monitoring on start/destroy
flightProfile.js Deterministic keyframed 24-minute sortie aligned to the Unix epoch (takeoff, climb, level cruise, TP-04 wind-up turn, recovery, descent, approach). sampleFlight(utc) returns every parameter for a timestamp; eventsBetween(start, end) returns test-card events. Bus B degrades → fails → fails over → restores during recovery
parameters.js Parameter catalog: keys, names, units, enumerations, limits and Open MCT telemetry metadata (utc domain, value range, phase)
FlightTestObjectProvider.js Static domain-object tree for the flight-test namespace
FlightTestTelemetryProvider.js Historical request() — honors options.size, strategy: 'latest', caps at 50,000 datums, never returns future values, chronological — and realtime subscribe() on a fixed 1 s interval reading the same profile; event stream request/subscribe
FlightTestLimitProvider.js Limit evaluator (yellow/red table highlighting) and limit lines (plots) for Nz, AOA, EGT and 1553 word errors
FlightTestFaultProvider.js Exceedance monitor publishing to openmct.faults: CRITICAL faults for critical telemetry exceedances and FAILED buses, WARNING for DEGRADED buses; faults latch until acknowledged, support shelving with timed/indefinite durations
Chapter10Adapter.js IRIG 106 Chapter 10 packet-header parser (sync 0xEB25, channel ID, packet/data length, data type version, sequence, flags, data type, 48-bit RTC, header checksum) + MIL-STD-1553 Format 1 (0x19) intra-packet header parser (bus ID, error flags, gap times, word count/message length) with a channel → telemetry-key map. Not a full PCM/1553 decoder
README.md Enable instruction, tree, sortie profile, limits, adapter usage
src/plugins/plugins.js Registers plugins.example.FlightTest
.cspell.json Adds ARINC, IRIG, TMATS, TSPI, exceedance(s), keyframed, measurand, ...

Limits

Parameter Warning Critical
Normal load factor (Nz) ≥ 5.5 g ≥ 6.5 g
Angle of attack ≥ 20° ≥ 25°
EGT ≥ 900 °C ≥ 950 °C
1553 word errors ≥ 5/s ≥ 20/s

Every sortie the wind-up turn (minutes 12–14) drives Nz and AOA through both thresholds, and Bus B word errors pass both thresholds during recovery (minutes 14–17). EGT peaks in the warning band by design.

Chapter 10 adapter accepts ArrayBuffer, DataView or typed arrays, validates every read against the buffer and the declared packet/data lengths, and rejects bad sync, non-multiple-of-4 packet lengths, truncated buffers, checksum mismatches and inconsistent message lengths with a Chapter10Error carrying the byte offset. Header layout follows IRIG 106 Chapter 10 §10.6.1 (packet header) and §10.6.4 (MIL-STD-1553 Format 1); the public references are cited in the module header comment.

Note on mixed tables: all parameters share the value range key (as real telemetry adapters do), so a telemetry table mixing several parameters shows a single value column whose header takes the name of the last object added (this is existing TelemetryTableConfiguration.getAllHeaders behavior). Per-row names, units and highlighting are correct.

Tests

npm run lint (js, vue, spelling) is clean. Six new Karma spec files, 96 specs:

Spec Specs
flightProfileSpec.js 12
FlightTestTelemetryProviderSpec.js 22
FlightTestLimitProviderSpec.js 10
FlightTestFaultProviderSpec.js 17
Chapter10AdapterSpec.js 29
pluginSpec.js 7

npm test vs. a detached master baseline run on the same machine (Node 24.14.1, Chrome Headless 133):

Run Executed Success Failed Skipped
master baseline 975 of 1042 969 6 67
this branch (initial) 1067 of 1134 1061 6 67
this branch (after review fixes, dist/ present) 1071 of 1138 1071 0 67

The six failures on the first two runs are the identical set (pre-existing, unrelated to this change): The Object API Search Function ×4 (in-memory search worker 404: /base/dist/inMemorySearchWorker.js), The Image Exporter ... can render an element to a blob, The URLIndicator ... has a default icon class if none supplied. They disappear once a dist/ build exists on the machine, which is why the re-run after the review fixes is fully green. +96 executed / +96 success, 0 new failures.

Browser verification

Verified with npm start after temporarily adding the two openmct.install lines above to index.html (not committed). Full-size screenshots and the screen recording are in the PR comment below.

Tree tree
Streaming PCM plot (realtime) stream
30-minute historical sortie profile sortie
Nz plot with warning/critical limit lines limit lines
Table highlighting during the wind-up turn table
Bus B word-error highlighting during recovery bus table
Fault Management: 4 latched critical faults faults
After acknowledging Nz / shelving AOA shelved

Original prompt

Add a flight-test telemetry example plugin to Open MCT: a "Flight Test Telemetry" root with a test article exposing PCM parameters (altitude, airspeed, AOA, attitude, Nz, engine N1/N2/EGT, fuel), MIL-STD-1553 Bus A/B health, TSPI, and a test-card event stream; simulated maneuvers with deterministic history and realtime streaming; warning/critical exceedance limits that highlight in tables/plots and raise faults in Fault Management; plus an IRIG 106 Chapter 10 packet-header + 1553 Format 1 adapter with unit tests. Follow the example/generator conventions, add karma specs, keep lint and the test suite green, and verify it renders in the browser.

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Is this a notable change that will require a special callout in the release notes? For example, will this break compatibility with existing APIs or projects that consume these plugins? — No; opt-in example plugin, no default install, no API changes.

Author Checklist

  • Changes address original issue?
  • Tests included and/or updated with changes?
  • Has this been smoke tested?
  • Have you associated this PR with a type: label? Note: this is not necessarily the same as the original issue.
  • Have you associated a milestone with this PR? Note: leave blank if unsure.
  • Testing instructions included in associated issue OR is this a dependency/testcase change? — see "Enable it" and "Browser verification" above.

Reviewer Checklist

  • Changes appear to address issue?
  • Reviewer has tested changes by following the provided instructions?
  • Changes appear not to be breaking changes?
  • Appropriate automated tests included?
  • Code style and in-line documentation are appropriate?

Link to Devin session: https://app.devin.ai/sessions/58e880f15fa6477b8f09391369d3f0b0
Open in Devin Desktop: https://app.devin.ai/desktop/session/58e880f15fa6477b8f09391369d3f0b0?variant=devin
Requested by: @erikrozi


Devin Review

Adds example/flightTest, an opt-in example plugin for aircraft flight-test /
mission-systems integration telemetry:

- Flight Test Telemetry root with Test Article TA-01 exposing PCM parameters,
  MIL-STD-1553 Bus A/B health, TSPI and a test-card event stream
- Deterministic simulated sortie (climb, cruise, wind-up turn, recovery,
  descent) backing both historical requests and realtime subscriptions
- Warning/critical limit provider for Nz, AOA, EGT and 1553 word errors
- Fault Management provider raising faults for critical exceedances and
  degraded/failed buses, with acknowledge and shelve support
- IRIG 106 Chapter 10 packet header and MIL-STD-1553 Format 1 adapter
- Karma specs for the profile, providers, limits, faults and the adapter

Registered as openmct.plugins.example.FlightTest; not installed by default.

Co-Authored-By: Erik Rozi <erik.rozi@cognition.ai>
@devin-ai-integration

Copy link
Copy Markdown

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR that start with 'DevinAI' or '@devin'.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment, CI, and merge conflict monitoring

Original prompt from Devin Bot

Repository: COG-GTM/openmct (fork of NASA Open MCT, branch master). Clone it, read README.md, CONTRIBUTING.md, TESTING.md, AGENTS.md if present, and study the existing example plugins in example/ (especially example/generator, example/eventGenerator, example/faultManagement) and src/plugins/faultManagement. Also read open PR #14 (#14) — it is the closest precedent for the structure, testing, and PR-description conventions you should follow.

#``# Task

Add a production-quality example plugin to Open MCT for aircraft flight-test telemetry monitoring, the kind of ground-station display a Navy/DoD flight-test or mission-systems integration lab would use during a test event. Register it as openmct.plugins.example.FlightTest under example/flightTest/.

Scope (implement all of it):

  1. Domain model / object tree. A root object "Flight Test Telemetry" containing one test aircraft node (call it "Test Article TA-01", fictional; do not name a real aircraft program) with folders:
    • PCM Parameters — pressure altitude (ft), indicated airspeed (kt), angle of attack (deg), pitch/roll/yaw (deg), normal load factor Nz (g), engine N1 (%), N2 (%), EGT (°C), fuel flow (pph), fuel quantity (lb).
    • MIL-STD-1553 Bus Health — per-bus (Bus A / Bus B) message rate (msg/s), word-error count, no-response count, bus status (enumerated: NOMINAL / DEGRADED / FAILED).
    • TSPI — latitude, longitude, altitude, ground speed (time-space-position information).
    • Test Card Events — an event stream of test-point marks (e.g. "TP-04 wind-up turn 4g start", "TP-04 complete", "Bus B failover") like example/eventGenerator.
  2. Realistic simulated data. Deterministic simulated maneuvers (climb, level cruise, wind-up turn that drives Nz and AOA up, descent) so plots look like a real test flight, with a deterministic historical request() (honor options.size, strategy: 'latest', cap total datums) and a realtime subscribe() ... (4187 chars truncated...)

@devin-ai-integration devin-ai-integration Bot added no milestone PR intentionally has no milestone type:maintenance Maintenance/CI change labels Sep 7, 2026
@devin-ai-integration

Copy link
Copy Markdown

Manual browser verification (npm start, Node 24.14.1, Chrome 133)

Plugin enabled for the test by temporarily adding openmct.install(openmct.plugins.FaultManagement()) and openmct.install(openmct.plugins.example.FlightTest()) to index.html (not committed).

Recording (2x speed, full run: tree → realtime plot → historical sortie → limit lines → table highlighting → Fault Management acknowledge/shelve):

flight-test-recording

Tree

Flight Test Telemetry → Test Article TA-01 → PCM Parameters (12), MIL-STD-1553 Bus Health (8), TSPI (4), Test Card Events.

tree-pcm
tree-bus-tspi-events

PCM plots stream

Pressure Altitude in realtime mode (30-minute rolling window), two captures a few seconds apart — the latest value/timestamp and the trace advance at 1 Hz.

stream-before
stream-after

30-minute fixed window showing the sortie profile (descent/landing of the previous sortie, takeoff, climb to 25,000 ft, level cruise, wind-up-turn altitude sag, descent).

historical-sortie

Limits

Nz in an Overlay Plot with limit lines: yellow warning at 5.5 g, red critical at 6.5 g; alarm markers on the exceedance points.

nz-limit-lines

Telemetry Table (Nz, AOA, EGT, Bus B Word Errors) over the TP-04 wind-up turn: yellow warning and red critical rows for Nz and AOA, yellow EGT warning rows.

table-windup-limits

Same table over the recovery window: Bus B word errors climbing through warning (yellow, ≥ 5/s) into critical (red, ≥ 20/s).

table-bus-limits

Fault Management

Four faults raised from live telemetry during one sortie — Nz 6.592 g and AOA 25.34° (critical exceedances), Bus B Word Errors 20 err/s and Bus B Status FAILED — all CRITICAL, latched with trip value, live value and trigger time.

faults-before

After acknowledging Nz (recovered fault clears, 4 → 3 results) and shelving AOA (Shelved filter):

faults-acknowledged
faults-shelved

Console: no errors (only pre-existing Vue defineExpose and WebGL/software-rendering warnings from the headless VM).

devin-ai-integration[bot]

This comment was marked as resolved.

…cleanup

- Chapter10Adapter.parsePacket rejects header checksum mismatches and
  packets whose declared Packet Length runs past the buffer, so truncated
  or corrupted packets are never partially decoded
- FlightTestTelemetryProvider keeps every returned sample on the one-second
  grid inside [start, end] for both ordinary and latest requests, returning
  nothing when the window contains no sample boundary
- FlightTestFaultProvider cancels pending shelve timers when a fault is
  removed so no notification is published for an unlisted fault
- Specs cover each case

Co-Authored-By: Erik Rozi <erik.rozi@cognition.ai>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no milestone PR intentionally has no milestone type:maintenance Maintenance/CI change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant