Inspiration
Connecting modern AI agents directly to physical robotics introduces two major hazards: non-deterministic latency from garbage-collected runtimes and LLMs, and long-term cryptographic vulnerability ("harvest now, decrypt later") on industrial control links.
We wanted to prove that high-level AI supervision can be safely decoupled from hard real-time actuation—combining the concurrency of Java 21 (OpenTron / JVMAI) with the deterministic microkernel guarantees of QNX Neutrino RTOS 8.0 and Post-Quantum Cryptography (PQC).
What it does
OpenTron QNX Robotics Supervisor separates high-level supervisory planning from deterministic, real-time motor control for a simulated single-axis robot:
- Non-Real-Time AI & Supervisory Plane (Java 21): Runs on the OpenTron / JVMAI Spring Boot engine, exposing a strictly typed setpoint tool and REST API (
dispatch_robot_setpoint). Natural-language prompts and unvalidated metadata never reach the real-time target. - Post-Quantum Secured Control Bridge: Protects supervisor-to-worker command and telemetry channels against quantum-era eavesdropping and tampering, paired with fixed-size network-byte-order binary frames (
QNX1) verified via CRC-16/CCITT-FALSE checksums. - Deterministic 1 kHz Real-Time Worker (QNX 8.0): A native C++ worker running on QNX 8.0 owns the $1\text{ kHz}$ ($1\text{ ms}$) control loop, heartbeat watchdog, and local safety interlocks—completely independent of the JVM.
- Hardware-Style Safety Interlocks: Enforces position bounds ($0\text{–}1000\text{ mm}$), velocity limits ($1\text{–}100\text{ mm/s}$), a forbidden exclusion zone ($450\text{–}550\text{ mm}$), thermal cutoff ($80^\circ\text{C}$), and a latched emergency stop if the $300\text{ ms}$ heartbeat watchdog expires.
How we built it
- QNX 8.0 Native Worker (
qnx-worker/): Built in C++ usingqcc(gcc_ntox86_64/gcc_ntoaarch64le). Uses native QNX timers and pulses for deterministic $1\text{ kHz}$ loop execution,SCHED_FIFOreal-time thread priorities, Priority Inheritance (PI) mutexes to prevent priority inversion, and QNX socket libraries. - Java 21 Supervisor Backend (
java/opentron-java/): Built on Java 21 (Virtual Threads & Project Panama FFM) and Spring Boot. Translates high-level supervisory requests into compact 16-byte binary command packets and parses 24-byte telemetry frames over TCP. - PQC & Protocol Integrity: Secured the transport/session layer with Post-Quantum Cryptography alongside frame-level sequence numbers and CRC-16/CCITT-FALSE integrity checks (
poly 0x1021,init 0xffff). - Fault-Injection & Demo Harness (
scripts/): Created a PowerShell CLI (demo.ps1) capable of querying telemetry, dispatching bounded setpoints, and injecting a $500\text{ ms}$ heartbeat stall to verify that the QNX worker independently trips its $300\text{ ms}$ watchdog and latches an emergency stop.
Challenges we ran into
- Strict Real-Time Isolation: Ensuring the JVM never sits inside the critical control path required designing a strict binary wire contract where the QNX worker rejects any setpoint until heartbeat supervision is established and independently validates every bound.
- Deterministic Synchronization on QNX: Coordinating the $1\text{ kHz}$ pulse-driven control loop with asynchronous TCP telemetry/command threads without introducing jitter required careful use of
SCHED_FIFOpriorities and priority-inheritance mutexes. - Cross-Platform Toolchain & QEMU Networking: Bridging a Windows-hosted Java 21 supervisor with a virtualized QNX 8.0 QEMU target required configuring host-to-guest TCP port forwarding (
9090) and validating low-latency packet round-trips under fault-injection scenarios.
Accomplishments that we're proud of
- Achieving clean separation of concerns between an AI-capable Java 21 supervisor and a deterministic $1\text{ kHz}$ QNX 8.0 RTOS control loop.
- Implementing a compact, zero-bloat binary wire protocol (
16-bytecommands,24-bytetelemetry) with deterministic watchdog latching demonstrated live via fault injection. - Integrating quantum-resistant cryptographic protection into a lightweight industrial robotics control bridge without compromising real-time loop determinism.
What we learned
- AI belongs in the supervisory plane, never the control loop: Treating an LLM or JVM purely as a bounded setpoint proposer—while letting QNX own timing, watchdogs, and safety interlocks—makes AI-assisted robotics predictable and auditable.
- QNX primitives make determinism explicit: Working directly with QNX pulses,
SCHED_FIFOpriorities, andpidin schedinspection highlighted how deterministic scheduling differs from general-purpose OS threading.
What's next for OpenTron QNX Robotics Supervisor
- Physical Hardware Deployment: Porting the QNX 8.0 worker from QEMU onto an ARM64 (
aarch64le) embedded board (such as Raspberry Pi 4 or NXP i.MX) connected to real motor drivers and hardware E-stop circuits. - Hardware-Backed PQC & TEE Attestation: Combining our PQC transport layer with Confidential Computing / Trusted Execution Environments (TEEs) so the QNX worker can cryptographically attest both the supervisor's identity and enclave integrity before accepting motion commands.
- Multi-Axis Kinematics: Expanding the
QNX1binary frame protocol to support synchronized multi-axis trajectory interpolation at $1\text{ kHz}$.