mcp-remotetouch
Enables remote control of touchscreens on Linux devices by injecting tap, swipe, long press, and double tap events via SSH and the uinput system.
Allows for remote interaction with touchscreens on Raspberry Pi devices by sending touch event commands over an SSH connection to a virtual touch device.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-remotetouchconnect to my Raspberry Pi and tap the center of the screen"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
mcp-remotetouch
An MCP server for remotely controlling a touchscreen on any Linux device over SSH.
Injects tap, swipe, long press, double tap, and keyboard events directly into the device. The daemon auto-detects the touchscreen and screen resolution. Keyboard input is injected via a virtual keyboard device created through /dev/uinput. No installation required on the remote device — the Python daemon is sent via stdin over SSH, using only Python's standard library.
Architecture
Stdio mode (default)
Dev Machine Remote Linux Device
┌──────────────────┐ SSH (persistent) ┌──────────────────┐
│ MCP Server (TS) │ ──────────────────> │ Python daemon │
│ stdio transport │ JSON-line proto │ (stdlib only) │
│ │ <────────────────── │ │
│ touch_tap │ │ Auto-detect │
│ touch_swipe │ │ touchscreen │
│ touch_long_press │ │ ↓ │
│ touch_double_tap │ │ /dev/input/eventN│
│ key_press │ │ ↓ │
│ key_type │ │ /dev/uinput (kbd)│
│ touch_disconnect │ │ ↓ │
│ │ │ Linux Input │
└──────────────────┘ └──────────────────┘The daemon scans /proc/bus/input/devices to find the physical touchscreen (by checking INPUT_PROP_DIRECT and ABS_MT_POSITION_X), then injects events directly into it. This works reliably with containerized compositors (e.g., Torizon with Qt EGLFS) where virtual uinput devices may not be detected.
HTTP server mode (--server)
AI Agent (remote) ──HTTP/SSE──> Express + StreamableHTTPServerTransport
│
McpServer (per MCP session)
│
SshTouchSessionManager (shared)
│
SSH ──> Linux DeviceRelated MCP server: mcp-ssh
Prerequisites
Dev Machine
Node.js 18+
SSH client
Remote Device
Any Linux device with a touchscreen (Raspberry Pi, SBC, embedded system, etc.)
Python 3
Read/write access to
/dev/input/eventN(the touchscreen device)Write access to
/dev/uinput(for keyboard input — optional, touch works without it)
Add the user to the input group on the remote device:
sudo usermod -aG input $USERRe-login for the change to take effect. Alternatively, use the useSudo option.
Installation
npm install -g mcp-remotetouchOr run directly with npx:
npx mcp-remotetouchUsage
Add to your MCP client configuration (e.g. Claude Desktop's claude_desktop_config.json):
{
"mcpServers": {
"remotetouch": {
"command": "npx",
"args": ["mcp-remotetouch"],
"env": {}
}
}
}Screen resolution is auto-detected from the device. You can override it with REMOTETOUCH_SCREEN_WIDTH and REMOTETOUCH_SCREEN_HEIGHT if needed.
Environment Variables
Variable | Default | Description |
| (none) | SSH host of the remote device |
|
| SSH username |
|
| SSH port |
| (none) | Path to SSH private key |
| auto-detected | Screen width in pixels |
| auto-detected | Screen height in pixels |
|
| Run daemon with sudo |
Tools
touch_connect
Connect to a remote Linux device via SSH and start the touch daemon. Returns a session ID.
Parameter | Type | Description |
| string? | SSH host |
| string? | SSH username |
| number? | SSH port |
| string? | Path to SSH private key |
| number? | Screen width (auto-detected if omitted) |
| number? | Screen height (auto-detected if omitted) |
| boolean? | Run with sudo |
touch_tap
Tap at the given coordinates.
Parameter | Type | Description |
| string | Session ID |
| number | X coordinate |
| number | Y coordinate |
| number? | Tap duration (default: 50ms) |
touch_swipe
Swipe from (x1, y1) to (x2, y2).
Parameter | Type | Description |
| string | Session ID |
| number | Start X coordinate |
| number | Start Y coordinate |
| number | End X coordinate |
| number | End Y coordinate |
| number? | Swipe duration (default: 300ms) |
| number? | Number of interpolation steps |
touch_long_press
Long press at the given coordinates.
Parameter | Type | Description |
| string | Session ID |
| number | X coordinate |
| number | Y coordinate |
| number? | Press duration (default: 800ms) |
touch_double_tap
Double tap at the given coordinates.
Parameter | Type | Description |
| string | Session ID |
| number | X coordinate |
| number | Y coordinate |
key_press
Press a key with optional modifier keys. Requires /dev/uinput access on the remote device.
Parameter | Type | Description |
| string | Session ID |
| string | Key name (e.g. |
| string[]? | Modifier keys to hold (e.g. |
key_type
Type a string of text by simulating individual key presses. Requires /dev/uinput access on the remote device.
Parameter | Type | Description |
| string | Session ID |
| string | Text to type (e.g. |
touch_disconnect
Disconnect a session and clean up the remote daemon.
Parameter | Type | Description |
| string | Session ID |
touch_list_sessions
List all active sessions. No parameters.
HTTP Server Mode
Instead of running as a stdio MCP server, you can run mcp-remotetouch as an HTTP server that AI agents can connect to remotely over HTTP.
Starting the server
# Default: listen on 0.0.0.0:3000
npx mcp-remotetouch --server
# Custom port and host
npx mcp-remotetouch --server --port 8080 --host 127.0.0.1CLI arguments
Argument | Default | Description |
| (off) | Enable HTTP server mode |
|
| HTTP listen port |
|
| Bind address |
Without --server, the process runs in stdio mode (the default, backward-compatible behavior).
Workflow
A typical session from Claude Desktop:
touch_connect— connect to the remote devicetouch_tap/touch_swipe/touch_long_press/touch_double_tap— interact with the screenkey_press/key_type— send keyboard inputtouch_disconnect— end the session
Troubleshooting
Permission denied
The user on the remote device needs access to /dev/input/eventN. Either:
Add the user to the
inputgroup:sudo usermod -aG input $USER(re-login required)Or set
REMOTETOUCH_USE_SUDO=true
No physical touchscreen device found
The daemon could not find a touchscreen in /proc/bus/input/devices. Verify:
The device has a touchscreen connected and its driver is loaded
The device shows
INPUT_PROP_DIRECTand hasABS_MT_POSITION_Xcapability
Keyboard input not available
The key_press and key_type tools require write access to /dev/uinput. If keyboard is reported as unavailable:
Add a udev rule to grant access:
echo 'KERNEL=="uinput", GROUP="input", MODE="0660"' | sudo tee /etc/udev/rules.d/99-uinput.rules sudo udevadm control --reload-rules && sudo udevadm triggerEnsure the user is in the
inputgroup:sudo usermod -aG input $USER(re-login required)Or set
REMOTETOUCH_USE_SUDO=true
Touch tools continue to work even if /dev/uinput is not accessible.
SSH connection fails
Ensure SSH public key authentication is configured for the remote device (password authentication is not supported since the connection uses
BatchMode=yes)Verify the hostname and port are correct
License
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityDmaintenanceAn MCP server for computer automation that provides tools for screenshots, mouse actions, keyboard input, and drag-and-drop functionality. It supports cross-platform desktop interaction for both Linux (X11) and Windows environments.Last updated5362MIT
- Alicense-qualityDmaintenanceMCP server for remote Linux/Unix server management via SSH, enabling command execution, system monitoring, file operations, and diagnostics through natural language.Last updated1MIT
- Flicense-qualityDmaintenanceMCP server for Android device automation via ADB, enabling screen control, phone functions, app management, and device control.Last updated1
- Flicense-qualityDmaintenanceAn MCP server that enables viewing all screens and controlling mouse and keyboard, allowing clicks anywhere and text input.Last updated
Related MCP Connectors
A very simple remote MCP server that greets you, with a custom icon.
A MCP server built for developers enabling Git based project management with project and personal…
The MCP server for Azure DevOps, bringing the power of Azure DevOps directly to your agents.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/signal-slot/mcp-remotetouch'
If you have feedback or need assistance with the MCP directory API, please join our Discord server