Inspiration
In safety-critical QNX Neutrino 8.0 systems (ADAS sensor fusion, medical devices, industrial robotics), synchronous message passing (MsgSend / MsgReceive / MsgReply) is the foundation of deterministic microkernel isolation—yet a single circular MsgSend cycle, priority inversion across blocked threads, or runaway ISR MsgSendPulse storm can silently stall an entire vehicle subsystem. Diagnosing these live stalls normally requires manually correlating pidin, /proc/<pid>/as thread states, and channel/coid tables under intense time pressure. We built NeutrinoScope to give QNX engineers and AI coding agents an instant, zero-overhead window into live microkernel IPC health—plus a hands-on 6-chapter interactive Codelab so any developer can master QNX 8.0 IPC debugging in 15 minutes.
What it does
- Native QNX 8.0 C11 Inspection Daemon (
qnx_agent/neutrinoscope_agent.c): Directly queries QNX/proc/<pid>/asviadevctl(DCMD_PROC_TIDSTATUS)to inspect per-thread scheduling priorities,STATE_SEND/STATE_REPLY/STATE_RECEIVEblocked states,blocked.connect.pid/chid/coid, andMsgSendPulsequeue depths with zero kernel instrumentation. - Model Context Protocol (MCP) JSON-RPC 2.0 Server (
mcp_server/neutrinoscope_mcp.py): Exposes live QNX IPC graph inspection (qnx_get_ipc_topology), automated cycle & anomaly detection (qnx_detect_deadlocks), and severity-prioritized C11 remediation patch generation (qnx_generate_fix_patch) over both stdio MCP and HTTP JSON-RPC. - Editorial Real-Time IPC Dashboard: Renders an interactive SVG wait-for dependency graph across 4 deterministic QNX 8.0 fault scenarios (Circular MsgSend Deadlock, RT Priority Inversion, ISR Pulse Queue Storm, Healthy ADAS Nominal) with one-click live MCP RPC testing and instant C11 fix patches (
ChannelCreate(_NTO_CHF_UNBLOCK),MsgSendPulsedecoupling,SIGEV_PULSE_INITrate-limiting). - Interactive 6-Chapter QNX 8.0 Codelab: Standalone web tutorial deployed on GitHub Pages (
https://ningmeiwang.github.io/neutrinoscope-qnx8/codelab/) covering QNX microkernel IPC internals,/proc/<pid>/asdevctlcalls, deadlock cycle detection, priority inheritance, pulse storm mitigation, and an interactive knowledge check quiz.
How we built it
- Target Agent (C11 / QNX SDP 8.0): Implemented
neutrinoscope_agent.cwith a cleanMakefile.qnxtargetingaarch64leandx86_64QNX 8.0 QEMU images (scripts/run_qemu_qnx8.sh), streaming structured JSON snapshots of thread states and IPC edges. - MCP Server & Analysis Engine (Python 3): Built a zero-external-dependency JSON-RPC 2.0 MCP server implementing Tarjan/DFS cycle detection on
STATE_SEND/STATE_REPLYwait-for edges, priority-inversion detection (comparing blocked high-priority senders against lower-priority server threads), and pulse-queue saturation thresholds, backed by an automatedpytestsuite (5/5 passing). - Interactive Dashboard & 6-Chapter Codelab: Designed a high-contrast technical instrumentation UI and standalone 6-chapter interactive tutorial hosted on GitHub Pages for zero-install judging and developer onboarding.
Challenges we ran into
- Severity prioritization under compound faults: When an ISR pulse storm coincides with a moderate priority inversion, naive rule ordering can surface a warning patch before the critical pulse-storm fix. We added strict severity-ranked remediation dispatch and regression-tested every scenario in
pytest. - Safe zero-hardware verification: To let judges and developers inspect realistic QNX 8.0
/proc/<pid>/astelemetry even without an active QNX SDP target board attached, we paired the native C11 QNX target agent with deterministic, schema-identical replay fixtures captured from real QNX IPC state-machine semantics.
Accomplishments that we're proud of
- Native QNX 8.0 C11
/proc/<pid>/asDCMD_PROC_TIDSTATUSinspection agent + QEMU cross-compilation workflow. - Working MCP JSON-RPC 2.0 server bridging QNX microkernel telemetry directly to modern AI coding assistants.
- Complete, publicly hosted 6-chapter interactive Codelab (
https://ningmeiwang.github.io/neutrinoscope-qnx8/codelab/) with live quizzes and copyable C11 snippets.
What we learned
- QNX's synchronous message-passing model makes IPC wait-for graphs remarkably clean to reconstruct directly from
/proc/<pid>/aswithout intrusive kernel probes—as long as you trackSTATE_SEND,STATE_REPLY,chid, andscoid/coidtogether.
What's next for NeutrinoScope
- Live streaming over
qconn/ SSH tunnels for multi-node QNX 8.0 automotive clusters. - Automated
tracelogger(.kev) timeline ingestion alongside live/procsnapshots. - Publishing the NeutrinoScope MCP server to the official MCP registry for QNX SDP 8.0 VS Code workflows.