gcu-gimbal-mcp
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
gcu-gimbal-mcp
🌐 English | 中文
ROSClaw MCP Server for Xianfei GCU Series Camera Gimbal via Serial protocol.
Part of the ROSClaw Embodied Intelligence Operating System.
Overview
This MCP server enables LLM agents to control Xianfei Technology GCU series camera gimbals through the Model Context Protocol. The GCU (Gimbal Control Unit) series includes the Z-2Mini and A5 dual-camera gimbal models featuring visible light + thermal imaging cameras.
The server communicates via RS-232/USB serial using the proprietary GCU binary protocol with CRC-16 error checking.
LLM Agent ──MCP──► gcu-gimbal-mcp ──Serial──► GCU Gimbal (Z-2Mini/A5)Manufacturer Information
Item | Details |
Manufacturer | Xianfei Technology |
Location | Nanjing, China |
Product Series | GCU (Gimbal Control Unit) |
Supported Models | Z-2Mini, A5 Gimbal |
Product Type | Dual-camera payload (Visible + Thermal) |
Related MCP server: mcp-serial-bridge
SDK Information
Property | Value |
SDK Name | GCU Gimbal SDK |
SDK Version | V2.0.6 |
Protocol | Binary Serial (Proprietary) |
Protocol Document | |
Manufacturer | Xianfei Technology |
Product Series | GCU (Gimbal Control Unit) |
Source | Proprietary |
License | Proprietary |
Generated | 2026-04-07 |
Hardware Specification
Product Information
Specification | Value |
Product Name | GCU Dual-Camera Gimbal |
Manufacturer | Xianfei Technology, Nanjing, China |
Supported Models | Z-2Mini, A5 |
Camera Type | Visible Light + Thermal Imaging |
Application | UAV Payload, Robotics, Surveillance |
Mechanical Specifications
Specification | Value |
Axes | 3-axis (Yaw, Pitch, Roll) |
Rotation Range | Yaw: ±170°, Pitch: -90° to +30°, Roll: ±45° |
Max Speed | ±150°/s (pitch/yaw) |
Stabilization | 3-axis mechanical stabilization |
Communication Interface
Specification | Value |
Protocol | GCU Binary Serial Protocol |
Serial Config | 115200 bps, 8 data bits, 1 stop bit, No parity |
Frame Header | 0xA8 0xE5 (send) / 0x8A 0x5E (receive) |
Checksum | CRC-16 |
Command Frequency | Up to 50Hz |
Supported Models
Model | Description | Weight | Application |
Z-2Mini | Compact dual-camera gimbal | ~300g | Small UAVs, robotics |
A5 | Advanced thermal+visible camera system | ~500g | Professional UAVs |
Camera Specifications
Feature | Visible Camera | Thermal Camera |
Resolution | 1920x1080 | 640x512 |
Zoom | Optical + Digital | Fixed |
Night Vision | No | Yes (IR mode) |
Recording | Yes | Yes |
Features
3-axis control: Yaw, pitch, roll with degree precision
Multiple modes: Stabilization, follow, FPV, lock
Camera control: Photo capture, video record, zoom, focus
Night vision: IR mode with multiple sensitivity levels
Real-time feedback: Position, temperature, velocity at 50Hz
CRC-16 checksum: Reliable serial communication
Auto-reconnect: Handles serial disconnections gracefully
Installation
# Clone
git clone https://github.com/ros-claw/gcu-gimbal-mcp.git
cd gcu-gimbal-mcp
# Install with uv (recommended)
uv venv --python python3.10
source .venv/bin/activate
uv pip install -e .
# Or with pip
pip install -e .Serial Port Permissions (Linux)
sudo usermod -a -G dialout $USER
# Log out and back in for group changes to take effectQuick Start
Run as MCP Server
# stdio transport
python src/gimbal_mcp_server.pyClaude Desktop Configuration
{
"mcpServers": {
"rosclaw-gimbal": {
"command": "python",
"args": ["/path/to/rosclaw-gimbal-mcp/src/gimbal_mcp_server.py"],
"transportType": "stdio",
"description": "GCU Gimbal V2.0.6",
"sdk_version": "V2.0.6",
"sdk_source": "Proprietary"
}
}
}MCP Inspector (Testing)
mcp dev src/gimbal_mcp_server.pyAvailable Tools
Tool | Description |
| Connect to gimbal on serial port |
| Disconnect from gimbal |
| Set control mode (stabilize/follow/fpv/lock) |
| Rotate with angular velocity |
| Go to absolute yaw/pitch/roll |
| Return to center position |
| Calibrate gimbal IMU |
| Trigger camera shutter |
| Toggle video recording |
| Control zoom (in/out/stop) |
| Set specific zoom level |
| Trigger autofocus |
| Enable IR/night vision mode |
| Enable/disable on-screen display |
| Set LED illumination brightness |
| Enable laser rangefinder |
| Emergency stop rotation |
| Perform scan demonstration |
Available Resources
Resource | Description |
| Current angles, mode, temperature |
| Serial connection status |
| SDK metadata and version |
Work Modes
Mode | Code | Description |
| 0x11 | Pointing lock mode |
| 0x12 | Pointing follow mode |
| 0x14 | Euler angle control mode |
| 0x1C | First-person view mode |
| 0x13 | Top-down shooting mode |
Angle Limits
Axis | Range | Safety Level |
Yaw | -170° to +170° | 🟠 HIGH |
Pitch | -90° to +30° | 🟠 HIGH |
Roll | -45° to +45° | 🟡 MEDIUM |
Speed Limits
Axis | Max Speed | Safety Level |
Pitch | ±150°/s | 🔴 CRITICAL |
Yaw | ±150°/s | 🔴 CRITICAL |
Roll | ±150°/s | 🔴 CRITICAL |
Serial Protocol
The GCU protocol uses binary frames:
[0xA8][0xE5][LEN_L][LEN_H][VER][DATA...][CRC16_L][CRC16_H]Frame Structure
Field | Size | Description |
Header | 2 bytes | 0xA8 0xE5 (send) / 0x8A 0x5E (receive) |
Length | 2 bytes | Packet length (little-endian) |
Version | 1 byte | Protocol version (0x01) |
Data | Variable | Command + parameters |
CRC16 | 2 bytes | CRC-16 checksum (big-endian) |
Command Codes
Command | Code | Description |
| 0x01 | IMU calibration |
| 0x03 | Reset to center |
| 0x20 | Take photo |
| 0x21 | Toggle recording |
| 0x22 | Zoom in |
| 0x23 | Zoom out |
| 0x24 | Stop zoom |
| 0x25 | Set zoom level |
| 0x26 | Autofocus |
| 0x2B | IR/night vision |
| 0x73 | On-screen display |
| 0x80 | LED brightness |
| 0x81 | Laser rangefinder |
Safety Information
WARNING: This MCP server controls a motorized gimbal. Improper use can cause:
Equipment damage
Motor overheating
Mechanical wear
Safety Features
Feature | Description |
Speed Limits | ±150°/s enforced in software |
Angle Limits | Mechanical limits enforced |
CRC Checksum | All packets validated |
Emergency Stop |
|
Safety Levels
Level | Color | Description | Example |
CRITICAL | 🔴 | Immediate danger | Speed > 150°/s |
HIGH | 🟠 | Potential damage | Angle near limit |
MEDIUM | 🟡 | Caution needed | Extended operation |
LOW | 🟢 | Informational | Status check |
Emergency Procedures
Immediate Stop: Use
stop_rotation()toolPower Off: Disconnect power if mechanical issue
Reset: Use
reset_gimbal()to return to center
Error Handling
Error Codes
Code | Name | Severity | Description |
-1 | CONNECTION_FAILED | 🟠 error | Serial port not accessible |
-2 | TIMEOUT | 🟠 error | Command response timeout |
-3 | INVALID_PARAMETER | 🟠 error | Invalid angle or speed |
-4 | SAFETY_VIOLATION | 🔴 critical | Exceeds speed/angle limits |
-5 | NOT_INITIALIZED | 🟠 error | Not connected |
-6 | CRC_ERROR | 🟠 error | Checksum mismatch |
Troubleshooting
Issue | Possible Cause | Solution |
Connection failed | Port not found | Check COM port in Device Manager |
Connection failed | Permission denied | Add user to |
Command no response | Wrong baudrate | Verify 115200 setting |
Jerky movement | EMI interference | Use shielded cable |
CRC errors | Cable too long | Max 3m for USB-serial |
Finding Your Serial Port
# Linux
ls /dev/ttyUSB* /dev/ttyACM*
# Windows
# Use Device Manager → Ports (COM & LPT)
# Common: COM3, COM4, COM8
# macOS
ls /dev/tty.usbserial-*Dependencies
Python 3.10+
mcp[fastmcp]— MCP frameworkpyserial— Serial communication
Architecture
gimbal_mcp_server.py
├── SDK_METADATA — SDK version and protocol info
├── GimbalState — Gimbal state dataclass
├── GimbalSerialBridge — Serial communication bridge
│ ├── connect() — Open serial port
│ ├── _calculate_crc16() — CRC-16 implementation
│ ├── _build_control_packet() — Build binary frame
│ ├── send_packet() — Thread-safe send
│ └── _recv_loop() — Background 50Hz reader
└── MCP Tools — FastMCP tool definitionsReferences
GCU Protocol: GCU Protocol V2.0.6 (Chinese)
User Manual: Z-2Mini User Manual (Chinese)
MCP Protocol: https://modelcontextprotocol.io/
PySerial: https://pyserial.readthedocs.io/
License
MIT License — See LICENSE
Note: The GCU protocol is proprietary to Xianfei Technology. This MCP server is an independent implementation based on the published protocol specification.
Part of ROSClaw
rosclaw — Core framework (see arXiv paper)
rosclaw-g1-dds-mcp — Unitree G1 (DDS)
rosclaw-ur-ros2-mcp — UR5 arm (ROS2)
rosclaw-gimbal-mcp — GCU Gimbal (Serial)
rosclaw-ur-rtde-mcp — UR5 via RTDE
Generated by ROSClaw SDK-to-MCP Transformer
SDK Version: GCU V2.0.6 | Protocol: Binary Serial | CRC-16
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Protocol-native energy infrastructure orchestration for AI data centers. Provides 46 MCP tools across 8 grid protocols (IEC-61850, DNP3, Modbus, OCPP, OpenADR, IEEE 2030.5, IEC 60870-5-104, ICCP) with 5 core API primitives: connect, dispatch, settle, comply, and intel. Enables AI agents to programmatically interact with substations, grid interfaces, and energy assets for real-time workload-grid coordination.
214 tools for AI agents over one MCP endpoint: image, video, audio, 3D, data, storage, mail, GPUs.
MCP-Native LLM Orchestration Agent
Unified MCP Server is a remote MCP connector for AI agents and vertical AI products that provides access to 22,000+ authorized SaaS tools across 400+ integrations and 24 categories directly inside LLMs (Claude, GPT, Gemini, Cohere). Tools operate only on explicitly authorized customer connections, enabling agents to safely read and write against live third-party systems.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables PTZ camera control with gimbal positioning, snapshots, and AI visual analysis for OBSBOT and UVC cameras. Supports autonomous scanning patterns and integrates with vision-language models for real-time camera analysis.71MIT
- AlicenseAqualityDmaintenanceEnables AI agents to control serial port devices (modems, instruments, embedded boards) via MCP tools for listing ports, connecting, and sending/receiving commands.31MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to interact with an ArduPilot vehicle in real-time via MAVLink, including reading state, inspecting and changing parameters, switching flight modes, diagnosing arming failures, and gated arming/disarming.30 PyPI5MIT
- AlicenseNot gradedqualityDmaintenanceEnables LLM agents to control and monitor a Unitree Go2 robot through MCP tools, including live telemetry, navigation, camera feeds, and waypoint missions.Apache 2.0