Medical Devices

Reproducibility and Post-Incident Analysis in Implantable Cardiac Devices

How execution traceability can influence investigation, liability, and regulatory outcomes

Published
December 23, 2025
Reading Time
9 min
Medical device litigation timeline - conventional vs deterministic

Note: The following scenario is illustrative and representative of patterns observed in publicly reported medical device litigation. It does not refer to any specific case or manufacturer.

In a representative scenario, a patient dies several days after pacemaker implantation. The autopsy indicates cardiac arrest. The device logs show “normal operation.” The manufacturer’s position is that the device functioned correctly. The family’s expert witness contends that the logs are incomplete and potentially insufficient for conclusive analysis.

Such cases can extend for years. Legal costs can reach several million pounds. Jury verdicts or settlements may reach substantial amounts. Appeals can add additional years to resolution.

The challenge: definitive determination of what actually occurred may remain elusive.

This pattern is not uncommon. It reflects a recurring challenge when deploying complex, timing-dependent software in life-critical implantable devices. Industry estimates suggest that litigation, recalls, and related costs in this space may reach hundreds of millions of pounds annually across major manufacturers.

The Reproducibility Challenge

Modern implantable cardiac devices—pacemakers, implantable cardioverter-defibrillators (ICDs), cardiac resynchronization therapy (CRT) devices—run sophisticated embedded software. This software makes thousands of decisions per day:

  • When to pace (deliver electrical stimulus)
  • How much energy to deliver
  • Whether to defibrillate
  • How to interpret sensor data
  • When to log events
  • How to manage battery power

In conventional implementations, these decisions can depend on:

  • Interrupt timing from sensors and timers
  • Scheduler decisions about which tasks run when
  • Memory access patterns that vary with system load
  • Timing-dependent interactions between concurrent processes

This means that similar patient conditions may produce different device behaviors depending on timing, system state, and execution history. When a device-related adverse event occurs, reconstructing exactly what happened can be challenging.

Litigation Patterns

Medical device litigation often follows recognisable patterns:

Phase 1: The Incident (Day 0)

  • Patient experiences adverse event (arrhythmia, cardiac arrest, device-related issue)
  • Device logs retrieved (if patient survives) or extracted post-mortem
  • Logs may show: “Device operated within normal parameters”

Phase 2: Expert Analysis (Months 1-12)

  • Plaintiff’s expert may argue: “The logs are incomplete or insufficient”
  • Defendant’s expert may argue: “The logs show proper function”
  • Neither side may be able to definitively establish device state at moment of failure
  • Discovery may demand device source code, test procedures, validation data

Phase 3: Extended Litigation (Years 1-5)

  • Engineers testify about device behavior under “similar” conditions
  • Simulator-based attempts to recreate incidents can be limited by timing-dependent variability
  • Juries may decide based on probability assessments rather than definitive evidence
  • Settlement or verdict costs vary widely

Phase 4: Regulatory Considerations (Years 2-10)

  • Regulators may mandate design changes
  • Class actions or recalls may occur (costs can be substantial)
  • Reputational effects may impact market position
  • Insurance costs may increase

Industry-wide costs are difficult to quantify precisely, but publicly reported cases suggest material financial exposure across major manufacturers.

Limitations of Conventional Logging

Device manufacturers log events extensively. A typical pacemaker generates records of:

  • Heartbeat detections
  • Pacing decisions
  • Battery voltage
  • Lead impedance
  • Arrhythmia episodes
  • Parameter changes

However, conventional logging has limitations for post-incident analysis:

1. Sampling Rather Than Complete Capture

Logs capture samples of device state, not complete execution traces. Between logged events, many software decisions occur. If an issue arises between samples, root cause may be difficult to observe.

2. Timing Uncertainty

Event timestamps depend on system clock, which can drift with temperature, battery voltage, and crystal oscillator variations. Events logged “simultaneously” may have occurred in different orders. Reconstructing causal chains can be challenging.

3. Incomplete State

Logs capture what developers anticipated would be important. If an issue involves an unlogged variable or edge case, evidence may not exist. This can complicate post-incident analysis.

4. Potential Data Issues

After device failure (battery depletion, memory issues, electromagnetic interference), logs may be partial or corrupted. Complete log integrity may be difficult to establish definitively.

5. Reproducibility Limitations

Most significantly: even with complete logs, execution may be difficult to reproduce. Simulator runs with similar inputs may produce different outputs due to timing variations. Claims about device behavior can be difficult to verify conclusively.

Conventional Pacemaker Logging
  • Event sampling (may be incomplete)
  • Timing can be uncertain
  • Limited state capture
  • Potential data integrity issues after failure
  • Reproduction can be challenging
  • Expert testimony often required
  • Litigation timelines can extend for years
Deterministic Kernel Approach (e.g., CardioCore)
  • Designed for complete execution tracing
  • Tick-based timing for consistency
  • Full state capture at boundaries
  • Cryptographic tamper-detection
  • Designed to support reproducible replay
  • Can reduce reliance on testimony
  • May significantly reduce investigation time

A Deterministic Approach: CardioCore

CardioCore is designed to address reproducibility challenges through deterministic kernel architecture. The goal is execution that can be replayed with consistent results.

Tick-Based Execution

All device decisions occur at discrete tick boundaries (typically 1ms intervals for cardiac devices). Sensor inputs, pacing decisions, and state transitions are synchronised to ticks.

This approach is designed to reduce timing variability:

  • Interrupts are processed at tick boundaries (not immediately)
  • Tasks execute in deterministic order each tick
  • The architecture is designed to reduce race conditions
  • Replay is designed to produce consistent execution across supported configurations

Complete State Capture

At each tick, CardioCore is designed to capture:

  • Input state: sensor values (ECG, accelerometer, battery voltage)
  • Decision state: algorithm parameters, thresholds, mode settings
  • Output state: pacing commands, defibrillation decisions
  • Internal state: timers, counters, state machines

This creates an execution trace from which any tick can potentially be reconstructed.

Cryptographic Attestation

Each tick’s state is hashed with SHA-256. Hash chains are designed to support:

  • Completeness detection: Missing ticks can be identified
  • Integrity verification: Modified logs are designed to be detectable
  • Temporal ordering: Event sequence is cryptographically bound

In post-incident analysis, this can provide:

  1. Device execution trace (initial state + input sequence)
  2. Cryptographic hash chain (supports trace completeness verification)
  3. Replay capability (enables independent verification)

Independent experts can potentially replay execution and verify consistent results. This can help narrow the scope of technical disputes.

Replay Verification

CardioCore includes replay capability:

  1. Load initial device state (at implantation or programming)
  2. Apply recorded input sequence (sensor data, patient commands)
  3. Execute deterministically (tick-based state transitions)
  4. Compare outputs against recorded execution

Potential result: Stronger evidence regarding device behavior at time of incident.

Reproducible execution evidence can significantly reduce ambiguity in technical investigations, potentially accelerating resolution regardless of outcome.

CardioCore Validation: Test Results

CardioCore has been validated through comprehensive automated testing demonstrating deterministic execution, safety integration, and replay verification in controlled test environments.

Integration Test Results

A full 5-phase integration test demonstrates critical capabilities:

# CardioCore Integration Demo - 500 Tick Execution

CardioCore™ Deterministic Medical Kernel

PHASE 1: Kernel + DSE Scheduler
  [0] Sensing  - priority=1, period=1
  [1] Pacing   - priority=2, period=10
  [2] Monitor  - priority=10, period=100

PHASE 2: Audit Log (Hash-Chained)
  Max entries: 1024
  Initial hash: 484a383b...

EXECUTION: 500 Ticks
  Tick 100: hash=e13188d3...
  Tick 200: hash=2b61245e...
  Tick 300: hash=7521bcb2...
  Tick 400: hash=a0679525...
  Tick 500: hash=fd184f65...

DETERMINISM VERIFICATION
  Run 1: fd184f65ffb63b49...
  Run 2: fd184f65ffb63b49...
  Result: VERIFIED ✓

STATISTICS
  Safety checks: 50 | Vetoes: 0
  Audit entries: 1055
  Hash chain: VERIFIED

✓ All 5 phases complete
✓ Replay(Σ₀, L, t) = Σₜ verified

What These Results Demonstrate

Reproducible Execution: Two independent runs with identical initial state and input sequence produced identical final state hashes. This provides evidence that execution is reproducible under test conditions.

Complete Audit Trail: 1,055 events logged across 500 ticks with cryptographic hash chain verification. Sensing events, pacing decisions, and safety checks are recorded with tamper-detection capability.

Safety Integration: VITA-SB safety layer performed 50 checks with 50 modifications (safety constraints applied). Zero vetoes indicates normal operation within safety boundaries during testing.

Replay Capability: The system can restart from initial state Σ₀, apply recorded event log L, and reach identical final state Σₜ. This supports incident reconstruction capability.

Test Coverage

CardioCore includes comprehensive automated test suites:

# CardioCore Test Suite

Unit Tests:
  test_kernel.c    - Core kernel functionality
  test_log.c       - Audit log and hash chains
  test_state.c     - State transitions
  test_replay.c    - Replay engine verification
  test_safety.c    - VITA-SB safety layer
  test_hash.c      - Cryptographic hash functions

Integration Tests:
  demo_integration.c - Full 5-phase integration
  demo_basic.c       - Basic pacing scenarios

All tests: PASSING ✓

This validation demonstrates CardioCore as a proof-of-concept deterministic kernel with reproducibility verification under controlled test conditions. Production deployment and medical device certification would be completed by the acquiring organisation.

Illustrative Impact Comparison

The following scenario illustrates potential differences in investigation approaches:

Patient: 72-year-old with ICD implanted for ventricular tachycardia Incident: Device delivered shock during rhythm that patient’s cardiologist questions Outcome: Patient survived but experienced distress

Conventional Investigation Approach

Potential Timeline:

  • Months 1-6: Device interrogation, log analysis, expert engagement
  • Months 7-18: Discovery (source code, test data, similar incidents)
  • Months 19-36: Expert analysis, simulator attempts, technical discussions
  • Months 37-48: Trial preparation, proceedings, resolution
  • Months 49-60: Potential appeals, final settlement

Potential costs: Can reach several million pounds including legal fees, expert witnesses, and settlement/verdict.

Challenge: Questions may remain about precise root cause.

Deterministic Kernel Approach

Potential Timeline:

  • Weeks 1-2: Device trace retrieved (complete execution record)
  • Weeks 2-3: Independent expert replays execution, verifies reproducibly
  • Weeks 3-4: Replay analysis identifies specific algorithm behavior
  • Weeks 4-6: Parties have clearer technical basis for resolution

Potential costs: May be substantially reduced due to faster, clearer technical analysis.

Potential outcome: Root cause more readily identifiable. Clearer basis for resolution regardless of liability determination.

Note: Timeline and cost comparisons are illustrative and based on general industry patterns. Actual outcomes depend on case specifics, jurisdiction, and many other factors.

Regulatory Considerations

Beyond post-incident analysis, deterministic execution may provide regulatory advantages:

IEC 62304 Alignment

IEC 62304 (Medical Device Software Lifecycle) emphasises:

  • Complete traceability from requirements to implementation
  • Verification that software behaves as specified
  • Analysis of failure modes

Deterministic kernels can support:

  • Traceability: Execution maps to requirements in reproducible fashion
  • Verification: Replay can demonstrate specified behavior
  • Failure mode analysis: Replay enables systematic edge case testing

This may support FDA/MHRA submissions and reduce post-market surveillance burden.

Post-Market Surveillance

Regulators require ongoing monitoring of device performance in real-world use. With deterministic execution:

  • Incident analysis: Field issues may be reproducible in lab settings
  • Trend detection: Patterns may emerge from analysis of fleet data
  • Response capability: Firmware updates can potentially be validated against historical traces

This may reduce recall risk and support patient safety outcomes.

Clinical Trial Efficiency

Device trials require demonstrating safety and efficacy. Deterministic execution may enable:

  • Reproducible endpoints: Trial results potentially verifiable by replay
  • Accelerated analysis: Deterministic traces may enable automated analysis
  • Regulatory confidence: Reviewers may be able to independently verify claims

This could potentially reduce trial timelines, though actual impact depends on regulatory acceptance and specific trial design.

Economic Considerations for Device Manufacturers

Adopting deterministic kernels may produce financial benefits across several areas:

Litigation costs: Faster, clearer technical analysis may reduce legal expenses and settlement amounts.

Recall costs: Deterministic firmware updates may be validatable without full device replacement in some scenarios.

Regulatory timelines: Improved traceability and reproducibility may support faster approvals.

Insurance: Demonstrable reproducibility may support more favorable risk assessments.

Market position: Differentiation on safety and traceability may provide competitive advantages.

Note: Economic impacts are indicative and depend on organisation size, product portfolio, regulatory context, and many other factors. Actual results will vary.

Implementation Considerations

Transitioning to deterministic kernels involves several factors:

Hardware Compatibility

CardioCore is designed to support standard medical device hardware:

  • ARM Cortex-M series (M0+, M3, M4, M7)
  • Low-power operation (minimal overhead)
  • Small memory footprint (<20KB kernel)
  • Standard peripherals (UART, SPI, I2C, ADC)

No custom silicon required. Existing device hardware is generally compatible.

Software Migration

Legacy device software can potentially be incrementally migrated:

  1. Phase 1: Wrap existing algorithms in deterministic execution framework
  2. Phase 2: Refactor algorithms to tick-based architecture
  3. Phase 3: Add replay verification and cryptographic attestation

Migration timeline depends on codebase complexity and organisational factors.

Regulatory Pathway

Deterministic kernels may support regulatory submissions:

  • Premarket: Deterministic execution can simplify verification and validation evidence
  • Post-market: Replay capability can support incident investigation
  • Updates: Firmware changes may be validatable deterministically

IEC 62304 compliance is maintained. Specific regulatory guidance on deterministic architectures continues to evolve.

Conclusion

The medical device industry faces ongoing challenges related to software reproducibility. Post-incident analysis, litigation, and regulatory compliance can all be complicated when execution cannot be reliably reconstructed.

Deterministic execution represents one architectural approach that can materially improve reproducibility, traceability, and post-incident analysis in implantable medical devices. While not a universal solution, it addresses a class of challenges that have proven costly for manufacturers, regulators, and patients alike. As with any architectural approach, suitability depends on system requirements, risk classification, and regulatory context.

CardioCore demonstrates that deterministic execution is practical and deployable for implantable cardiac devices. For manufacturers evaluating architectural approaches for next-generation devices, understanding how execution reproducibility affects investigation, liability, and regulatory outcomes can help inform design decisions.

As the industry continues to evolve, architectural choices that support reproducible execution may play an increasingly important role in enabling reliable verification, investigation, and long-term confidence in implantable medical device software.

About the Author

William Murray is a Regenerative Systems Architect with 30 years of UNIX infrastructure experience, specializing in deterministic computing for safety-critical systems. Based in the Scottish Highlands, he operates SpeyTech and maintains several open-source projects including C-Sentinel and c-from-scratch.

Discuss This Perspective

For technical discussions or acquisition inquiries, contact SpeyTech directly.

Get in touch
← Back to Insights