You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A [Model Context Protocol](https://modelcontextprotocol.io/introduction)(MCP) server for the Geargrafx emulator, enabling AI-assisted debugging and development of TurboGrafx-16 / PC Engine / SuperGrafx games.
3
+
A [Model Context Protocol](https://modelcontextprotocol.io/introduction) server for the Geargrafx emulator, enabling AI-assisted debugging and development of TurboGrafx-16 / PC Engine / SuperGrafx games.
4
4
5
-
This server provides comprehensive tools for game development, rom hacking, reverse engineering, and debugging through standardized MCP protocols compatible with AI agents like GitHub Copilot, Claude Desktop, ChatGPT and others.
5
+
This server provides tools for game development, rom hacking, reverse engineering, and debugging through standardized MCP protocols compatible with AI agents like GitHub Copilot, Claude, ChatGPT and others.
6
6
7
7
## Features
8
8
@@ -114,30 +114,10 @@ The Geargrafx MCP server supports two transport modes:
114
114
115
115
The default mode uses standard input/output for communication. The emulator is launched by the AI client and communicates through stdin/stdout pipes.
116
116
117
-
**Advantages:**
118
-
- Automatic lifecycle management (client starts/stops the emulator)
119
-
- No network configuration needed
120
-
- More secure (no open ports)
121
-
122
-
**Use cases:**
123
-
- VS Code GitHub Copilot
124
-
- Claude Desktop
125
-
- Any MCP client with process management
126
-
127
117
### HTTP Transport
128
118
129
119
The HTTP transport mode runs the emulator with an embedded web server on `localhost:7777/mcp`. The emulator stays running independently while the AI client connects via HTTP.
130
120
131
-
**Advantages:**
132
-
- Persistent emulator instance
133
-
- Can connect/disconnect AI clients without restarting
134
-
- Manual emulator control while debugging with AI
135
-
136
-
**Use cases:**
137
-
- Advanced debugging workflows
138
-
- Multiple AI client connections
139
-
- Manual emulator testing with AI assistance
140
-
141
121
## Quick Start
142
122
143
123
### STDIO Mode with VS Code
@@ -164,25 +144,21 @@ The HTTP transport mode runs the emulator with an embedded web server on `localh
164
144
-**Linux:**`/path/to/geargrafx`
165
145
-**Windows:**`C:/path/to/geargrafx.exe`
166
146
167
-
3.**Restart VS Code** for settings to take effect
147
+
3.**Restart VS Code**may be necessary for settings to take effect
168
148
169
149
4.**Open GitHub Copilot Chat** and start debugging:
170
150
- The emulator will auto-start with MCP server enabled
171
151
- Load a game ROM
172
152
- Start chatting with Copilot about the game state
153
+
- You can add context from "MCP Resources" if needed
173
154
174
155
### STDIO Mode with Claude Desktop
175
156
176
157
#### Option 1: Desktop Extension (Recommended)
177
158
178
159
The easiest way to install Geargrafx MCP server on Claude Desktop is using the MCPB package:
179
160
180
-
1.**Download the latest MCPB package** for your platform from the [releases page](https://github.com/drhelius/geargrafx/releases):
181
-
-**macOS Intel:**`geargrafx-macos-x64.mcpb`
182
-
-**macOS Apple Silicon:**`geargrafx-macos-arm64.mcpb`
1.**Download the latest MCPB package** for your platform from the [releases page](https://github.com/drhelius/geargrafx/releases).
186
162
187
163
2.**Install the extension**:
188
164
- Open Claude Desktop
@@ -191,7 +167,7 @@ The easiest way to install Geargrafx MCP server on Claude Desktop is using the M
191
167
- In the Extension Developer section, click **Install Extension…**
192
168
- Select the downloaded `.mcpb` file
193
169
194
-
3.**Start debugging**: The extension is now available in your conversations. The emulator will automatically launch when Claude needs to access debugging tools.
170
+
3.**Start debugging**: The extension is now available in your conversations. The emulator will automatically launch when the tool is enabled.
195
171
196
172
#### Option 2: Manual Configuration
197
173
@@ -221,8 +197,6 @@ If you prefer to build from source or configure manually:
221
197
222
198
2.**Restart Claude Desktop**
223
199
224
-
3.**Start debugging**: The emulator will launch when Claude needs to access debugging tools
225
-
226
200
### HTTP Mode
227
201
228
202
1.**Start the emulator manually** with HTTP transport:
@@ -250,18 +224,6 @@ If you prefer to build from source or configure manually:
250
224
}
251
225
```
252
226
253
-
Or User Settings JSON:
254
-
```json
255
-
{
256
-
"github.copilot.chat.mcp.servers": {
257
-
"geargrafx": {
258
-
"type": "http",
259
-
"url": "http://localhost:7777/mcp"
260
-
}
261
-
}
262
-
}
263
-
```
264
-
265
227
3.**Or configure Claude Desktop**:
266
228
```json
267
229
{
@@ -276,7 +238,7 @@ If you prefer to build from source or configure manually:
276
238
277
239
4.**Restart your AI client** and start debugging
278
240
279
-
> **Note:** The MCP HTTP Server must be running standalone before connecting the AI client. Default port is 7777 (configurable with `--mcp-http-port`). In HTTP mode, the emulator stays running even when the AI client disconnects. You can manually load games and interact with the GUI while the AI assistant connects as needed.
241
+
> **Note:** The MCP HTTP Server must be running standalone before connecting the AI client.
280
242
281
243
## Usage Examples
282
244
@@ -311,75 +273,25 @@ Once configured, you can ask your AI assistant:
311
273
312
274
In addition to tools, the MCP server provides documentation resources that AI assistants can access to better understand the PC Engine / TurboGrafx-16 hardware and programming.
313
275
314
-
Resources are organized into categories and are automatically loaded when the server starts. They provide context and reference material for AI-assisted debugging and development.
276
+
MCP clients usually offer reources in the "Add context..." section of the chat interface. You may need to manually add them when you think they are relevant.
315
277
316
278
### Hardware Documentation Resources
317
279
318
280
Complete technical reference documentation for all PC Engine / TurboGrafx-16 hardware components:
319
281
320
282
-**HuC6280 CPU — 8-bit CMOS Microprocessor** (`geargrafx://hardware/huc6280_cpu`)
321
-
- 65C02-compatible core architecture
322
-
- CPU registers (A/X/Y/S/P/PC) and status flags
323
-
- Memory Management Unit (MMU) with 8×8KB page mapping
324
-
- Interrupt controller, 7-bit timer, I/O ports
325
-
- Clock speeds (1.79MHz/7.16MHz switchable)
326
-
327
283
-**HuC6280 Instruction Set Reference** (`geargrafx://hardware/huc6280_instructions`)
328
-
- Complete instruction set with all 65C02 base opcodes
- RAM configuration, ROM banking, CD-ROM/Arcade Card extensions
359
-
360
-
### How Resources Work
361
-
362
-
Resources are read-only documentation that AI assistants can reference during conversations:
363
-
364
-
1.**Automatic Loading**: Resources are loaded when the MCP server starts
365
-
2.**Context Enhancement**: AI assistants can retrieve resources to understand hardware specifics
366
-
3.**Format**: Resources are provided in Markdown format for easy reading
367
-
4.**URIs**: Each resource has a unique URI like `geargrafx://category/resource_id`
368
-
369
-
### Accessing Resources
370
-
371
-
Resources are accessed through the MCP protocol's resource capabilities:
372
-
373
-
-`resources/list` - List all available resources
374
-
-`resources/read` - Read the content of a specific resource
375
-
376
-
AI clients automatically handle resource retrieval, so you typically don't need to manually request them. The AI assistant will fetch relevant resources when needed to answer your questions or provide better debugging assistance.
377
289
378
-
## How It Works
290
+
## How MCP Works in Geargrafx
379
291
380
292
- The MCP server runs **alongside** the GUI in a background thread
381
-
- The emulator GUI remains fully functional (you can play/debug normally)
382
-
- Commands from the AI are queued and executed on the main thread
293
+
- The emulator GUI remains fully functional (you can play/debug normally while using MCP)
294
+
- Commands from the AI are queued and executed on the GUI thread
383
295
- Both GUI and MCP share the same emulator state
384
296
- Changes made through MCP are instantly reflected in the GUI and vice versa
385
297
@@ -389,8 +301,8 @@ AI clients automatically handle resource retrieval, so you typically don't need
389
301
```
390
302
┌─────────────────┐ ┌──────────────────┐
391
303
│ VS Code / │ stdio │ Geargrafx │
392
-
│ Claude Desktop │◄──────────────────►│ MCP Server │
393
-
│ (AI Client) │ pipes │ (Background) │
304
+
│ Claude Desktop │◄──────────────────►│ MCP Server │
305
+
│ (AI Client) │ pipes │ (background) │
394
306
└─────────────────┘ └──────────────────┘
395
307
│ │
396
308
└───► Launches ►────────────────────────┘
@@ -408,7 +320,7 @@ AI clients automatically handle resource retrieval, so you typically don't need
408
320
┌─────────────────┐ ┌──────────────────┐
409
321
│ VS Code / │ HTTP (port 7777) │ Geargrafx │
410
322
│ Claude Desktop │◄──────────────────►│ MCP HTTP Server │
Copy file name to clipboardExpand all lines: README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -109,7 +109,7 @@ Don't hesitate to report bugs or ask for new features by [opening an issue](http
109
109
- Supported platforms (standalone): Windows, Linux, BSD and macOS.
110
110
- Supported platforms (libretro): Windows, Linux, macOS, Raspberry Pi, Android, iOS, tvOS, PlayStation Vita, PlayStation 3, Nintendo 3DS, Nintendo GameCube, Nintendo Wii, Nintendo WiiU, Nintendo Switch, Emscripten, Classic Mini systems (NES, SNES, C64, ...), OpenDingux, RetroFW and QNX.
111
111
- Full debugger with just-in-time disassembler, CPU breakpoints, memory access breakpoints, code navigation (goto address, JP JR and JSR double clicking), debug symbols, automatic labels, memory editor, PSG inspector and video viewer including registers, tiles, sprites, backgrounds, CD-ROM sub-systems and both VDCs in SuperGrafx mode.
112
-
- MCP server for AI-assisted debugging with GitHub Copilot, Claude Desktop, ChatGPT ..., exposing tools for execution control, memory inspection, hardware status, and more.
112
+
- MCP server for AI-assisted debugging with GitHub Copilot, Claude, ChatGPT and similar, exposing tools for execution control, memory inspection, hardware status, and more.
113
113
- Windows and Linux *Portable Mode*.
114
114
- ROM loading from the command line by adding the ROM path as an argument.
115
115
- ROM loading using drag & drop.
@@ -148,7 +148,7 @@ Options:
148
148
149
149
### MCP Server
150
150
151
-
Geargrafx includes a [Model Context Protocol](https://modelcontextprotocol.io/introduction) (MCP) server that enables AI-assisted debugging through AI agents like GitHub Copilot, Claude Desktop, ChatGPT... The server provides tools for execution control, memory inspection, breakpoints, disassembly, hardware status, sprite viewing, and more.
151
+
Geargrafx includes a [Model Context Protocol](https://modelcontextprotocol.io/introduction) (MCP) server that enables AI-assisted debugging through AI agents like GitHub Copilot, Claude, ChatGPT and similar. The server provides tools for execution control, memory inspection, breakpoints, disassembly, hardware status, sprite viewing, and more.
152
152
153
153
For complete setup instructions and tool documentation, see [MCP_README.md](MCP_README.md).
0 commit comments