Token导航 LogoToken导航TokenDH.com
Pcsx2 MCP logo
开发工具未说明官方级别未说明来源级核验

Pcsx2 MCP

MCP Server

PCSX2-MCP是一个为PS2模拟器PCSX2提供调试功能的工具,允许通过AI编码助手控制模拟器,设置断点、读取寄存器、反汇编MIPS代码等。

工具数

30

提示词数

0

GitHub Stars

8

资源数

0
调试工具JavaScriptClaudeClaude DesktopClaudeVS Code

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

hkmodd

提供方

hkmodd

最后核验

2026/5/17 20:20

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

PCSX2-MCP

PCSX2改装及MCP服务器

通过AI编码助手控制PS2模拟器。 设置断点、读取寄存器、反汇编MIPS、检查内存——所有这些都是通过MCP工具完成的。
┌─────────────┐    stdio (MCP)    ┌─────────────────────┐    TCP:21512    ┌─────────────────┐
│ AI Assistant │ ◄──────────────► │  pcsx2-mcp-server   │ ◄────────────► │  PCSX2 Emulator │
│ (Antigravity │                  │  (Node.js bridge)    │                │  + DebugServer   │
│  Claude etc) │                  │                      │ ◄────────────► │  + Pine IPC      │
└─────────────┘                  └─────────────────────┘    TCP:28011    └─────────────────┘

______________________________________________________________________

⚠️ 存储库与发布版——先读一下

此git仓库不包含完整的PCSX2源代码。 我们只提供修改的来源,以避免浪费存储空间上传1GB的上游代码。
此Git RepoGitHub发布(zip)
目的仅源代码准备运行包
PCSX2二进制文件❌ 不包括✅ 预建 pcsx2-qt.exe +所有DLL
PCSX2完整源代码❌ 不包括在内(见 上游)❌ 不包括在内
DebugServer补丁pcsx2-plugin/DebugServer.cpp + .h✅ 已包含(已编译)
MCP服务器源pcsx2-mcp-server/src/✅ 预建 dist/ + node_modules/
安装脚本setup-mcp.bat✅ 包括

只想使用它吗? → 下载 最新版本 拉链。一切都是预先构建的。

想要修改或重建吗? → 克隆此仓库,然后按照以下步骤操作 从源头构建 在......下面

______________________________________________________________________

快速入门(3个步骤)

1.下载

获取最新版本 --把拉链拉到任何地方。

2.设置

setup-mcp.bat --它检查Node.js并为您编写MCP配置。

需要 ≥ 18. 安装脚本会告诉你它是否丢失。

3.使用

  1. 发射 pcsx2-qt.exe 从提取的文件夹中
  2. 加载PS2游戏(ISO或光盘)
  3. 重启你的人工智能助手(反重力/克劳德桌面)
  4. 问: *“连接到PCSX2并向我显示线程列表”*

就是这样!你的AI助手现在已经 30个调试工具 对于PS2。

______________________________________________________________________

手动MCP配置

如果 setup-mcp.bat 不起作用或您想手动配置:

Antigravity / Gemini

编辑 ~/.gemini/antigravity/mcp_config.json:

{
  "mcpServers": {
    "pcsx2": {
      "command": "node",
      "args": ["
/pcsx2-mcp-server/dist/index.js"],
      "disabled": false
    }
  }
}

Claude Desktop

编辑 %APPDATA%\Claude\claude_desktop_config.json:

{
  "mcpServers": {
    "pcsx2": {
      "command": "node",
      "args": ["
/pcsx2-mcp-server/dist/index.js"]
    }
  }
}

VS Code (Copilot / Continue.dev)

创建 .vscode/mcp.json 在您的项目中:

{
  "servers": {
    "pcsx2": {
      "command": "node",
      "args": ["
/pcsx2-mcp-server/dist/index.js"]
    }
  }
}

______________________________________________________________________

里面有什么

DebugServer(内置于PCSX2中)

注入PCSX2的自定义TCP服务器,用于监听 端口21512。当模拟器启动时,您将看到:

[DebugServer] Listening on 127.0.0.1:21512

MCP服务器(Node.js网桥)

将MCP工具调用转换为DebugServer TCP命令。还支持 松树IPC (端口28011)作为基本存储器R/W和保存状态的回退。

______________________________________________________________________

全部30个工具

连接和状态

工具说明
pcsx2_connect连接到PCSX2(自动检测DebugServer或Pine)
pcsx2_status连接类型+仿真器状态

记忆

工具说明
pcsx2_read_memory读取N个字节作为十六进制转储
pcsx2_write_memory将十六进制数据写入地址
pcsx2_read_string读取以null结尾的字符串
pcsx2_find_pattern搜索十六进制模式(?? 通配符)
pcsx2_memory_diff快照+差异内存区域

寄存器

工具说明
pcsx2_read_registers全部7个类别(GPR、CP0、FPU、VU…),全128位
pcsx2_write_register按类别+索引写入寄存器

反汇编

工具说明
pcsx2_disassemble地址处的本地MIPS反汇编
pcsx2_evaluate计算表达式: v0 + 0x100, gp - 4

断点和观察点

工具说明
pcsx2_set_breakpoint使用可选条件+描述设置BP
pcsx2_remove_breakpoint按地址删除
pcsx2_list_breakpoints列出所有条件/状态
pcsx2_set_watchpoint观看读/写/访问/更改
pcsx2_remove_watchpoint移除观察点
pcsx2_list_watchpoints列出点击次数
pcsx2_clear_all_breakpoints删除所有断点+观察点

执行控制

工具说明
pcsx2_step第一步说明
pcsx2_step_over跳过日航/日航电话
pcsx2_continue恢复执行
pcsx2_pause停止模拟器

系统

工具说明
pcsx2_get_threads列出EE/IOP BIOS线程
pcsx2_get_modules列出加载的IOP模块
pcsx2_get_backtrace调用堆栈遍历——入口点、PC、堆栈指针、帧大小
pcsx2_game_info游戏名称/ID/版本(Pine)
pcsx2_save_state将状态保存到插槽0-9(Pine)
pcsx2_load_state从插槽加载状态(Pine)

PS2恢复集成

工具说明
ps2recomp_lookup_function按地址或姓名进行搜索覆盖
ps2recomp_list_overrides列出所有函数重写

______________________________________________________________________

示例工作流程

逆向工程功能

> "Connect to PCSX2"
> "Disassemble 40 instructions at 0x001000E0"
> "Set breakpoint at 0x001000E0 with condition v0 == 5"
> "Continue and wait for breakpoint"
> "Read registers"
> "Read 256 bytes at the address in a0"

使用差分查找内存值

> "Take a memory snapshot of 0x200000, size 4096"
  (do something in the game)
> "Diff the snapshot to find changes"

使用调用堆栈调试崩溃

> "Pause the emulator"
> "Get the backtrace"
> "Disassemble the function at entry 0x00125bf4"
> "Read registers to see what went wrong"

与PS2Recomp相比

> "Look up function at 0x0072e5c0 in PS2Recomp"
> "Set breakpoint at 0x0072e5c0 in PCSX2"
> "Step through and compare register values"

______________________________________________________________________

建筑

Git仓库

PCSX2-MCP/                       ← source code only, lightweight
├── pcsx2-plugin/
│   ├── DebugServer.cpp          ← our custom patch for PCSX2 (this is the only PCSX2 modification)
│   └── DebugServer.h
├── pcsx2-mcp-server/
│   ├── src/index.ts             ← MCP server source (TypeScript)
│   ├── src/debug-server-client.ts
│   ├── src/pine-client.ts
│   ├── package.json
│   └── tsconfig.json
├── README.md
├── setup-mcp.bat
└── package-release.ps1

GitHub发布(zip)

PCSX2-MCP-v1.0.0-win64/          ← ready to run, everything pre-built
├── pcsx2-qt.exe                 ← PCSX2 with DebugServer already compiled in
├── *.dll                        ← Qt + runtime dependencies
├── platforms/                   ← Qt platform plugins
├── resources/                   ← PCSX2 shaders, GameDB, etc
├── pcsx2-mcp-server/
│   ├── dist/index.js            ← compiled MCP server
│   └── node_modules/            ← pre-installed dependencies
├── source/
│   ├── DebugServer.cpp          ← patch source (GPL compliance)
│   └── DebugServer.h
├── setup-mcp.bat
└── README.md

______________________________________________________________________

从源头构建

Only needed if you want to modify PCSX2 or the MCP server

先决条件

组件需要
PCSX2Git、CMake≥3.22、Ninja、MSVC(Visual Studio 2022)、Qt 6
MCP服务器≥18(含npm)
所有MCP服务器依赖项(@modelcontextprotocol/sdk, zod, typescript)在声明中 package.json 并由自动安装 npm install确实如此 需要手动安装它们。

PCSX2

# 1. Clone the upstream PCSX2 source (we don't include it in this repo to save space)
git clone https://github.com/PCSX2/pcsx2.git pcsx2-src
cd pcsx2-src

# 2. Copy our DebugServer patch into the PCSX2 source tree
cp ../pcsx2-plugin/DebugServer.cpp pcsx2/DebugTools/
cp ../pcsx2-plugin/DebugServer.h pcsx2/DebugTools/

# 3. Add to CMakeLists.txt (in pcsx2/DebugTools/)
# Add DebugServer.cpp and DebugServer.h to the source list

# 4. Build with CMake + Ninja + MSVC
cmake -G Ninja -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --target pcsx2-qt

MCP服务器

cd pcsx2-mcp-server

# Install all dependencies (MCP SDK, Zod, TypeScript, etc.)
npm install

# Compile TypeScript → dist/index.js
npm run build

______________________________________________________________________

故障排除

问题修复
“没有Qt平台插件”确保 platforms/qwindows.dll 存在于旁边 pcsx2-qt.exe
DebugServer未侦听检查PCSX2控制台是否 [DebugServer] Listening on 127.0.0.1:21512
工具中的“无连接”呼叫 pcsx2_connect 首先
Pine工具失败启用Pine IPC:PCSX2设置→ 高级→ 启用Pine IPC
断点不会触发游戏必须正在运行(不在BIOS/菜单中)

______________________________________________________________________

许可证

  • PCSX2:GPL-3.0(与 上游)
  • DebugServer插件:GPL-3.0(衍生作品)
  • MCP服务器:MIT

GitHub版本包括一个预构建的PCSX2二进制文件(GPL-3.0)。我们修改的完整来源见 pcsx2-plugin/ (此仓库)并捆绑在发布压缩包中 source/未经修改的PCSX2源可在以下网址获得 .

目录标签

目录标签

调试工具JavaScriptClaudePS2模拟器本地部署MIPS反汇编内存操作断点调试

支持客户端

Claude DesktopClaudeVS Code

接入字段

传输方式(transport,传输协议)

未说明

鉴权方式(authType,认证方式)

none

工具数量(toolCount,工具数)

30

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

未说明none部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP