serial-mcp

serial-mcp

0

Serial-MCP is an MCP server designed to facilitate communication between agents and devices connected via a computer's serial port. Built using the FastMCP framework, it provides robust features such as asynchronous operations, error handling, and connection management to ensure reliable serial communication.

Serial-MCP

MCP server enabling communication with devices connected via serial port. Designed with asynchronous operations for efficient I/O, it includes features like message buffering, error handling, and automatic connection management.

Features

  • Asynchronous Serial Communication
  • Message Buffering
  • Connection Management
  • Error Handling
  • Environment Configuration
  • Detailed Logging

Installation

  1. Clone the repository.
  2. Install dependencies.

Configuration

Environment variables allow customization of serial port, baud rate, and buffer length.

Requirements

  • Python 3.7+
  • pyserial
  • fastmcp
  • pydantic
  • asyncio

Usage

  • Start the server.
  • Use API endpoints to initialize connection, send messages, read messages, list ports, and more.