serial-console-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| list_serial_portsA | List every serial port the computer can currently see. Call this FIRST whenever the user wants to connect to a device but hasn't given
an exact port name, or when a connection fails. Returns each port's system name
(what you pass to |
| connectA | Open a serial port and start the background reader. The defaults are 9600 baud, 8 data bits, no parity, 1 stop bit, no flow control ("9600 8N1"), which is what most console/craft ports and much radio gear expect. Every setting can be overridden when the user says so, e.g. "38400 with XON/XOFF" -> baud=38400, xonxoff=True. Args:
port: System port name, e.g. "COM4" (Windows), "/dev/cu.usbserial-10"
(macOS), or "/dev/ttyUSB0" (Linux). Get exact names from
|
| reconnect_lastA | Reconnect to the most recently used port/settings from a previous session. Handy at the start of a chat so the user doesn't have to repeat the port and
baud rate. If nothing is remembered, tells you to use |
| send_textA | Send an ASCII command to the device. Writes to TX only; does NOT read. On an interactive console the device will ECHO this text back and then print
its output; call Args: data: The command text, e.g. "show version", "FA014250000", or "ID". Non-ASCII characters are sent as "?"; use send_hex for raw bytes. line_ending: What to append — "CR" (\r, most rigs), "CRLF" (\r\n), "LF" (\n, most Unix-style consoles), or "NONE". clear_buffer_first: Discard buffered RX before sending. |
| send_hexA | Send raw bytes given as hex. Writes to TX only; does NOT read. Use for binary protocols — notably Icom CI-V, which is all hex (e.g.
"FE FE 94 E0 03 FD"). Spaces in the hex string are ignored. To see a binary
reply, call Args: hex_bytes: Bytes as hex, e.g. "FE FE 94 E0 03 FD". clear_buffer_first: Discard buffered RX before sending. |
| read_until_promptA | Read accumulated output until a prompt appears, or until timeout. This is the right tool for interactive CLI sessions (routers, switches, shells).
It reads from the background buffer until Typical flow: send_text("show version", line_ending="LF", clear_buffer_first=True) read_until_prompt(prompt="# ") Args:
prompt: The text that marks the end of output. Literal by default, e.g.
"# ", "> ", "login: ", "$ ", "Password:". Common device prompts end in
"# " (enable) or "> " (user). Note the match is searched in everything
received, including the echo of your own command, so prefer a prompt
with its trailing space over a bare "#" or ">" when the command text
itself could contain that character.
timeout: Max seconds to wait for the prompt to appear.
regex: Treat |
| read_availableA | Drain and return whatever the device has sent, without transmitting anything. Use for unsolicited/streaming output (syslog on a console, GPS, a sensor, a rig
in auto-info mode), or to grab a binary reply after |
| query_textA | Convenience: clear the buffer, send an ASCII command, and read the reply. For the common "ask the device something and read its answer" case. If Args: data: Command text, e.g. "show version" or "ID". line_ending: "CR", "CRLF", "LF", or "NONE" (see send_text). prompt: Optional literal prompt to read until, e.g. "# ". Empty = read until idle. read_timeout: How long to wait overall, in seconds. |
| clear_bufferA | Discard any buffered received data. Handy right before sending a command so the next read starts clean (drops old echo, prior output, or syslog noise). |
| statusA | Report whether a port is open, with what settings, and how much RX is buffered. |
| disconnectA | Close the serial port and free it for other programs. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 11 tools
Most tools have clear, distinct purposes: connect/disconnect/list/status/clear are unambiguous, and send_text vs send_hex are clearly separated by data type. The only mild overlap is query_text being a convenience wrapper around send+read, and read_until_prompt vs read_available both reading but with different termination conditions; descriptions clarify these well.
Names mostly follow a verb_noun pattern (list_serial_ports, send_text, clear_buffer, read_available) and all use lowercase snake_case. Minor deviations like standalone verbs (connect, disconnect, status) and reconnect_last break the pattern slightly but are still predictable and readable.
11 tools is well within the ideal 3-15 range and each tool earns its place for a serial console server: discovery, connection lifecycle, sending in both ASCII and hex, multiple read modes, buffer management, and session state.
The surface covers the full serial interaction lifecycle: discover ports, connect with configurable settings, reconnect from memory, send text or binary, read via prompt or drain, clear stale data, check status, and disconnect. No obvious dead ends or missing operations for the stated domain.