Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions docs/components/manager.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ ModAVD 0.36.0 起包里带两个管理程序,源码在 [ModAVDManager](https:/
双击包根的 `ModAVD.exe`:起一个只听 127.0.0.1 的本地服务,再用 Edge 的应用模式开一个窗口(Windows 10 / 11 自带 Edge);找不到 Edge 时用默认浏览器。页面内嵌在程序里,不联网。

- 功能:实例卡片(在线时有画面缩略图)、开关机(带进度)、新建、设置、删除、电脑检查、活动面板、画面查看(点击即点按,返回 / 主页 / 最近任务)、日志、安装 APK、打开目录;浅色 / 深色 / 跟随系统。管理器 0.4.0 起还有[按应用走代理](./app-proxy)。
- 管理器开机一律带窗口;无头开机用命令行或 MCP。无头运行的实例也能在这里关机。
- 一个根目录只开一个服务,再双击只是把窗口重新打开;日志在 `<根>\logs\modavd-ui.log`。
- 关掉窗口后,等正在跑的任务做完再退出。

Expand All @@ -30,17 +31,18 @@ modavd [--root <目录>] [--json] [--quiet] [--verbose] <命令> [参数]
| `create [--index N] [--title T] [--memory 6G] [--cpu N] [--data-gb N] [--fps 30\|60] [--resolution 1080\|720] [--no-bridge]` | 新建。默认带 arm64 执行桥,第一次开机时装上 |
| `set <i> [--title T] [--memory M] [--cpu N] [--fps F] [--resolution 1080\|720] [--data-gb N]` | 修改,下次开机生效。`--data-gb` 只能改大,游戏数据不动 |
| `delete <i> --yes` | 删除已关机的实例,连同游戏数据 |
| `start <i> [--window] [--timeout 300] [--no-bridge]` | 开机,等开完并做完开机后的设置 |
| `start <i> [--window \| --headless] [--timeout 300] [--no-bridge]` | 开机,默认无头;`--window` 带窗口,`--headless` 明确要求无头。等开完并做完开机后的设置 |
| `stop <i> [--force]`、`stop --all` | 关机:先让安卓正常关机,不成再 sync + kill;`--force` 是 sync + 强杀 |
| `restart <i> [--window] [--timeout 300] [--force] [--no-bridge]` | 关机再开机 |
| `bridge <i> install\|uninstall\|verify` | 装、卸、检查 arm64 执行桥 |
| `proxy <i> [on\|off\|test] [--server URL\|auto] [--add 包名] [--remove 包名] [--apps 包名]` | 管理器 0.4.0 起:[按应用走代理](./app-proxy),名单里的应用走代理,其余直连 |
| `check [--memory M]` | 开机前的电脑检查 |
| `window <i> show\|hide`、`install <i> <apk>`、`shell <i> <命令>`、`adb <i> -- <参数>` | 窗口、装 APK、客体命令、adb 透传 |
| `window <i> show\|hide` | 显示 / 隐藏带窗口开机的实例;无头实例没有窗口 |
| `install <i> <apk>`、`shell <i> <命令>`、`adb <i> -- <参数>` | 装 APK、客体命令、adb 透传 |
| `servers`、`version`、`mcp`、`help [命令]` | |

- `<i>` 写成 `3` 或 `mas_3`(0–9,5 除外);内存写成 `6144`、`6144M` 或 `6G`,只有 3 / 4 / 5 / 6 GB 四档,核数 2 / 4 / 6,帧率 30 / 60。
- 根目录:`--root`,没给就用环境变量 `MODAVD_ROOT`,再没有就用 `modavd.exe` 所在目录或它的上一级。
- 运行中不能切换带窗口 / 无头;先关机,再按需要的方式开机。`--window` 和 `--headless` 不能同时给。0.3.0 起没有 `restart` 命令,要重启就先 `stop` 再 `start`。
- adb 只走根目录的私有 server(`mas-avd.json` 的 `adbServerPort`),不碰默认的 5037。
- 关机先 sync 再关,不会弄出 0 字节的文件。

Expand Down
8 changes: 5 additions & 3 deletions docs/en/components/manager.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ Instance files and `mas-avd.json` are written the same way as in AUTO-MAS, so in
Double-click `ModAVD.exe` in the package root. It starts a local server that listens only on 127.0.0.1, then opens a window in Edge app mode (Edge comes with Windows 10 / 11); if Edge is not found, it uses the default browser. The page is embedded in the program and does not use the network.

- Features: instance cards (with a screen thumbnail when the instance is online), start and stop (with progress), create, settings, delete, PC check, activity panel, screen view (a click is a tap; Back / Home / Recents), logs, install APK, open folder; light / dark / follow system. Since manager 0.4.0 there is also the [per-app proxy](./app-proxy).
- The manager always starts instances with a window; use the CLI or MCP for headless starts. Headless instances can also be shut down here.
- One server runs per root folder; double-clicking again only reopens the window. The log is at `<root>\logs\modavd-ui.log`.
- After you close the window, it waits for the running tasks to finish before it exits.

Expand All @@ -30,17 +31,18 @@ modavd [--root <dir>] [--json] [--quiet] [--verbose] <command> [args]
| `create [--index N] [--title T] [--memory 6G] [--cpu N] [--data-gb N] [--fps 30\|60] [--resolution 1080\|720] [--no-bridge]` | Create an instance. It includes the arm64 execution bridge by default, installed on the first boot |
| `set <i> [--title T] [--memory M] [--cpu N] [--fps F] [--resolution 1080\|720] [--data-gb N]` | Change settings; they take effect on the next start. `--data-gb` can only grow the disk; game data is untouched |
| `delete <i> --yes` | Delete a shut-down instance together with its game data |
| `start <i> [--window] [--timeout 300] [--no-bridge]` | Start, then wait until boot is complete and the post-boot setup is done |
| `start <i> [--window \| --headless] [--timeout 300] [--no-bridge]` | Start headless by default; `--window` starts with a window and `--headless` explicitly requests headless mode. Wait until boot and post-boot setup are complete |
| `stop <i> [--force]`, `stop --all` | Shut down: first ask Android for a clean shutdown; if that fails, sync + kill. `--force` is sync + force-kill |
| `restart <i> [--window] [--timeout 300] [--force] [--no-bridge]` | Shut down, then start |
| `bridge <i> install\|uninstall\|verify` | Install, uninstall or check the arm64 execution bridge |
| `proxy <i> [on\|off\|test] [--server URL\|auto] [--add pkg] [--remove pkg] [--apps pkg]` | Since manager 0.4.0: the [per-app proxy](./app-proxy); the listed apps use the proxy, the others go direct |
| `check [--memory M]` | PC check before starting |
| `window <i> show\|hide`, `install <i> <apk>`, `shell <i> <command>`, `adb <i> -- <args>` | Window, install an APK, guest command, adb passthrough |
| `window <i> show\|hide` | Show or hide the window of an instance started with one; headless instances have no window |
| `install <i> <apk>`, `shell <i> <command>`, `adb <i> -- <args>` | Install an APK, guest command, adb passthrough |
| `servers`, `version`, `mcp`, `help [command]` | |

- Write `<i>` as `3` or `mas_3` (0–9, except 5). Write memory as `6144`, `6144M` or `6G`; there are only four levels: 3 / 4 / 5 / 6 GB. Cores are 2 / 4 / 6, frame rate 30 / 60.
- Root folder: `--root`; if it is not given, the environment variable `MODAVD_ROOT`; otherwise the folder containing `modavd.exe` or its parent.
- Windowed / headless mode cannot change while an instance is running; shut it down, then start it in the desired mode. `--window` and `--headless` are mutually exclusive. Since 0.3.0 there is no `restart` command; use `stop` followed by `start`.
- adb uses only the root folder's private server (`adbServerPort` in `mas-avd.json`) and never touches the default 5037.
- Shutdown syncs first and then stops, so it does not leave 0-byte files behind.

Expand Down
2 changes: 1 addition & 1 deletion docs/en/guide/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ ModAVD is an Android emulator based on the AOSP Android Emulator 37.2.10, built
The package includes a manager, `ModAVD.exe`, and a CLI, `tools\modavd.exe`, for creating instances and starting and stopping them. Automation tools such as [AUTO-MAS](https://github.com/AUTO-MAS-Project/AUTO-MAS) can also drive it and take care of instance orchestration and task flows.

- An Android emulator that runs on Windows today and uses the Windows Hypervisor Platform (WHPX) for hardware acceleration. More platforms are planned.
- It can run with a window as an ordinary emulator, or without one (headless). The manager, the CLI or a script starts it and shuts it down when done.
- It can run with a window as an ordinary emulator, or without one (headless). The manager starts it with a window; use the CLI, MCP or a script for headless starts. Either mode can be shut down in the manager or CLI when done.
- The emulator itself comes from Google's open-source [Android Emulator](https://android.googlesource.com/platform/external/qemu/). We changed QEMU, gfxstream (graphics streaming) and Crashpad (crash handling) in it, and the changes are published as patches.
- adb and the Android system images belong to Google and are covered by the Android Software Development Kit License Agreement. We cannot distribute them, so they are not in the Release. **补全组件** (Fetch components) in the manager (or `tools\modavd.exe components fetch`) downloads them from the official channels on your computer.

Expand Down
2 changes: 1 addition & 1 deletion docs/guide/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ ModAVD(魔改 AVD)是基于 AOSP Android Emulator 37.2.10 的安卓模拟器
包里带管理器 `ModAVD.exe` 和命令行 `tools\modavd.exe`,用来建实例、开机关机;也可以接入 [AUTO-MAS](https://github.com/AUTO-MAS-Project/AUTO-MAS) 这类自动化工具,由它们负责实例编排和任务流程。

- 一个安卓模拟器,现在跑在 Windows 上,用 Windows 虚拟机监控程序平台(WHPX)做硬件加速;以后计划支持更多平台。
- 可以开窗口当普通模拟器用,也可以不开窗口(无头)运行,由管理器、命令行或脚本拉起、用完关掉。
- 可以开窗口当普通模拟器用,也可以不开窗口(无头)运行。管理器开机带窗口;无头开机用命令行、MCP 或脚本,用完可以在管理器或命令行里关掉。
- 模拟器本体来自 Google 开源的 [Android Emulator](https://android.googlesource.com/platform/external/qemu/)。我们改了其中的 QEMU、gfxstream(图形转发)和 Crashpad(崩溃处理),改动以补丁形式公开。
- adb 和安卓系统镜像属于 Google,受《Android 软件开发套件许可协议》约束,不能由我们分发,所以不在 Release 里,由管理器里的「补全组件」(或 `tools\modavd.exe components fetch`)在你的电脑上从官方渠道下载。

Expand Down