QNX-Based Real-Time Power Supply Control for HT-7U Tokamak
The HT-7U superconducting tokamak requires stringent real-time control for its poloidal field (PF) power supplies. This article presents the design of a QNX 6.20-based control system achieving a 1 ms control cycle across 12 independent power supply units, addressing communication, feedback, measurement, and synchronization challenges in high-stakes fusion experiments.
โก Introduction #
The HT-7U (EAST) tokamakโs PF power supply system is essential for plasma initiation, shaping, position regulation, and sustainment. Key characteristics include:
- 12 independent power supplies, each managing multiple thyristor converters and protection devices.
- Over 700 I/O signals, including ~80 hard real-time signals (<1 ms response).
- Hybrid hard/soft real-time environment, requiring precise synchronization across distributed controllers.
Meeting these requirements necessitated selecting a high-performance RTOS capable of deterministic timing and robust distributed communication.
๐ Selection of the Real-Time Operating System #
RTOS Performance Comparison #
| RTOS | Max/Avg Interrupt Latency (ยตs) | Thread Switch Time (ยตs) | Min Interrupt Period (ยตs) | Cross-Network IPC | Scheduling |
|---|---|---|---|---|---|
| QNX 6.20 | 4.3 / 1.7 | 21.8 / 8.8 | 9 | Yes (Qnet) | FIFO, RR, Adaptive |
| VxWorks AE 1.1 | 6.8 / 1.7 | 46.8 / 6.8 | 25 | No | Priority, RR |
| Windows CE .NET | 5.6 / 2.4 | 16.7 / 9.6 | 11 | No | RR |
| ELDS 1.1 | 4.0 / 3.2 | N/A | 60 | No | FIFO, RR |
QNX 6.20 was selected due to its microkernel architecture, low-latency Qnet IPC, and deterministic real-time capabilities.
QNX 6.20 Highlights #
- Microkernel with message-passing IPC.
- Distributed control via Qnet.
- SMP support (up to 8 CPUs), x86/PowerPC/ARM compatible.
- Nanosecond-level timing resolution.
- Mature cross-platform development tools.
Measured performance:
- Local message round-trip: ~few ยตs
- Network round-trip (same LAN): minimal latency and jitter
๐ฅ System Architecture #
The system uses a three-layer hierarchical design:
1. Windows Monitoring Layer #
- HMI, waveform display, fault diagnosis.
- Communicates with QNX layer via TCP/IP (50 ms update interval).
2. QNX Real-Time Layer #
- Console Node: Parameter configuration, process coordination, monitoring.
- Data Server: Real-time database (Empress 8.60), 16 ms backup interval.
- Feedback Node: Multi-variable current feedback, signal acquisition, distribution to 12 PF controllers.
- PF Subsystem Controllers: One per power supply unit, managing local control, thyristor firing, and hard real-time I/O.
3. Fieldbus Execution Layer #
- Fieldbus modules for soft real-time signals.
- Direct DA/DIO for ultra-hard real-time signals (thyristor switches, quench protection).
๐ง Key Technical Solutions #
Real-Time Communication & Synchronization #
- Multi-threading with high-priority FIFO scheduling.
- Dedicated communication threads per controller.
- Achieved <1 ms cycle and synchronization error <200 ยตs.
Process Monitoring and Tracing #
- Software: QNX System Analysis Tool (SAT),
traceprinter,traceparser. - Hardware: Digital output cards + oscilloscope to verify critical timing.
High Availability and Reliability #
- Software HA: QNX High Availability framework, primary/backup process failover.
- Hardware Redundancy: Dual-network, dual-switch, CompactPCI systems.
- Fault Handling: Fast thyristor inversion and switch opening for safe shutdown.
Data Backup #
- Empress 8.60 real-time database with compression.
- 16 ms backup interval and automatic metadata logging per pulse.
๐ Conclusion #
The QNX 6.20-based control system satisfies the 1 ms real-time requirement for the HT-7U PF power supplies. Through layered architecture, optimized communication, HA mechanisms, and real-time monitoring, the system ensures:
- High reliability
- Precise synchronization
- Fault tolerance
Validation via single-unit and multi-unit simulations confirms the feasibility and effectiveness of the design.
๐ฎ Modern Perspective (2026) #
Advancements allow for further modernization using QNX SDP 8.x / Neutrino:
- Multi-core and safety-certified profiles
- Eclipse-based IDE or QNX Momentics
- ROS 2 or DDS for higher-level orchestration
- TSN or EtherCAT for tighter fieldbus synchronization
- Containerized RTPs with advanced core dump and trace capabilities
Despite technological evolution, the microkernel, deterministic IPC, and message-passing foundations of QNX remain highly relevant for fusion-grade real-time control applications.