Blyx

Heron

Telemetry monitoring framework · 0.1.0

Track one sensor feed’s accepted messages, duplicate sequence numbers, out-of-order arrivals and missed deadlines.

Audit a sensor heartbeat trace

Replay sequence and local receipt-time pairs. The bundled trace contains a duplicate, a two-ID gap and one out-of-order delivery. You can feed your own two-column headerless trace into the same program.

Download the standalone example

Extract the archive and run heron-demo.exe on Windows or ./heron-demo on Linux and macOS. Each archive includes the Blyx source and tests.

Build from source

With Blyx 0.2.1, Rust and a host linker installed, run these commands to edit and rebuild the example.

git clone --depth 1 --branch v0.1.0 https://github.com/Rahulchaube1/blyx-heron.git
cd blyx-heron
blyxc native-run project.blyx

Why this framework exists

A replayed packet can make an idle sensor appear healthy if every arrival resets its last-seen timer. ROS 2 distinguishes delivery and deadline policies. Heron lets an application choose a freshness deadline and updates that timer only when it accepts a new sample. ROS 2, Quality of service settings

Install Heron in your editor

Extension RahulChaube.blyx-heron · 0.1.0

The extension includes a runnable Blyx example, function completions and the framework source. For the modular project, extract the starter, open its folder and run blyxc native-run main.blyx with the native toolchain installed.

Create an empty .blyx file, type blyx-heron-demo and accept the completion. Choose Blyx: Run File to run the example.

For an offline installation, choose Extensions: Install from VSIX for Blyx Language first, then for Heron.

Download the companion Blyx Language VSIX

Install with Conda

Create an environment containing Heron 0.1.0, its Blyx source and a runnable example. Run the second command with Blyx 0.2.1, Rust and a host linker installed.

conda create -y --prefix ./blyx-env --override-channels -c https://rahulchaube1.github.io/blyx-packages blyx-heron=0.1.0=0
blyxc native-run ./blyx-env/share/blyx/heron/main.blyx

To use this package in your application, copy share/blyx/heron/vendor/heron from the environment into your project's vendor directory.

Install the full collection with Homebrew or Scoop

Import into a Blyx project

Install Blyx 0.2.1, Rust 1.85 or newer and a host linker. From the directory containing your entry file, clone this tagged release.

git clone --depth 1 --branch v0.1.0 https://github.com/Rahulchaube1/blyx-heron.git vendor/heron

Save this as main.blyx beside vendor and run blyxc native-run main.blyx.

use vendor::heron::heron;

fn main() {
    let first = he_observe(he_start(), 10.0, 100.0);
    let next = he_observe(first, 13.0, 120.0);
    let repeated = he_observe(next, 13.0, 145.0);
    println!(at(repeated, 5));
    println!(at(repeated, 3));
    println!(he_status(repeated, 151.0, 30.0));
}

Expected output

2
1
late

API and input requirements

Maintain one state per sensor. Use a monotonically increasing integer sequence and a monotonic local receipt clock in milliseconds, both at most 2^53−1. Reset the state when the sensor restarts or its sequence wraps. The gap counter records skipped IDs at acceptance time. Late arrivals do not reduce it. This release monitors application data and exposes its state to the host.

APIUse
he_start(), he_observe(state, sequence, receipt_ms)Initialize or update [last sequence, last receipt, accepted, duplicates, out of order, skipped IDs].
he_age(state, now)Return milliseconds since the latest accepted observation, or −1 when unavailable.
he_status(state, now, deadline)Return unseen, current, late or invalid. A reading remains current exactly at its deadline.

Develop and contribute

Open the tagged source to read the implementation and examples. Include the smallest reproducible Blyx program, compiler version and expected result when reporting an issue.