Skip to content
inowattioPublic

About

Customizable, powerful and versatile Modbus Client.

Topics

Resources

Stars

42 stars

Watchers

1 watching

Forks

Latest commit

 

History

825 Commits

Folders and files

Repository files navigation

MTUI - Modbus Terminal User Interface

A keyboard-driven Modbus client for your terminal, built for speed and customizable down to the columns and keybinds.

Made in pure safe Rust, based on tokio-modbus and ratatui (with ratzilla for the web demo).

Demo

Play the GIF to see a quick tour, or better yet, try it in your browser (mock device only): https://inowattio.github.io/MTUI/

Features

  • Modbus TCP, RTU, RTU-over-TCP and a built-in mock device for playing around
  • Live register reading with auto-refresh, pause/resume and unit id selection
  • Interpretation columns with configurable word order: u16, i16, hex, binary, ASCII, u32, i32, f32, f64, M10K (and more!)
  • Panels: main view, pinned, labeled, custom rules and an address matrix
  • Pin, label and custom-rule registers; jump to address or label
  • Value graph for a register over time
  • Register writes, with a write log and an optional read-only mode
  • HTTP API (POST /read, POST /write, POST /raw, GET /health, see openapi.yaml, can run standalone with --headless)
  • MCP server on the same port at /mcp (Streamable HTTP, enable it under Settings / API), exposing device_status, list_registers (labels and custom rules), read_registers (optionally decoding custom rules), write_registers and raw_function tools under the same API settings, e.g. claude mcp add --transport http mtui http://localhost:26127/mcp
  • Dump read data to a file, copy addresses to the clipboard, paste pins/labels/custom rules to import them (Home Assistant Modbus YAML config or .mbmap.json are accepted too)
  • Export pins, labels and custom rules (or the whole config) to the clipboard or a file, as MTUI JSON, Home Assistant Modbus YAML or .mbmap.json (Settings / Config / Export)
  • Browse device register libraries and import from them straight from the app: the mbmap-library, SunSpec models and the Solarman inverter definitions.
  • Snapshot diffing: paste a dump to compare it with the current reads
  • Configurable via files, a user-located config.json file will be created on the first startup (~/.config/mtui/ on Linux, %APPDATA%\inowattio\mtui\config\ on Windows, ~/Library/Application Support/io.inowattio.mtui/ on macOS), overridable with --config <path> and can also be modified in-app, the config can also be switched on the fly.

Press h inside the app for all available keybinds.

Running

Multiple options are available:

  • (Linux) install via snap install mtui
  • (Debian/Ubuntu) download the .deb from releases and sudo apt install ./mtui_*.deb
  • download a binary from releases
  • with cargo via cargo install mtui
  • clone the repository and then cargo run

Performance

The project aims to run using as little resources as possible.
Using the default demo config on 1.9.1 with a screen size of 120x30:

CPU / Platform OS Render Time Memory usage
Intel i9 12900H Ubuntu 26.04 0.19 ms 7.6 MB
Raspberry Pi Zero 2 Raspbian 13 2.70 ms 5.5 MB
Raspberry Pi 5 Raspbian 12 0.41 ms 5.6 MB
Apple M1 Tahoe 26.3.1 0.97 ms 10.1 MB

These should give off an estimated performance outlook.
The count of data samples and the customs amount can vastly change these (amongst many other things).

LLM usage disclosure

LLM-based tools have been used to develop the project.
If LLM(s) are used upon creating PRs/issues, please keep in mind to always check the generated content to be as concise (and short) as possible.

Usage suggestions

If you'd want to quickly map a protocol definitions document, one could use any LLM with said document and specify in the context of this repository source code to create a JSON file and then copy and paste into a session to import it.

About

Customizable, powerful and versatile Modbus Client.

Topics

Resources

Stars

42 stars

Watchers

1 watching

Forks

Releases

Used by

Contributors

Languages