Evidence

What we tested, what we found

Passes and misses, side by side. Timing of QNX itself is not published, following the hackathon organisers' guidance on licence section 4.6(i), 28 Nov 2026; what we report is pass or fail, counts from our own tests, and the work done by our own code.

20/20

Host safety scenarios passed

0

Rule violations across all scenarios

99.3%

Chest compression fraction, shockable rhythm run

57

Real arrest ECG records evaluated

The same C code that runs on QNX, run faster than real time against the physics model. Each scenario prints PASS or FAIL and the suite exits with an error if any fails.

Pass

VF, shock, return

One shock, 0.80 s machine time, piston parked within one compression of trusted return of circulation.

Pass

Pre-authorised shock

Crew presses while charging. Human time 0, machine time 0.80 s.

Pass

Slow crew, 1.8 s

Shock still delivered inside the 3 s limit. Human time shown separately.

Pass

Crew never presses

Window closes at 3 s, charge kept and re-offered three times, then dumped. CCF stays above 90%.

Pass

30:2 mode

Two breaths in each gap, one shock, CCF 87%.

Pass

Refractory VF, 10 minutes

Four shocks, epinephrine prompts after the second, CCF above 99%.

Pass

Advisor dead or hung

Compressions continue on time and the shock is still delivered.

Pass

Malicious advisor

297 forged demands for a shock, a stop and 12 cm depth were all ignored.

Pass

True return, advisor denies

A pulse input parks the piston within one compression even while the advisor insists on VF.

Pass

Stiff chest

Force capped at 606 N. Depth reached only 3.9 cm, and the run reports that as a miss.

Pass

Sensor loss and e-stop

Controlled retract to full recoil, then safe hold.

Pass

Transport

Depth in range on 100% of strokes with compensation, 71% without, 100% with a 15% model error.

Pass

Controller stalls

The controller freezes for 40 ms every 0.7 s, then catches up, the way a busy virtual machine makes it. Transport depth stays in range on 98.5% of strokes and a stiff chest stays under 650 N.

1 / 1
Honest result. The trusted check got much better after tuning, but on real arrest ECG it still does not meet the American Heart Association performance goals. Until it does, the 0.8 s step should be read as a timed pause with a careful check, not a diagnosis.

57 records from two public PhysioNet databases. The check measures five things on 0.8 s of clean ECG, including how much of the signal sits in the 3 to 9 Hz fibrillation band. Its thresholds were tuned on CUDB only, with a rule fixed in advance (leave at least 95% of every non-shockable rhythm alone, then find as much VF as possible), and then scored once on VFDB, which the tuning never saw. Longer looks of 1.6 and 2.4 s were tested and did not help enough to justify the extra hands-off time.

Trusted check, held out (VFDB)
VF found75.0% goal above 90%
Normal sinus left alone97.7% goal above 99%
Other rhythms left alone98.0% meets goal
Asystole left alone90.0% goal above 95%
Before tuningVF 67.6%, sinus 90.3%, asystole 85.9%
On the tuning set (CUDB)VF 57.6%, sinus 95.3%, other 95.8%
Advisor, during compressions
VF found25 to 30% weak
Normal sinus left alone95 to 98%
Asystole left alone98.4%
Why it is safe anywayThe advisor only proposes. Its worst case is delaying one pre-charge.

The whole stack, compiled with qcc for QNX 8.0 x86_64, running on QNX 8.0 in QEMU with KVM on two virtual CPUs, on an ordinary laptop that was busy with other work at the same time. With the final code, three full runs in a row pass every case. The raw output of every run, the failed ones included, is in the repository under docs/results.

Emulator mode. A virtual machine on a busy host pauses for tens of milliseconds. These runs use the stack's explicit emulator mode: sensor timeout 50 ms and hardware watchdog 100 ms, instead of the 5 ms and 20 ms used on real hardware. Everything else, every limit and every rule, is the same code that will run on a board.
12/12

Fault cases passed on QNX 8.0, twice in a row

3ticks

Hands-off for the shock: the rhythm was read through the compressions

100%

Chest compression fraction, shockable rhythm run

7/7

Forbidden advisor actions refused by QNX

T1 Control loopThe 1 ms control loop is running pass
T2 Compressions16 in 10 s, 0 rule violations pass
T3 Advisor attack7 of 7 forbidden actions refused by QNX, also with the security policy enforced; kept as root under its type, the kernel still refuses every path to the piston and the shock line pass
T4 Advisor killedCompressions continued, advisor restarted each time pass
T5 CPU storm8 threads just below control priority for 10 s: compressions kept their rate (+18), 17 of 17 strokes 5 to 6 cm, 0 violations pass
T6 Stiff chestPeak force 604 N, hard limit 650 N, ceiling engaged 8 times pass
T7 TransportDepth in the 5 to 6 cm band on 100% of 90 strokes on a moving frame, peaks 51 to 54 mm pass
T8 Sensor dropoutSafe hold, cup at full recoil pass
T9 Safety process killedHardware watchdog lifted the cup to 0.0 mm, nothing restarted the safety process pass
T10 Shock and returnRhythm read as shockable through the compressions, one shock with 3 ticks hands-off (803 when the old design paused to look), 0 shocks off recoil, return of circulation detected, CCF 100% pass
T11 Malicious advisor250 forged demands ignored, shock still delivered, 0 rule violations pass
T12 Read through compressionsAsystole read as sure not shockable (score 0.12): the 2-minute check needed no pause at all, no shock pass

Reading the rhythm through the compressions

Every defibrillator stops compressions to read the heart, because compressions bury the ECG. Elvrek is the machine pushing, so it knows the phase of every stroke and subtracts its own artifact. On real arrest ECG from PhysioNet, at 0 dB, compared with always pausing to look: VF shocked at the check 82.1% against 75.0%, wrong shock advice for sinus 0.7% against 2.3%, and 70% of sinus checks with no pause at all. When the reading is not sure, the 0.8 s look runs as before. The thresholds were set on one database and scored on another, which we had to look at twice; the full method and that disclosure are in the repository (docs/ZERO-PAUSE.md).

One clock against two

Today a crew with mechanical CPR also runs a separate AED, and they are the link between two clocks: pause the device, wait for the analysis, wait for the charge, press, restart. We ran the same arrest both ways on the same code, physics and crew timings. With a 5 s AED analysis the pause before the shock was 0.3 s with Elvrek, which is the crew's own press, against 12.3 s for the device plus AED, and 5.3 s even when that crew charges during compressions. Over 10 minutes of VF that would not convert, total hands-off time was 1.2 s against 53.2 s and 25.2 s. The conventional workflow here is a model with stated assumptions, not a recording of a real AED, and the analysis time is swept from 3 to 10 s because devices differ widely.

Every requirement, traced and checked

Thirty safety requirements, from compression rate and depth to the shock gate, the AI fence, faults, timing and boot, each with its clinical or safety reason, the code that implements it, the host test checks that verify it in their own words, the QNX runs where it passed, and the result files. A script checks every link on each build and fails if one breaks, and the matrix is published in the repository as REQUIREMENTS.md. Writing it found two things no test checked, the upper limit of the compression rate and full recoil, so both checks were added. It also showed that full recoil cannot yet be judged in a moving vehicle, which is listed as a limit rather than claimed.

Compressing before the system has booted

The safety process and the hardware stand-in live in the QNX boot image and start from the first boot script, before the disks are mounted or the network is up. In five boots on QNX 8.0 in QEMU, the first full compression was done before any disk was mounted every time, and the piston kept working while the rest of the system came up. With the same programs started after the normal boot, like an ordinary application, it came only after the whole system had booted. Every boot ended compressing with no fault. We report the order of events, not boot times, which mostly measure QNX itself.

The crew console, on QNX Screen

The Elvrek crew console on QNX 8.0: charging while compressing, next rhythm check in 4 seconds

The crew sees one screen, drawn on the QNX target with QNX Screen: rate, depth and peak force, the countdown to the next rhythm check and what the reading through the compressions says, the charger, the EtCO2 trend and the compression fraction. It only reads the safety process's status, so it cannot move the piston or fire a shock, and if it hangs nothing else notices. In a recorded run the crew saw charging while compressing, then shock delivered: the shock window lasted 3 ms, too short for a screen drawn ten times a second to ever show a pause. Every frame saved from Screen on the target matched our host replay pixel for pixel, 11 of 11.

What the target taught us

The first runs on QNX did not all pass, and each failure led to a real improvement rather than a looser test:

  • One early run counted far fewer ticks than it should, and we first credited a call asking QNX for a 0.5 ms system tick. Testing that call on its own showed QNX 8.0 in QEMU keeps a fixed 1 ms tick and refuses the change, so the slow run was the virtual machine. The controller now reads the tick instead of assuming it.
  • A paused controller let a stiff chest reach 823 N. The motor driver now has its own force limit, so the hard limit holds even when software is late.
  • Road motion compensation moved from the controller into the driver, the way real motion systems split the work, so a late controller cannot make the depth wrong.
  • After a pause the controller replays the ticks it missed, using the buffered motion samples, so its clocks stay in step with real time.
  • A start up bug in the supervisor, and a test that watched the wall clock instead of the controller's clock, were fixed.
  • After a pause the controller replayed missed ticks with the newest sample, so the whole movement during the pause looked like it happened in 1 ms. The force guard tripped early and strokes came up short (43 to 50 mm). Speed is now measured over real hardware sample time, and two host scenarios that stall the controller guard against this coming back.
  • When the whole virtual machine froze, the controller could wake before the hardware had its turn and call the sensors silent. Silence is now counted only over time the controller was awake to see it. A real sensor loss is still caught within the timeout.
  • The stiff chest fault was injected in the middle of a push, which no controller can stop. It now takes effect at full recoil, the way a different patient would.
  • The CPU storm test used to compare missed ticks with and without the storm. On a virtual machine that number measures the host, not our code: one run missed more ticks with the storm, the next missed fewer. The test now judges what the patient gets during the storm: compressions on rate, every stroke 5 to 6 cm, no rule broken, no fault.
  • The test crew pressed once, from a status read a second old. It now behaves like a real crew and presses whenever the device asks.

At real hardware timings

We also ran the suite at the timings a real board will use: a 5 ms sensor timeout and a 20 ms hardware watchdog. Here QEMU runs inside WSL2, which is itself a virtual machine on Windows, and its virtual CPUs can freeze for longer than 5 ms. The first strict run passed 5 of 11 cases. Every failure was the controller correctly calling the sensors silent and retracting to safety. Two idle threads at the lowest priority keep the virtual CPUs awake without touching anything else, and with them 9 of 11 pass, including the full shock and return of circulation. Transport and the malicious advisor case still trip the 5 ms timeout. We think only real hardware can settle these numbers, and both runs are published in full.

  1. Cheskes S, et al. Perishock pause: an independent predictor of survival from out-of-hospital shockable cardiac arrest. Circulation. 2011;124:58-66.
  2. Panchal AR, et al. Part 3: Adult Basic and Advanced Life Support, 2020 American Heart Association Guidelines for CPR and ECC. Circulation. 2020;142(16 suppl 2):S366-S468.
  3. Kerber RE, et al. Automatic external defibrillators for public access defibrillation: recommendations for specifying and reporting arrhythmia analysis algorithm performance. Circulation. 1997;95:1677-1682.
  4. Nolle FM, et al. CREI-GARD, a new concept in computerized arrhythmia monitoring systems. Computers in Cardiology. 1986;13:515-518. (CUDB)
  5. Greenwald SD. Development and analysis of a ventricular fibrillation detector. MIT, 1986. (VFDB)
  6. Goldberger AL, et al. PhysioBank, PhysioToolkit, and PhysioNet. Circulation. 2000;101(23):e215-e220.

See a run, tick by tick

Play back a recording of the controller handling a shockable rhythm from compressions to return of circulation.