ros2_tui
A powerful Terminal User Interface (TUI) for monitoring and managing ROS2 topics and parameters in real-time.
Prerequisites
- ROS2 installed and sourced
ros2 topicandros2 paramcommands available in your shell
Installation
From pypi
From crates.io
From Source
The binaries topics and params will be available at target/release/.
Topics TUI (topics)
Highlights
- 📊 Real-time Hz/Delay monitoring backed by streaming
ros2 topic hz/delay - 🌳 Namespace-aware topic tree with collapsible groups and instant search
- 🎯 Watch-only metrics so large graphs stay responsive and low overhead
- 🎨 Status indicators, Bollinger-band charts, and debug logging for on-call triage
Usage
# Start monitoring with default settings
# Custom refresh rate (topics list updates every 5 seconds by default)
Toggling a row with Enter starts Hz/Delay measurement. Unwatched topics stay lightweight, ensuring responsive navigation even with hundreds of topics.
Navigation & Controls
↑/↓orj/kmove between topics;←/→orh/lcollapse and expand namespacesEntertoggles watching on the focused topic or expands/collapses a groupTabtoggles the current group;ccollapses/expands all groups at oncestoggles simulation time when measuring delay metricsF4opens live search with auto-expansion;Space,r, orF5refresh immediatelyq,Esc, orCtrl+Cquit;--verbosewrites detailed logs totopics_debug.log
Command-Line Options
--refresh <SECONDS>– Topic list refresh cadence (default: 5)--detail-refresh <SECONDS>– Legacy detail polling interval (still accepted)--no-initial-fetch– Skip the initialros2 topic listcall--help,--version– Standard metadata flags
Architecture Highlights
- Background workers keep
ros2 topic list -v,ros2 topic hz, andros2 topic delaystreaming without blocking the UI - Crossbeam channels drive a non-blocking event loop that renders at ~5 FPS and processes input instantly
- Watched topics maintain FIFO histories (including std dev) to power Bollinger-band charts and statistical readouts
- Selective monitoring conserves system resources by spawning measurement processes only when needed
Params TUI (params)
Highlights
- 🧭 Node/namespace browser that mirrors
ros2 param listhierarchies - 🔄 Live value polling keeps displayed values fresh without manual refreshes
- ✏️ In-terminal editing with type validation plus YAML dump/load workflows
- 🧰 Built-in search, success/error banners, and contextual help overlays
Usage
# Parameter dashboard with 5 second refresh
# Faster poll rate for parameters
The app groups dotted parameter names into expandable namespaces so large graphs stay navigable. Value edits, dumps, and loads run through the ROS2 CLI and report their outcome inline.
Navigation & Controls
↑/↓orj/kmove through nodes and parameters;←/→orh/lcollapse/expand namespaces?opens the help overlay;F4enters search mode with persistent filteringSpace,r, orF5refresh on demand;Escexits dialogs, cancels search, or quits
Parameter Actions
sedits the selected parameter (array values are normalised for ROS2 compatibility)ddumps the current node to YAML viaros2 param dumpCtrl+lloads YAML into the active node usingros2 param load- Inline success/error banners acknowledge operations and fade automatically
Command-Line Options
--refresh <SECONDS>– Parameter polling cadence (default: 5)--no-initial-fetch– Skip the initialros2 param listscan--verbose/-v– Emit detailed logs toparams_debug.log--help,--version– Standard metadata flags
Architecture Highlights
- A primary watcher repeatedly shells out to
ros2 param list, building aParamTreethat mirrors node hierarchies - A secondary watcher streams value lookups to populate the table without blocking the UI thread
- Dump/load/edit workflows wrap the ROS2 CLI while scheduling delayed refreshes to reflect state changes
- All ROS2 interaction happens on background threads, keeping the Crossterm-driven interface responsive under load
Development
Building
Testing
Before Pushing
Check formatting
Lint code
Release Safety Check
Configure Git once so the bundled pre-push hook runs before release pushes:
When you push a tag such as v0.3.0, the hook calls scripts/check-release-version.sh and verifies the tag matches the Cargo.toml version. The push is rejected if they diverge, keeping release tags in sync with the crate metadata.
Comparison with Other Tools
| Tool | Language | Dependencies | Features | Performance |
|---|---|---|---|---|
| topics | Rust | ros2 CLI only | TUI, Real-time metrics | ⚡ Fast |
| params | Rust | ros2 CLI only | TUI, Parameter management | ⚡ Fast |
| rqt_topic | Python | Full ROS2 + Qt | GUI, Rich features | 🐌 Heavy |
| ros2 topic | Python | Full ROS2 | CLI only | 🚀 Fast but limited |
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Acknowledgments
- Inspired by turm - A TUI for the Slurm Workload Manager
- Built with ratatui - A Rust library for building rich terminal interfaces
Roadmap
- Topic filtering and search (F4 search mode)
- Hierarchical topic grouping with collapsible groups
- Add topic message preview/echo functionality
- services app
- actions app