Repository navigation
Releases
发版:ModAVDManager v0.7.0 (#121)
ModAVDManager v0.7.0
ModAVD.exe:76b27aa31e7b6baac0d45ab8df916c7a91a1d8ed13107e2c70e5b270032a197dtools/modavd.exe:556ca3a553bc2be1cab081fe22e53dd17c2042390ba19c9bb02318fa8cdbd77f
随 ModAVD 0.39.1 进包。下面是相对 v0.6.0 的改动。这一版主要是修新建、开机时管理器看不到私有 adb server、等满 300 秒才报超时的问题(ModAVD/ModAVD#172);另外「设置」里的「更新」能用了,Windows 上小块同步写盘也快了。
新增
-
「设置」里的「更新」能用了:
- 点「检查更新」找到新版以后,「更新」才能点。点了先弹框,写明会关掉几台在运行的实例。
- 确认以后,管理器下载、按清单核对、暂存好新版,这时实例照常运行(更新任务和别的任务互斥,这期间在管理器里开关不了实例);然后正常关掉所有在运行的实例,中间不再问。交给
tools\modavd.exe换上新版后,管理器自己退出;换好后自动重新打开管理器,提示「已更新到 X」,或者没换上的原因和建议。 - 有别的程序在用这个根目录的 modavd(比如
modavd mcp),或者有实例正在新建,就一台实例都不关,先提示你处理。 - 换不上(比如有程序占着文件)也照样重新打开管理器,下载好的新版留着,下次不用重下。换包的过程记在
logs\modavd-update.log。 - 新版要求更高版本的 AUTO-MAS 时,设置和确认框里会写出来,用 AUTO-MAS 的请先更新 AUTO-MAS;管理器换包时不查 AUTO-MAS 的版本,和用命令行装一样。
- 只在 Windows 上能用。这个功能从这一版才有,所以更新到这一版还是照原来的办法:在 AUTO-MAS 里更新,或者关掉所有实例和管理器,把新版整包覆盖解压到根目录。用 AUTO-MAS 的,以后也照旧可以在 AUTO-MAS 里更新,它用自己设置里的更新源和 CDK。
(ModAVDManager#115)
-
问题包(「收集问题信息」、
collect-info)多收几样东西,开机超时这类问题不用再另外找你要:- 管理器自己的日志:
logs\modavd-ui.log、modavd-bootwatch.log、adb-server.log,以及各自的.1,每份取最后 5 MB。 - 所有 adb.exe 进程(pid、启动时间、路径、命令行),以及 adb server 自己的日志(
%TEMP%\adb.log,设了ANDROID_ADB_LOG_PATH就取它)的最后 2 MB。 - Windows 保留的 TCP 端口(
netsh interface ipv4 show excludedportrange protocol=tcp的输出),并指出本目录的两个 adb server 端口、各实例的端口有没有落在保留范围里。
(ModAVD/ModAVD#172,ModAVDManager#112、ModAVDManager#113)
- 管理器自己的日志:
变更
-
Windows 上小块同步写盘快约 1.5 倍:
- 游戏下载资源时常常每写一小块就要求落盘一次(明日方舟每 7 KB 一次),每次都要等模拟器和电脑之间往返一趟,下载只有约 8 MB/s。开机时多给模拟器两个参数,缩短每一趟要等的时间:实测明日方舟下资源从约 7.5 MiB/s 提到约 11.5 MiB/s,模拟器占的 CPU 也从约 6 个核降到约 4 个。大块写盘和开机时间没有变慢。
- 「写完」的含义不变:数据进了电脑上的文件才算写完,模拟器被强行结束时能保住的东西和以前一样。
- 以前为了下载快,开机后会在客体里起一个守护(
mas-idlepoll.sh),密集小块写盘时让 vCPU 忙等(不超过电脑余下的核数);现在客体自己只在等读写时短暂忙等,就不再起它,下载时不再把那些核占满。 - 由 modavd(管理器、命令行、MCP)开机时生效,已经开着的实例要关机再开一次。想退回原来的做法,设环境变量
MODAVD_SYNC_IO=off再开机。
(ModAVD/ModAVD#35,ModAVDManager#116)
-
开机前不再查电脑内存:
- 以前空闲物理内存不到「实例内存 + 1.5 GB」就不让开机。可页面文件(虚拟内存)能补上物理内存的不足,这时其实开得了机,只是慢一些。现在「电脑检查」里没有「内存」这一项,也不再因为它挡开机。
- 模拟器真分不到实例的内存时,会自己退出并在日志里写明。管理器认出这种情况,就报「电脑内存不足,模拟器分不到实例的内存」,建议关闭部分程序、调小实例内存,或调大虚拟内存(页面文件);别的原因退出照旧报启动失败。实例卡片上的「调小内存」按钮改为在这种失败时出现。
(ModAVDManager#118)
-
为了少被杀毒软件误报(0.38.2 的
tools\modavd.exe被 Microsoft Defender 的机器学习规则误报过):- 两个 exe 带上版本信息,文件属性里能看到产品名 ModAVD、说明和版本号;不再去掉符号表。
- 复制配置信息、收集问题信息要查系统信息(WMI)时,隐藏启动的 PowerShell 不再从编码过的命令行(
-EncodedCommand)拿脚本,改为从标准输入读;收集到的内容和以前一样。 - 按应用走代理用的客体守护进程原样放进 exe,不再压缩。
- 两个 exe 因此各大了约 6 MB。会不会再被误报,要等这一版发出去才知道。
(ModAVDManager#107、ModAVDManager#108)
-
名字统一叫 ModAVD,不再叫「魔改 AVD」:日志、报错、命令行帮助、问题包和配置信息的标题都换了,问题包文件名从
魔改AVD问题信息-<时间>.zip改成ModAVD-问题信息-<时间>.zip。几处默认你在用 AUTO-MAS 的文字改成照实写:补全组件做完提示「可以新建实例了」;没找到 AUTO-MAS 时注明不用 AUTO-MAS 的不用管;复制配置信息里要你补的一行改成「怎么用的(自己玩 / AUTO-MAS 及版本 / MAA、M9A 等脚本)」。只改文字,行为不变。(ModAVDManager#111) -
NOTICE 和 README 里图标的说明改成:图标是 ModAVD 自己的,不在代码许可范围内。只改说明。(ModAVDManager#106)
-
macOS(Apple Silicon):
- 实例的新建、开机、关机、查看、修改设置和删除放开了,用官方的 ARM64 模拟器 37.2.13 和 Android 15 ARM64 镜像;执行桥、运行中显示 / 隐藏窗口、给实例装卸商店还不能用。
- 更新设置和组件下载源存在
~/Library/Application Support/ModAVD/,Mirror 酱 CDK 加密保存,密钥放在当前用户的钥匙串里;钥匙串锁着或没授权时保存失败,不弹授权框,也不改存明文。 - 复制配置信息(
report-config)和收集问题信息(collect-info)能用了:只收所选根目录的配置白名单和文本日志(每份最多 2 MiB,最多 8 份、共 20 MiB),过滤常见的凭据、路径和设备标识,不收截图和系统转储;分享前请自己再看一遍。 - 这一版还只出 Windows 包,Mac 版没有发布,完整打包和上机验收在后面的阶段。Windows 上不受影响。
(ModAVDManager#94、ModAVDManager#95、ModAVDManager#96)
修复
-
Windows 10.0.26300 上新建、开机要等满 300 秒才报失败:
- 这个版本的 Windows 上,系统 TCP 监听表里私有 adb server 那一行的状态常常不是「监听」。管理器以前只信这张表,就一直认定 adb server 没起来,每 20 秒重起一次,一条 adb 命令也不发;安卓明明开好了,也要等满 300 秒。
- 现在判断私有、脚本 adb server 在不在,先直接连它的端口问一句版本(adb 客户端本来第一句就问这个,对 server 没有影响),有应答就用;能连上、答的却不是 adb 时,才查监听表看端口被谁占着。
- 26300 上的情况我们这里复现不了,是按用户的日志和问题包修的。
(ModAVD/ModAVD#172,ModAVDManager#117)
-
私有 adb server 起不来、或者起来以后又没了,现在能看出原因:
- 私有、脚本两个 adb server 的日志写到
logs\adb-server.log,不再混进%TEMP%\adb.log;模拟器开机结束时自己调 adb、顺手起的 server 也写这里。超过 2 MB 时换成.1。 - server 起了却没在时限内监听上,或者起来过又不见了(已经退出,还是还在但不再监听),管理器会报出来,附上这份日志的最后几行;同样的内容只报一次。
(ModAVD/ModAVD#172,ModAVDManager#113)
- 私有、脚本两个 adb server 的日志写到
-
安卓开好了、私有 adb 却连不上时,不再干等到 300 秒:
- 模拟器报告开机完成以后,每 10 秒替实例向私有 adb server 补登记一次。模拟器只在开机结束时登记那一次,server 要是之后才起来或者重启过,以前就再也看不到这台实例。
- 报告开机完成 60 秒后还连不上,就报「安卓已经开好了,但之后 N 秒里私有 adb 一直用不了」,带上 adb 日志的最后一行。等满总时限时也这么报,不再说「安卓没有启动完成」。
(ModAVD/ModAVD#172,ModAVDManager#113)
-
补全组件时,把解好的目录挪进
sdk遇到拒绝访问、文件被占用(多半是安全软件在扫刚写出的文件),先重试 30 秒,还不行就复制过去,不再直接失败。(ModAVD/ModAVD#172,ModAVDManager#113) -
打开诊断模式时,偶尔会在日志采集还没切换过去时就报告已经打开;现在等切换完成才返回。(ModAVDManager#109)
给调用方(AUTO-MAS)
protocol还是 2:没有删命令、参数和--json字段,已有错误码、退出码的含义不变;加了错误码insufficient_memory和退出码 10,check少了内存一项(见下)。调用方不用改,不认识退出码 10 的按一般失败处理就行。- 新错误码
insufficient_memory(退出码 10):- 要开机的命令都可能报:
start、create(含--resume)的初始化开机、gles32 <i> on|off和playstore <i> install|uninstall里的冷启动;MCP 的start_instance、create_instance也一样。管理器接口回 502,和launch_failed一样。 - 什么时候报:emulator.exe 退出、qemu 也不在了,而且这次开机的模拟器日志(每次开机一个新文件)里有分不到内存的那几句:
Insufficient RAM free for launching emulator、cannot set up guest memory、Failed to allocate memory、PANIC: not enough memory。别的提前退出照旧是launch_failed(退出码 7)。带不带--json都一样。 error.message是「ModAVD 实例 N 启动失败:电脑内存不足,模拟器分不到实例的内存(emulator.exe 退出码 X):」加模拟器日志的最后几行;error.advice是「请关闭部分程序、调小实例内存,或调大虚拟内存(页面文件)」,不附「下次开机补做设置」那句(模拟器已经不在了)。error.details和launch_failed时一样,没有reason:start带instance_status(一般是offline,看不准时是unknown)和qemu_running(一般是false),模拟器已经退出,所以没有boot_diag_dir;新建的初始化开机另带instance_exists,instance_status是create_failed。
- 要开机的命令都可能报:
- 开机前不再查内存:
- 以前:空闲物理内存不到「实例内存 + 1.5 GB」时,要开机的命令在拉起模拟器之前就报
precheck_failed(退出码 4,没有error.details.reason),消息是「电脑可用内存不足:实例内存 … GB,启动约需 … GB,当前可用 … GB」,建议「请关闭部分程序,或调小实例内存」;check(MCPcheck_host)的items里有一项id为memory的阻塞检查,不够时ready为false。 - 现在不会再因为内存报
precheck_failed;check的items里没有memory这一项,ready也不再因为内存为false。check --memory和 MCPcheck_host的memory_mb照收、不报错,但不再起作用。 - 以前靠
precheck_failed加消息里的「内存」认内存不足的,改认insufficient_memory。
- 以前:空闲物理内存不到「实例内存 + 1.5 GB」时,要开机的命令在拉起模拟器之前就报
- 等开机:模拟器已经报告安卓开机完成、私有 adb 却连不上时,60 秒后就报
timeout(退出码 6),不再等满总时限;错误码不变,消息改成「ModAVD 实例 N 的安卓已经开好了(模拟器报告开机完成),但之后 N 秒里私有 adb(端口 P)一直用不了」,可能带上 adb 日志的最后一行。 update install新加--after-pid、--reopen、--reopen-arg,给管理器的「更新」用,只能和install一起用;不给时和以前一样。交接结果写在.update\manager-result.json。AUTO-MAS 的更新器照旧用它自己的,两个更新器之间仍然没有共用的磁盘锁,和直接用modavd update时一样;管理器下载时自己开着,交给命令行以后命令行在跑,AUTO-MAS 5.8.0 起看到这些进程占着根目录就不换包。- 文字:日志、报错消息和命令行帮助里的「魔改 AVD」都换成 ModAVD,错误码、退出码不变;问题包文件名改成
ModAVD-问题信息-<时间>.zip。 - 私有、脚本 adb server 的日志改写到
logs\adb-server.log(modavd 起 server 时设ANDROID_ADB_LOG_PATH),不再写进%TEMP%\adb.log。 - 开机参数(只在 Windows 上):modavd 开机时在
-qemu后面多带-global virtio-blk-pci.ioeventfd=off和-acpitable file=…(实例目录里按核数生成的modavd-cst.aml;表写不了或读不出核数时只带前一个);设了MODAVD_SYNC_IO=off就都不带。只有 modavd 开机时才带,别的程序自己拉起模拟器时不会有。
下载与核对
用 Go 1.26.5、GOTOOLCHAIN=local 运行仓库里的 build.ps1,能编出相同的字节。单独下载的包里还有 Go 的许可原文和文件清单。请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.7.0-win-x64.zip -Algorithm SHA256。
单独下载的管理器不会自己更新,新版本要手动替换;ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录,覆盖整包里的文件。
English
Shipped in ModAVD 0.39.1. Changes since v0.6.0. This release mostly fixes creating and starting instances failing only after a full 300-second wait because the manager could not see its private adb server (ModAVD/ModAVD#172); in addition, "更新" (update) in "设置" (settings) now works, and small synchronous disk writes are faster on Windows.
New
-
"更新" (update) in "设置" (settings) now works:
- It becomes available once "检查更新" (check for updates) has found a new version. Clicking it first shows a dialog saying how many running instances will be stopped.
- Once you confirm, the manager downloads the new version, checks it against the manifest and stages it while instances keep running (the update task excludes other tasks, so instances cannot be started or stopped in the manager meanwhile); then it stops every running instance normally, without asking again. It hands over to
tools\modavd.exeto swap in the new version and exits; after the swap the manager is opened again and shows "已更新到 X" (updated to X), or why the new version was not swapped in and what to do. - If another program is using modavd in this root (such as
modavd mcp), or an instance is being created, no instance is stopped and you are asked to deal with that first. - If the swap fails (for example a program holds a file), the manager is still opened again and the downloaded version is kept, so it need not be downloaded again. The swap is logged in
logs\modavd-update.log. - When the new version needs a newer AUTO-MAS, the settings and the confirmation dialog say so; if you use AUTO-MAS, update it first. Like installing from the command line, the manager does not check the AUTO-MAS version when it swaps.
- Windows only. The feature is new in this release, so updating to this release still works the old way: update in AUTO-MAS, or stop all instances and the manager and extract the new full package over the root. If you use AUTO-MAS, you can keep updating in AUTO-MAS; it uses the update source and CDK in its own settings.
(ModAVDManager#115)
-
The problem package ("收集问题信息" (collect problem info),
collect-info) collects more, so problems such as start-up timeouts no longer need a second round of asking:- The manager's own logs:
logs\modavd-ui.log,modavd-bootwatch.log,adb-server.logand their.1files, the last 5 MB of each. - All adb.exe processes (pid, start time, path, command line), and the last 2 MB of the adb server's own log (
%TEMP%\adb.log, orANDROID_ADB_LOG_PATHwhen set). - The TCP ports Windows has reserved (the output of
netsh interface ipv4 show excludedportrange protocol=tcp), and whether the root's two adb server ports or any instance's ports fall in a reserved range.
(ModAVD/ModAVD#172, ...
- The manager's own logs:
发版:ModAVDManager v0.6.0 (#105)
ModAVDManager v0.6.0
ModAVD.exe:cb157a6b81958d78d69845d661fc0e6eae4fd6675a709ce3a42ae39f570d0ab5tools/modavd.exe:d80949e9535fc70cc2bab1af186cc1d4f873b669afc0b6b3ff2a8b6442bc27fa
随 ModAVD 0.39.0 进包。下面是相对 v0.5.0 的改动。这一版主要是适配 World of Airports 3.7.3(ModAVD/ModAVD#131)。
新增
-
按实例的实验开关「报告 GLES 3.2」:
- 有的游戏在清单里要求 GLES 3.2,比如 World of Airports 3.7.3。Google Play 按实例报的 OpenGL ES 版本判断兼容,ModAVD 报的是 3.1,商店就不让装。打开这个开关,实例改报 3.2,商店就放行。
- 只改报的版本,实际渲染仍是 3.1:走 Vulkan 的游戏能用,真要 GLES 3.2 渲染的应用会装得上、打不开。默认关,界面和命令帮助里都标着「实验」。遇到问题先把它关掉。
- 在实例的「更多操作」里点「开启 / 关闭报告 GLES 3.2(实验)」,或运行
modavd gles32 <编号> on|off|status。要冷启动一次(几分钟):原来关着的做完再关上,开着的照原来的方式开回来;冷启动后核对实例报的版本,对不上就报错。 - 实例要有执行桥:改的是执行桥带来的可写系统镜像覆盖层里的
/vendor/build.prop。没有执行桥的实例开不了;开着这个开关时不能卸执行桥,要先关掉它。 - 实例装着 Google Play 商店时,改完要到实例里 设置 → 应用 → Google Play 商店 → 存储,清除数据(账号不会退出),商店才会按新的版本重新判断。
(ModAVD/ModAVD#131,ModAVDManager#104)
-
开机时多挂一个 ARM 转译层补丁:
- API 34 r14 镜像自带的 Google ARM 转译层(
libndk_translation.so)把 AArch64 的 WFE、WFI、SEV、SEVL 这几条 HINT 指令当成未定义指令,用到它们的应用会闪退。新版 Unity(比如 World of Airports 3.7.3 用的 Unity 6)的自旋锁会用sevl; wfe,游戏启动约 2 秒就退出。按 ARM 规范这几条可以当空操作执行,补丁就把它们改成空操作;其余未定义指令照旧报错。 - 和客体 Vulkan 驱动补丁一样,补丁版是在你的电脑上从镜像自带的库生成的(放在根目录的
guest-patches\),不随包分发。两个补丁在同一次里挂上,zygote 只重启一次,开机不比原来多花时间。 - 只认 API 34 r14 镜像里的那一份转译层,别的版本不改,只记一条日志。ARM64 客体直接跑 ARM 代码,不套用。
- 这几条指令当空操作以后,用它们等待的自旋锁会一直空转,可能多占一点 CPU;World of Airports 主界面上没看到 CPU 被占满。
- 升级时已经开着的实例只检查、不挂,关机再开一次才生效。
- 开机进度和结果里原来写「客体 Vulkan 修复」的地方,改成「客体库补丁」。
(ModAVD/ModAVD#131,ModAVDManager#103)
- API 34 r14 镜像自带的 Google ARM 转译层(
变更
- 客体 Vulkan 驱动补丁多修一处:镜像自带的
libvulkan_enc.so在批量更新描述符时,一个模板条目连写几个相邻的绑定(Vulkan 规范允许这么写),后面几个绑定没写上,反而写到了数组外面。World of Airports 加载机场到 68% 时模拟器退出(宿主显卡报VK_ERROR_DEVICE_LOST),就是这个原因。只有开着批量描述符更新(VulkanBatchedDescriptorSetUpdate,默认开)时才走这条路。补丁版换了文件名,第一次由这一版开机时会在本机重新生成一次。(ModAVD/ModAVD#131,ModAVDManager#102) - 套不套客体库补丁,按实例自己的配置来定:实例的
config.ini没写abi.type时按 x86_64 处理。以前读不到或没写这一项时,会跳过 Vulkan 补丁,之后也不再补。ARM64 客体照旧不套用。(ModAVD/ModAVD#130,ModAVDManager#103) - 整理磁盘前要看数据盘所在卷的文件系统。系统没给出文件系统名时,现在按「读不到」报错并说明原因,错误码是
internal(退出码 1);以前报的是unsupported(退出码 4),提示里还会出现一个空的卷名。(ModAVD/ModAVD#142,ModAVDManager#101) - macOS(Apple Silicon):
components fetch能补全固定版本的 adb(平台工具 37.0.1)和 Android 15 Google APIs ARM64 系统镜像(r9),下载前显示对应的两份 Google 许可协议;components fetch --play-store和components import-playstore能从 Android 15 Google Play ARM64 镜像(r9,arm64-v8a-35_r09.zip)里准备好商店的五个文件。这一版还只出 Windows 包,Mac 版没有发布,Mac 上也还不能新建、开机,不能给实例装商店。Windows 上的组件和商店照旧是 Android 14(API 34)x86_64 r14,行为不变。(ModAVD/ModAVD#67、ModAVD/ModAVD#68、ModAVD/ModAVD#112、ModAVD/ModAVD#125,ModAVDManager#72、ModAVDManager#92)
给调用方(AUTO-MAS)
protocol还是 2:只加了命令和字段,没有删字段,已有命令、参数、字段和退出码的含义不变。调用方不用改。- 新命令
gles32 <i> on|off|status(实验):on、off会冷启动一次再核对,要几分钟;原来关着的做完再关上,开着的照原来的方式(带窗口或无头)开回来。status只读,实例要开着。--json的data:index、action、state(on、off,还没冷启动的是pending-on、pending-off)、enabled、prop(客体的ro.opengles.version)、restarted、stopped、notes、warnings。- 冷启动后实例报的版本和要的对不上,报
launch_failed(退出码 7),带不带--json都一样;成功时state就是要的on或off。 - 实例没有执行桥是
not_ready,error.details.reason为gles32_no_bridge;arm64 客体是unsupported(unsupported_guest);status碰上没开机的实例是unsupported(不带reason,和playstore status一样)。 - 和装卸执行桥、Google Play 商店共用一把锁:它们正在做时报
busy,error.details的reason为locked、lock为bridge。 - 开着这个开关的实例,
bridge <i> uninstall返回not_ready,要先gles32 <i> off。 - MCP 没有这个开关。
- 新字段,调用方照旧要容忍不认识的字段:
list、info的实例:gles32(bool),是mas-avd.json里instances.<i>.gles32的记录,不问客体。开着时,info的文字输出多一行。MCP 的list_instances、get_instance也带这个字段。components status --json的data.play_store:archive(可以导入的官方镜像压缩包名,Windows 上是x86_64-34_r14.zip)、download_bytes(这个压缩包的大小)、install_supported(这台电脑能不能给实例装、卸商店,Windows 上是true)。
- 开机:
start结果里的zygote_restarted、setup_pending,和进度里的vulkan_fix这一步,现在也包括 ARM 转译层补丁;名字和含义都没变(挂补丁会重启 zygote,前台开着应用或者正在装 APK 时推迟到下一次start或下次开机)。 - 客体 Vulkan 驱动补丁在宿主上的缓存换成了新文件名,不和 AUTO-MAS 自己那份(没有这次的修复)同名,互不覆盖。同一次开机里 AUTO-MAS 已经挂上它自己那份时,modavd 不替换,下次由 modavd 开机才换成新的。
下载与核对
用 Go 1.26.5、GOTOOLCHAIN=local 运行仓库里的 build.ps1,能编出相同的字节。单独下载的包里还有 Go 的许可原文和文件清单。请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.6.0-win-x64.zip -Algorithm SHA256。
单独下载的管理器不会自己更新,新版本要手动替换;ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录,覆盖整包里的文件。
English
Shipped in ModAVD 0.39.0. Changes since v0.5.0. This release is mostly about running World of Airports 3.7.3 (ModAVD/ModAVD#131).
New
-
Per-instance experimental switch "report GLES 3.2":
- Some games list GLES 3.2 in their manifest, World of Airports 3.7.3 among them. Google Play judges compatibility by the OpenGL ES version the instance reports; ModAVD reports 3.1, so the store refuses to install them. With this switch on, the instance reports 3.2 and the store lets them in.
- It only changes the reported version; rendering stays 3.1: games that use Vulkan work, while an app that really renders with GLES 3.2 installs but does not start. It is off by default and marked experimental in the manager and in the command help. If something goes wrong, turn it off first.
- Choose "开启 / 关闭报告 GLES 3.2(实验)" (turn reporting GLES 3.2 on / off, experimental) in the instance's "更多操作" (more actions) menu, or run
modavd gles32 <index> on|off|status. It boots the instance cold once (a few minutes): a stopped instance is stopped again afterwards, a running one comes back the way it ran. After the cold boot it checks the version the instance reports and fails on a mismatch. - The instance needs the execution bridge: the switch edits
/vendor/build.propin the writable system overlay the bridge brings. It cannot be turned on without the bridge, and while it is on the bridge cannot be uninstalled; turn the switch off first. - With the Google Play Store on the instance, afterwards go to Settings → Apps → Google Play Store → Storage in the instance and clear its data (the account stays signed in), so the store judges compatibility again against the new version.
(ModAVD/ModAVD#131, ModAVDManager#104)
-
A patch for the ARM translation layer is mounted at boot:
- Google's ARM translation layer in the API 34 r14 image (
libndk_translation.so) treats the AArch64 HINT instructions WFE, WFI, SEV and SEVL as undefined, so apps that use them crash. Spin locks in recent Unity (such as the Unity 6 in World of Airports 3.7.3) usesevl; wfe, and the game quits about 2 seconds after launch. The ARM specification allows these instructions to run as no-ops, and the patch makes them no-ops; every other undefined instruction still faults. - As with the guest Vulkan driver patch, the patched library is made on your computer from the image's own library (kept in the root's
guest-patches\) and is not shipped. Both patches are mounted together with one zygote restart, so booting takes no longer than before. - Only the translation layer of the API 34 r14 image is recognised; any other version is left alone with a line in the log. ARM64 guests run ARM code natively and are not patched.
- With these instructions as no-ops, spin locks that wait on them keep spinning and may use a little more CPU; on the World of Airports main screen the CPU was not seen to be maxed out.
- An instance that is already running when you upgrade is only checked, not patched; stop it and start it again.
- Boot progress and results that said "客体 Vulkan 修复" (guest Vulkan fix) now say "客体库补丁" (guest library patches).
(ModAVD/ModAVD#131, ModAVDManager#103)
- Google's ARM translation layer in the API 34 r14 image (
Changes
- The guest Vulkan driver patch fixes one more bug: in batched descriptor updates, when a single template entry writes several adjacent bindings (which the Vulkan specification allows), the image's
libvulkan_enc.sodid not write the later bindings and wrote past the array instead. This is why the emulator quit at 68% while World of Airports loaded an airport (the host GPU reportedVK_ERROR_DEVICE_LOST). The code path is used only with batched descriptor updates on (VulkanBatchedDescriptorSetUpdate, on by default). The patched library has a new file name and is made once more on this computer at the first boot with this release. (ModAVD/ModAVD#131, ModAVDManager#102) - Whether the guest library patches apply is decided from the instance's own configuration: an instance whose
config.inihas noabi.typecounts as x86_64. Previously, when that entry could not be read or was missing, the Vulkan patch was skipped and never applied later. ARM64 guests are still not patched. (ModAVD/ModAVD#130, ModAVDManager#103) - Compacting a disk first checks the file system of the volume that holds the data disk. When Windows returns no file system name, this is now reported as unreadable with the reason, with the error code
internal(exit code 1); it used to beunsupported(exit code 4), and the message showed an empty volume type. (ModAVD/ModAVD#142, ModAVDManager#101) - macOS (Apple Silicon):
components fetchcan fetch the pinned adb (platform-tools 37.0.1) and the Android 15 Google APIs ARM64 system image (r9), showing the two matching Google license agreements before downloading;components fetch --play-storeandcomponents import-playstorecan prepare the store's five files from the Android 15 Google Play ARM64 image (r9,arm64-v8a-35_r09.zip). This release still ships only the Windows package; there is no Mac release, and a Mac still cannot create or start instances or install the store into one. On Windows the components and the store are still Android 14 (API 34) x86_64 r14, and nothing changes. (ModAVD/ModAVD#67, ModAVD/ModAVD#68, ModAVD/ModAVD#112, ModAVD/ModAVD#125, ModAVDManager#72, ModAVDManager#92)
For callers (AUTO-MAS)
protocolis still 2: only a command and fields were added; no field was removed, and the meaning of exis...
发版:ModAVDManager v0.5.0 (#99)
ModAVDManager v0.5.0
ModAVD.exe:7679bca311222395513b88fb9935bd4fdd7086bc7e0f2d8045d1b1afe8695854tools/modavd.exe:2c7e337ac13e0489c17f3b9e6e77e39aa02ca806d4a1376a8b8b1aadf6d6000b
随 ModAVD 0.38.2 进包。下面是相对 v0.4.1 的改动。
新增
-
可选的 Google Play 商店:
- 「补全组件」下面多一项「同时补全 Google Play 商店服务(约 1.5 GB,可选)」,默认不勾。勾上后,同意许可协议时一起从 Google 官方下载 Play 版系统镜像,只取出商店要的五个文件放进
sdk\playstore\,下载的压缩包和解出的镜像用完就删。 - 手里已经有 Google 官方的镜像压缩包
x86_64-34_r14.zip或那五个文件的,点「使用我自己的文件…」导入,不用再下载。每个文件都核对大小和 SHA-256,认不出、对不上、缺文件的一律拒收,什么也不改,你的文件也不动。 - 新建的实例不带商店。要的话,在实例的「更多操作」里点「补全 Google Play 商店…」:会冷启动一次,开着的做完照原来的方式开回来,关着的做完再关上。装上以后同一处变成「移除 Google Play 商店…」。实例要有执行桥;装了商店的实例要先移除商店,才能卸执行桥。
- 装了商店的实例开机后,「更多操作」里有「复制 GSF ID」:复制这台的 GSF ID,到 https://www.google.com/android/uncertified/ 登记,解决登录时「设备未经 Play 保护机制认证」的提示。还没有 ID 时,开着网等一两分钟再试。
- 装到一半失败(比如空间不够)时,撤回这次放进去的文件;撤不干净的,实例标成「只装了一部分」,「补全」和「移除」都可以点。原来关着的实例,失败后也会关上。
- 命令行:
components fetch --play-store、components import-playstore <文件或文件夹>…、playstore <编号> install | uninstall | status | gsfid;components status多一行商店的五个文件。 - 商店不算必需组件,没有它不影响开机和 AUTO-MAS。查 Play Integrity 的游戏多半还是过不了。
(ModAVD/ModAVD#125,ModAVDManager#89、ModAVDManager#91)
- 「补全组件」下面多一项「同时补全 Google Play 商店服务(约 1.5 GB,可选)」,默认不勾。勾上后,同意许可协议时一起从 Google 官方下载 Play 版系统镜像,只取出商店要的五个文件放进
-
补全组件、收集问题信息做进了管理器:
- 「电脑检查」里组件一项没通过时,点「补全组件」:先选下载源(自动、googledownloads_cn、tencent、google 或自定义地址),读从这个下载源取到的许可协议全文,同意后才下载。每个组件显示进度、速度和剩余时间,可以取消;失败时写明原因,可以重试;做完自动重新检查。主页横幅上的「补全组件」也是这个对话框。
- 你同意的就是要下载的那份协议:下载时从同一个下载源取到的协议和你读过的不一样,就停下,什么也不下。
- 设置里多了「组件与问题反馈」:看组件状态;「收集问题信息」做完显示问题包在哪,可以在资源管理器里打开;「复制配置信息」复制到剪贴板。
- ModAVD 0.38.2 起包里不再带「补全组件.bat」「收集问题信息.bat」「复制配置信息.bat」,改在管理器里做,也可以运行
tools\modavd.exe components fetch、tools\modavd.exe collect-info。
(ModAVD/ModAVD#45,ModAVDManager#84)
-
记住组件下载源:
- 设置里「组件下载源」和更新源放在一起,选好就保存。按 Windows 用户存在
%LOCALAPPDATA%\ModAVD\components-settings.json。 - 管理器和
components fetch(不给--mirror、--mirror-url时)都用它;下载前那一行「下载源:」写明这次的源是参数给的、保存的设置、管理器里选的,还是默认。 - 命令行
components source [auto|googledownloads_cn|tencent|google]查看、修改。还没存过时,在控制台里运行components fetch会用编号问一次并记住;--json、--accept-license、管道或文件输入都不问、不保存。
(ModAVD/ModAVD#120,ModAVDManager#84)
- 设置里「组件下载源」和更新源放在一起,选好就保存。按 Windows 用户存在
-
诊断模式:在实例设置里打开「诊断模式」,或运行
modavd set <编号> --diagnostics on。默认关,日志只存在本机。- 开着时,这台实例的模拟器日志、logcat 和崩溃转储留近 30 天,开机失败现场留最新 20 个,用这台单独的 4 GiB 上限,不挤普通实例共用的 1 GiB。客体的日志缓冲区加大,客体内存最多多用 48 MiB。收集问题信息时,这台多收一些日志和现场。
- 卡片副标题标出「诊断模式」。所在盘剩余不到 20 GiB 时,改按普通规则清理,并提示一次。
- 关闭时立即按普通规则清掉多留的日志(管理器先告诉你要清多少,再让你确认),返回实际清了多少。
- 这些日志和现场可能带账号信息,发给别人之前请先看一眼。
(ModAVD/ModAVD#97、ModAVD/ModAVD#106,ModAVDManager#78)
-
无头运行的实例(命令行或 AUTO-MAS 开的,没有窗口)在卡片副标题上标「无头」,悬停有说明;可以在管理器里关机。(ModAVD/ModAVD#101,ModAVDManager#90)
变更
-
stop --all碰上正在新建、处在两次开机之间的实例(这时没有模拟器在跑),以前会漏掉它,新建随后接着开机。现在也把它算进去,取消这次新建,结果照旧标interrupted_create。单台stop的行为不变。(ModAVD/ModAVD#103,ModAVDManager#86) -
端口段
portBase(只有开发、测试用的根目录才会设):- 只能是 1100–49000 之间 100 的整数倍,而且不能是 5500:5500 段会被别的 adb server 自动扫描到,49100 及以上和 Windows 默认的临时端口重叠。默认的 20000 不变。
- 已经设成 5500 或 49100–65400 的根目录,照旧能看状态、关机,但不能再新建、开机;先关掉全部实例,再换一段。
- 收集问题信息时,用默认端口段的根目录不再把别的端口段里同编号的模拟器当成自己的。
(ModAVD/ModAVD#98,ModAVDManager#73)
-
问题包的隐私提示第一句改成「问题包只保存在本机,管理器和命令行都不会上传它。」,以前写的是「脚本不会上传」。(ModAVD/ModAVD#45,ModAVDManager#87)
-
macOS 平台层:进程、后台启动、文件锁和 TCP 端口,QEMU 归属核验和私有 adb 隔离,宿主资源和 ARM64 开机前检查,Android 15(API 35)ARM64 的实例配置和 Guest ANGLE。这一版还只出 Windows 包,Mac 版没有发布;Windows 上新建照旧是 Android 14(API 34),行为不变。(ModAVD/ModAVD#67、ModAVD/ModAVD#68、ModAVD/ModAVD#112,ModAVDManager#62、ModAVDManager#68、ModAVDManager#69、ModAVDManager#70、ModAVDManager#71)
给调用方(AUTO-MAS)
protocol还是 2:只加了命令、字段和错误原因,没有删字段,已有命令、参数和退出码的含义不变。- 新命令:
playstore <i> install|uninstall|status|gsfid、components source、components import-playstore;components fetch加--play-store;set加--diagnostics on|off。 components fetch不给--mirror、--mirror-url时,用用户在管理器或components source里保存的下载源,没存过才是自动。带--json或--accept-license时不问、不保存。- 新字段,调用方照旧要容忍不认识的字段:
list、info的实例:play_store、play_store_partial(bool);diagnostics(bool),开着时另有diagnostics_since。MCP 的list_instances也带诊断字段,MCP 不提供诊断开关。components status --json的data.play_store:商店的五个文件在不在,source是download还是import。商店不算必需组件,check和components status的组件结果不受它影响。components source --json的data:source、mirror、mirror_urls、configured。playstore <i> gsfid --json的data:index、decimal、hex。
error.details.reason的新取值:not_ready:playstore_files_missing(根目录还没有商店的五个文件)、no_bridge(实例没有执行桥)、no_gsf_id(还没有 GSF ID)。unsupported:unsupported_guest(arm64 客体装商店)。components_rejected(导入商店文件被拒,退出码 9):unknown_file、mismatch、incomplete。
- 装着商店(或只装了一部分)的实例,
bridge <i> uninstall返回not_ready,要先playstore <i> uninstall。 stop --all现在也会取消两次开机之间的新建(见上)。
下载与核对
用 Go 1.26.5、GOTOOLCHAIN=local 运行仓库里的 build.ps1,能编出相同的字节。单独下载的包里还有 Go 的许可原文和文件清单。请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.5.0-win-x64.zip -Algorithm SHA256。
单独下载的管理器不会自己更新,新版本要手动替换;ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录,覆盖整包里的文件。
English
Shipped in ModAVD 0.38.2. Changes since v0.4.1:
New
-
Optional Google Play Store:
- Under "补全组件" (download components) there is a new option, "同时补全 Google Play 商店服务" (also get the Google Play Store services, about 1.5 GB, optional), off by default. When ticked, accepting the license also downloads Google's official Play system image, takes out only the five files the store needs into
sdk\playstore\, and deletes the downloaded zip and the extracted image afterwards. - If you already have Google's official image zip
x86_64-34_r14.zipor the five files, import them with "使用我自己的文件…" (use my own files) instead of downloading. Every file's size and SHA-256 is checked; unknown, mismatching or missing files are refused and nothing is changed. Your files are left as they are. - New instances come without the store. To add it, choose "补全 Google Play 商店…" (add the Google Play Store) in the instance's "更多操作" (more actions) menu: it cold-boots once; a running instance comes back up the way it ran, a stopped one is stopped again. Once installed, the same item becomes "移除 Google Play 商店…" (remove). The instance needs the execution bridge; to uninstall the bridge from an instance with the store, remove the store first.
- On a booted instance with the store, "复制 GSF ID" (copy GSF ID) in the same menu copies the instance's GSF ID, to register at https://www.google.com/android/uncertified/ when sign-in says the device is not Play Protect certified. If there is no ID yet, stay online and try again in a minute or two.
- If an install fails halfway (for example out of space), it takes back what it put in; when it cannot take everything back, the instance is marked as partly installed and offers both add and remove. An instance that was stopped is stopped again after a failure.
- Command line:
components fetch --play-store,components import-playstore <file or folder>…,playstore <index> install | uninstall | status | gsfid;components statuslists the store's five files. - The store is not a required component; without it booting and AUTO-MAS work as before. Games that check Play Integrity will most likely still fail it.
(ModAVD/ModAVD#125, ModAVDManager#89, ModAVDManager#91)
- Under "补全组件" (download components) there is a new option, "同时补全 Google Play 商店服务" (also get the Google Play Store services, about 1.5 GB, optional), off by default. When ticked, accepting the license also downloads Google's official Play system image, takes out only the five files the store needs into
-
Component download and problem reports in the manager:
- When the component item of "电脑检查" (host check) fails, click "补全组件": first pick a download source (automatic, googledownloads_cn, tencent, google or your own addresses), read the full license text fetched from that source, and download only after you accept. Each component shows progress, speed and time left, and can be canceled; a failure says why and can be retried; when done, the check runs again. The "补全组件" on the home banner opens the same dialog.
- What you accept is what is downloaded: if the license fetched from the same source at download time differs from the one you read, it stops and downloads nothing.
- Settings gain "组件与问题反馈" (components and feedback): the component status; "收集问题信息" (collect problem info) shows where the problem package is and can open it in Explorer; "复制配置信息" (copy configuration info) copies it to the clipboard.
- From ModAVD 0.38.2 the package no longer ships "补全组件.bat", "收集问题信息.bat" and "复制配置信息.bat"; use the manager, or run
tools\modavd.exe components fetchandtools\modavd.exe collect-info.
(ModAVD/ModAVD#45, ModAVDManager#84)
-
The component download source is remembered:
- Settings have "组件下载源" (component download source) next to the update source; a choice is saved right away, per Windows user, in
%LOCALAPPDATA%\ModAVD\components-settings.json. - The manager and
components fetch(without--mirroror--mirror-url) use it; the "下载源:" line before a download says whether this run's source came from the arguments, the saved setting, the manager's choice or the default. components source [auto|googledownloads_cn|tencent|google]shows or changes it. With nothing saved yet,components fetchin a console asks once by number and remembers the answer; with--json,--accept-license, or input from a pipe or a file it neither asks nor saves.
(ModAVD/ModAVD#120, ModAVDManager#84)
- Settings have "组件下载源" (component download source) next to the update source; a choice is saved right away, per Windows user, in
-
Diagnostics mode: turn on "诊断模式" in the instance settings, or run
modavd set <index> --diagnostics on. Off by default; the logs stay on this computer.- While it is on, the instance's emulator logs, logcat and crash dumps are kept for about 30 days and its newest 20 boot-failure snapshots are kept, under a 4 GiB limit of its own that does not eat into the 1 GiB shared by normal instances. The guest log buffers are larger (at most 48 MiB more guest memory). Problem-info collection takes more logs and snapshots from it.
- The card subtitle shows "诊断模式". When the drive has less than 20 GiB free, cleanup falls back to the normal rules and says so once.
- Turning it off cleans the extra logs back to the normal rules right...
发版:ModAVDManager v0.4.1 (#83)
ModAVDManager v0.4.1
ModAVD.exe:5448c8b6e30d3839fe8243c546f85a2ea5fdd63cea2709f55511d27d1aa36380tools/modavd.exe:7a7b43a0ce2bfd076bb6080d19568efa4b34340ae03f4880fbab0b0b05291054
随 ModAVD 0.38.1 进包。下面是相对 v0.4.0 的改动。
变更
-
更新换包(
modavd update install):- 关机命令刚返回就装,偶尔会在关机辅助进程正好退出的那一刻,把它当成「读不到路径」的占用而拒绝。现在读不到程序路径或命令行时,先按 PID 和创建时间确认这个进程还在不在,已经退出的不算占用。
- 换包前最后一次检查时,要是碰上本根目录的
modavd短命令(比如 AUTO-MAS 定时调的status),最多隔 250 毫秒重扫两次,等它结束。还在的话照旧拒绝,什么都不动。 - 换包由当前装着的那份
modavd来做,所以这一条从 0.4.1 装好以后才生效:从 ModAVD 0.38.0(管理器 0.4.0)升到 0.38.1 的那一次仍可能被拒一次,重试即可。
(ModAVD/ModAVD#77,ModAVDManager#77)
-
执行桥日志
logs\modavd-bridge-<编号>-<时间>.log并进日志清理:每台留最新 10 份,算进logs\的 1 GiB 上限。收集问题信息时,按实例归类收进问题包,不再把它当成一台叫modavd-bridge-<编号>的实例。(ModAVD/ModAVD#97,ModAVDManager#74) -
带界面的管理器
ModAVD.exe --help(-h、-help一样)改成用信息框显示用法和各个选项,退出码 0。以前弹「命令行参数不对」的报错框,退出码 2。其他参数错误照旧报错,退出码 2。(ModAVD/ModAVD#115,ModAVDManager#81) -
补全组件(
modavd components fetch)要下载时,先打一行「下载源:…」,说明这次从哪里下、为什么:- 默认是自动,依次试 Google 中国下载、腾讯云镜像、Google 官方;
- 给了
--mirror就只用那一个; - 给了
--mirror-url就用自定义地址。
(ModAVD/ModAVD#45,ModAVDManager#82)
给调用方(AUTO-MAS)
protocol还是 2:命令、参数、已有字段和退出码都没变。- 错误的
--json里,error.details多了几个机读的键,值都是字符串,调用方要容忍缺少和不认识的键(ModAVD/ModAVD#105,ModAVDManager#75):- 实例操作报
busy时,reason说明是哪一种:running、locked、starting、stopping、window_mismatch、port_in_use、port_other_root。 reason是locked时,lock说明是哪把锁:start、stop、boot、bridge、create、guest、disk、metadata、config。start的开机等待或开机后设置失败时,带上instance_status、qemu_running。create失败时,带上instance_exists,清理结束后再填instance_status、qemu_running。instance_exists只表示这个编号现在有实例文件,不表示是这次建的,不能只凭它自动删除。- 每个键的取值和含义见 README「错误的
details」一节。
- 实例操作报
下载与核对
用 Go 1.26.5、GOTOOLCHAIN=local 运行仓库里的 build.ps1,能编出相同的字节。单独下载的包里还有 Go 的许可原文和文件清单。请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.4.1-win-x64.zip -Algorithm SHA256。
单独下载的管理器不会自己更新,新版本要手动替换;ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录,覆盖整包里的文件。
English
Shipped in ModAVD 0.38.1. Changes since v0.4.0:
Changes
-
Updating the package (
modavd update install):- Installing right after the shutdown command returned could now and then be refused, because a shutdown helper exiting at that very moment was taken for a use whose path could not be read. Now, when a program's path or command line cannot be read, it first checks by PID and creation time whether the process is still there; one that has exited no longer counts as a use.
- If the last check before the swap meets a short
modavdcommand of this root (for example thestatusAUTO-MAS calls on a timer), it scans again up to twice, 250 ms apart, for it to finish. If it is still there, the install refuses as before and changes nothing. - The swap is done by the
modavdalready installed, so this takes effect only once 0.4.1 is in place: the update from ModAVD 0.38.0 (manager 0.4.0) to 0.38.1 may still be refused once; try again.
(ModAVD/ModAVD#77, ModAVDManager#77)
-
The execution bridge logs
logs\modavd-bridge-<index>-<time>.logjoin the log cleanup: each instance keeps the newest 10, counted in the 1 GiB limit oflogs\. Problem-info collection files them under their instance instead of treating them as an instance namedmodavd-bridge-<index>. (ModAVD/ModAVD#97, ModAVDManager#74) -
ModAVD.exe --help(and-h,-help) of the desktop manager now shows the usage and each option in an information box and exits with 0. It used to show a "wrong command-line arguments" error box and exit with 2. Other argument errors still show an error box and exit with 2. (ModAVD/ModAVD#115, ModAVDManager#81) -
When component download (
modavd components fetch) has something to download, it first prints a line "下载源:…" (download source) saying where it downloads from and why:- by default, automatic: Google's China download site, the Tencent Cloud mirror and Google's official site in turn;
- with
--mirror, only that one; - with
--mirror-url, your own addresses.
(ModAVD/ModAVD#45, ModAVDManager#82)
For callers (AUTO-MAS)
protocolis still 2: commands, arguments, existing fields and exit codes are unchanged.- In the
--jsonof an error,error.detailsgains some machine-readable keys. All values are strings; callers must tolerate missing and unknown keys (ModAVD/ModAVD#105, ModAVDManager#75):- For
busyfrom an instance operation,reasonsays which kind:running,locked,starting,stopping,window_mismatch,port_in_useorport_other_root. - With
reasonlocked,locknames the lock:start,stop,boot,bridge,create,guest,disk,metadataorconfig. - When the boot wait or the post-boot setup of
startfails,instance_statusandqemu_runningare added. - When
createfails,instance_existsis added, andinstance_statusandqemu_runningare filled in after the cleanup.instance_existsonly means that this index has instance files now, not that this create made them; do not delete on it alone. - The values and their meaning are in the README section on error
details.
- For
Download and verification
Building with Go 1.26.5 and GOTOOLCHAIN=local through the repository's build.ps1 gives the same bytes. The standalone package also holds the Go license text and a file list. Check the zip and the two exes with the attached SHA256SUMS.txt, for example Get-FileHash .\ModAVDManager-0.4.1-win-x64.zip -Algorithm SHA256 in PowerShell.
The standalone manager does not update itself; replace it by hand. The copy in the ModAVD package is updated with the whole package. When you use it standalone, pass --root or set MODAVD_ROOT, or it reports that it cannot find the ModAVD root. Do not extract the standalone zip over the files of a ModAVD root.
发版:ModAVDManager v0.4.0 (#76)
ModAVDManager v0.4.0
ModAVD.exe:43fdc07fb58114f4b444472f5b4e76dbf1c6d3d399a7b6aa5a2efc7b24a84746tools/modavd.exe:189bbd078e3aad8315e94d52bdb6125aebc31e8a3870920957fbd3821b638d2f
随 ModAVD 0.38.0 进包。下面是相对 v0.3.1 的改动。
新增
-
按应用走代理:可以让实例里只有你指定的几个应用(比如某个要走海外线路的游戏)经过代理上网,其余应用照常直连。
- 命令行:
modavd proxy <编号>看设置;on/off开关(on --server socks5://IP:端口,也可写http://…,或--server auto取这台电脑的代理设置);--add/--remove/--apps改应用名单(填包名);test在这台电脑上探测代理是什么协议、UDP 通不通。代理地址写127.0.0.1或localhost时,会记成实例里看到的宿主地址10.0.2.2。 - 设置存在
mas-avd.json里这台实例名下,开机后的第一步挂上规则,运行中改了马上生效;设置关着的实例开机时,不碰客体。 - 实例卡片菜单里多一项「按应用走代理…」(开关、地址、应用名单,有「从系统代理读取」和「检测」按钮),开着这个设置的卡片上有「代理」标记:绿色是已生效,黄色是正在补规则或最近一次连接没成功,红色是名单里的应用现在断网或直连。
- 目前不支持要账号密码的代理:
auto取到带账号密码的地址时只留host:port,并提示。代理断了,名单里的应用就断网。 - 规则挂不上(客体里没有 root、守护进程对不上等)时,名单里的应用会直连;开机不受影响,原因写进
start返回的警告。
(ModAVD/ModAVD#81,ModAVDManager#44、ModAVDManager#53)
- 命令行:
-
数据盘回收
modavd disk <编号> info | trim | compact:info:数据盘的逻辑大小、在这台电脑上实际占的大小、已分配和估计能回收的大小。只读,开着机也能看(开着机时只给前两项)。compact:关机后把数据盘重写一遍,丢掉客体已经删掉的内容,把文件缩小。整理前先检查剩余空间,只在 NTFS / ReFS 上做;数据盘有内部快照、实例有内存快照时拒绝;新盘要通过qemu-img check和逐字节比对才会换上,任何一步失败都留着原盘。整理期间这台实例开不了机。trim:对开着的实例触发一次客体回收,开机完成后也会自动做一次(每台最多每 24 小时一次)。这一版的模拟器还没有 discard,trim 不会真正回收空间:手动modavd disk trim会报「不支持」(退出码 4),开机自动 trim 检测到没有 discard 就直接跳过。要省空间,用modavd disk compact。- 管理器界面每台实例加了「磁盘占用」「回收空间」「整理磁盘」三个按钮;MCP 加了
disk_info、trim_disk、compact_disk三个工具。
(ModAVD/ModAVD#2,ModAVD/ModAVD#95,ModAVDManager#47)
-
开机失败或超时时,会留下客体现场:开机超时、开机后设置失败、新建的期限到了,而模拟器还在时,返回之前把客体的 logcat、dmesg、系统属性、进程列表、内存信息收进
logs\mas_<编号>-<时间>-bootfail\。你主动取消(Ctrl+C、MCP 取消、管理器里取消任务)、这台实例正在关机、模拟器已经不在时不收。每台实例留最新 3 份,算进logs\的 1 GiB 上限;收集问题信息(collect-info)时带上最新 3 份,合计到 100 MB 为止。里面的 logcat 等可能带账号信息,只存在本机,发问题包前请自己看一眼。(ModAVD/ModAVD#79,ModAVDManager#50)
变更
-
新建实例默认 1080p(1920×1080,DPI 280);720p(1280×720,DPI 240)留作第二档。管理器新建和实例设置、
modavd create/modavd set的--resolution 1080|720、MCP 的create_instance/update_instance共用这两档,DPI 跟着档位一起换,不用单独设。- 已有的实例保留原来的设置:只按宽高认档位,1920×1080(横屏或竖屏)算 1080p,其余和缺字段的旧配置都算 720p。换档时一次写入宽、高、DPI,保留横竖屏方向;开机前按当前档位规范化,不再固定写回 720p。
- 运行中改了分辨率,下次冷启动才生效。同时修了一处:运行中改档以后,管理器画面上的点击会按“下次开机的尺寸”换算而点歪,现在按当前截图的尺寸算,竖屏画面的留白不发送点击。
- 旧版的
modavd不认 1080p;AUTO-MAS 配套的支持见调用方一节。
(ModAVD/ModAVD#100,ModAVDManager#61)
-
modavd stop对新建中的实例变了:以前可以直接把初始化打断,现在默认报忙(退出码 5),--force也不例外,初始化继续做完。确实要打断,要显式加--cancel-create(MCP 是cancel_create;管理器里外部进程在新建的实例,「取消新建」会显式带上)。打断照样走 sync 和安卓的正常关机,这台实例的状态变成create_failed,之后用modavd create --resume <编号>接着做;stop --json的结果里interrupted_create为true。stop --all会关掉所有在跑的实例,包括新建中的,并逐台标出interrupted_create。(ModAVD/ModAVD#103,ModAVDManager#54) -
根目录整个搬走以后,装过执行桥的实例也能开机了。以前搬走以后数据盘覆盖层还指着旧的 SDK 位置,开机报
Could not open backing file。现在可写冷启动时会记下实例 system / vendor 原始镜像的路径、大小和 SHA-256;搬走后路径失效时,先核对新位置的两块镜像和记录一致,再把覆盖层改指过去。- 老实例要先在原位置用新版冷启动、关机一次(记下摘要),再搬整个根目录。已经搬走又没有摘要,或者候选镜像缺失、大小或摘要对不上时,开机返回
precheck_failed(退出码 4),提示是哪块覆盖层、原路径、候选路径和怎么处理,什么都不改。 - 这个检查在管理器、命令行和 AUTO-MAS 调的包内命令行里都一样。
(ModAVD/ModAVD#99,ModAVDManager#55)
- 老实例要先在原位置用新版冷启动、关机一次(记下摘要),再搬整个根目录。已经搬走又没有摘要,或者候选镜像缺失、大小或摘要对不上时,开机返回
-
更新换包(
modavd update):- 关机命令返回后,退出看门狗和开机守护可能还活着,以前会立刻拒绝更新;现在最多等 30 秒让它们退场,超时才拒绝,并列出还活着的进程名和 PID。
- 以前换包前扫描完、换包前的那一刻,如果有人直接启动 emulator,或者另一个共用同一份 SDK 的根目录启动,更新仍会继续换包。现在换包期间先拿住本根目录所有编号的启动锁,再按文件 ID 把 SDK 里的程序文件都占住,换包全程(包括备份、重命名、出错恢复)新的启动都会被拦下,最后再扫一遍,有新占用就拒绝、什么都不动。
- ModAVD 根目录所在的盘要支持按文件 ID 打开程序文件(NTFS 可以)。放在 exFAT / FAT32 上的根目录,自动换包会被拒绝、什么都不动,请手动下载整包。只读、权限不够、有程序被占用时也一样拒绝。
(ModAVD/ModAVD#77,ModAVDManager#58)
-
磁盘整理期间,这台实例的开机(
start)、删除(delete)和执行桥安装会马上报忙,提示「正在整理磁盘」,不再傻等。disk info在拿不到锁或读不到数据时不再报错,改成给出能读到的文件头大小和宿主占用,并在warnings里写明哪些没算、为什么;读不到的数值直接省略(比如拿不到宿主占用时,on_disk_bytes这一项就不出现)。数据盘损坏时,info的提示会说明它检查了什么,并给出备份、恢复、保留副本排查,或确认放弃数据后删除重建的处理建议。(ModAVD/ModAVD#95,ModAVDManager#63) -
整理磁盘(
disk compact):覆盖层本身是符号链接(包括悬空的)或有多个硬链接时,在动手之前拒绝(unsupported,退出码 4),提示路径、原因和怎么办,不会在中途写坏链接的另一头。(ModAVD/ModAVD#95,ModAVDManager#59) -
管理器被外部结束时,磁盘整理、查看用的
qemu-img子进程也会跟着结束,不再继续占着数据盘的覆盖层。(ModAVD/ModAVD#95,ModAVDManager#60) -
非 Windows 平台上,打开日志目录、显示 / 隐藏窗口这类只有 Windows 才支持的操作,现在明确返回「不支持」,不再先建目录再报内部错误,也不再把查不到进程当成实例离线而报成功。Windows 上的行为不变。(ModAVD/ModAVD#74,ModAVDManager#49)
-
组件下载(
components fetch)和modavd update的下载合成同一套:共用连接、响应等待和“响应体停顿”超时(连接等 20 秒、读取停顿 30 秒),续传时严格核对服务器回的范围,带管理器版本号的 User-Agent,网络错误和 CDK 在输出里脱敏。Mirror 酱每次从头下载;更新下了一半的.part重新下,已经校验过的完整文件仍可复用。- 补全组件的边界:搬目录失败或后缀冲突、旧目录位置、完整的坏缓存、超时参数超范围、只设了
NO_PROXY时用系统代理、重试时取消、重复的 ZIP、剩余空间、日志。--help里写明许可被拒是退出码 2,退出码 9 也包括代理不可用。 - 收集问题信息:修了新版 adb 的 logcat 请求,ZIP 用本地时间,查盘信息失败时取消并等盘类型查询结束,根目录和暂存目录展开 8.3 短名;ZIP 做完之前取消会删掉半个 ZIP,默认清理暂存目录,加
--keep-stage则保留并返回路径;普通打包失败时已收集的文件仍保留。
(ModAVD/ModAVD#91、ModAVD/ModAVD#72、ModAVD/ModAVD#73,ModAVDManager#51)
- 补全组件的边界:搬目录失败或后缀冲突、旧目录位置、完整的坏缓存、超时参数超范围、只设了
-
磁盘整理按工作量定时限:转换、比对各按虚拟容量加预算(下限 30 / 20 分钟,大盘可以到数十小时,正常整理基本不会超时,要停就取消);预计能回收的不足 16 MiB 与宿主占用 1% 中的较大者时,跳过重写,不再白白重写整个盘。
disk compact的结果新增带符号的on_disk_delta_bytes(整理后减整理前,占用增加时为正)和skipped等字段,freed_bytes和前后占用字段保留;界面上整理磁盘可以中途取消。(ModAVD/ModAVD#95,ModAVDManager#65) -
宿主上正在写的模拟器 logcat 每到 256 MiB 切一份,每台保留最新 10 份已关闭的,已关闭的合计上限 1 GiB,不再无限长大。采集进程绑定这次开机的模拟器,模拟器退出时自己退出,不会遗留下来占着管理器程序、挡住整包更新。(ModAVD/ModAVD#97,ModAVDManager#57)
-
磁盘回收的界面和日志改了说法,区分“触发请求已返回”和“客体回收已完成”:管理器里运行中显示「已进行」,返回后显示「触发请求用时」和「已触发」,说明写明不等安卓回收完成;命令行的「已触发磁盘回收」不变。(ModAVD/ModAVD#95,ModAVDManager#64)
说明
- 磁盘整理(
disk compact)会重写整个数据盘,需要和已分配大小差不多的空闲空间(按已分配的 1.05 倍再加 2 GiB 估算),不够时会拒绝并提示要腾出多少。 - 按应用走代理的已知限制:AUTO-MAS 写
mas-avd.json时不拿mas-avd.json.lock,它和 modavd 同时改这个文件时,后写的会把先写的冲掉,代理设置的修改也可能因此丢;不经过 modavd 开机的实例,这次开机没有规则,名单里的应用直连;客体重启后规则最多晚 5 秒补上,这几秒名单里的应用直连。
给调用方(AUTO-MAS)
protocol还是 2:只加了命令、字段、工具和错误码,没有删字段,也没有改已有退出码的含义。(internal/buildinfo里Protocol = 2。)- 新命令:
proxy(<i> [on|off|test] [--server …] [--add …] [--remove …] [--apps …])、disk(<i> info | trim | compact)。stop加了--cancel-create。create、set的--resolution取 1080 或 720,新建不写就是 1080。 stop的行为变了(ModAVDManager#54):新建中的实例,stop(含--force)默认返回busy(退出码 5),不再打断初始化。AUTO-MAS 如果以前靠stop打断新建,要改成显式加--cancel-create;打断后create以退出码 8(已取消)结束,实例状态create_failed,用create --resume <编号>接着做。stop --json的结果里interrupted_create在被打断时为true;stop --all会连新建中的一起关,并逐台标出这个字段。- 新字段:
list、info里的实例多一个app_proxy(开关、地址、名单个数;没设过是null)。modavd proxy --json的data里applied取值now、booting、next_boot、off、failed。disk info --json:index、overlay、running、needs_shutdown、logical_bytes、on_disk_bytes、allocated_bytes、reclaimable_bytes、warnings。on_disk_bytes、allocated_bytes、reclaimable_bytes在读不到、算不出时会省略(不是 0),原因写在warnings,不要把缺省当成 0 处理。disk compact --json:before_on_disk_bytes、after_on_disk_bytes、freed_bytes。- 开机失败、超时等错误的
--json里,error.details.boot_diag_dir是客体现场所在的目录(没有就不出现)。
- 新错误码
proxy_unavailable(代理不通、不是 SOCKS5 / HTTP,或auto时宿主没设代理),退出码沿用 9(和更新、组件下载不可用同一个)。precheck_failed(退出码 4)现在也会因“搬走根目录后接不回执行桥的后备镜像”而出现。 - 新的 MCP 工具:
get_app_proxy(只读)、set_app_proxy、disk_info、trim_disk、compact_disk;stop_instance多一个cancel_create参数;create_instance/update_instance多resolution(1080 / 720)。 - 创建实例默认 1080p:经包内
modavd新建、不传--resolution的实例是 1080p;旧实例不受影响。要 720p,新建时显式传--resolution 720。旧版modavd不认 1080p。 - ModAVD 根目录所在的盘不支持按文件 ID 打开程序文件(exFAT / FAT32)时,
update返回not_ready并什么都不动。
下载与核对
使用 Go 1.26.5、GOTOOLCHAIN=local,运行仓库中的 build.ps1 可以编出相同字节。单独下载包还包含 Go 许可原文和文件清单;请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.4.0-win-x64.zip -Algorithm SHA256。
单独下载的管理器不会自己更新,新版本要手动替换;ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录覆盖整包中的文件。
English
Shipped in ModAVD 0.38.0. Changes since v0.3.1:
New
-
Per-app proxy: only the apps you list (for example a game that needs an overseas route) go out through a proxy in the instance; everything else connects directly.
- Command line:
modavd proxy <index>shows the setting;on/offswitch it (on --server socks5://IP:port, orhttp://…, or--server autoto take this computer's proxy setting);--add/--remove/--appsedit the app list (package names);testprobes on this computer what protocol the proxy speaks and whether UDP works. An address of127.0.0.1orlocalhostis stored as the host address10.0.2.2as seen from inside the instance. - The setting lives under the instance in
mas-avd.json. The rules are installed as the first step after boot, and a change made while the instance runs takes effect at once; an instance with the setting off leaves the guest alone at boot. - The card menu gets "Per-app proxy…" (switch, address, app list, with "Read from system proxy" and "Check" buttons). Cards with the setting on show a "Proxy" mark: green means in effect, yellow means rules are being restored or the last connection did not succeed, red means the listed apps are currently offline or connecting directly.
- Proxies that need a username and password are not supported: when
autofinds an address with credentials, onlyhost:portis kept and you are told. If the proxy goes down, the listed apps lose their network. - When the rules cannot be installed (no root in the guest, the guest daemon does not match, and so on), the listed apps connect directly; boot is not affected and the reason is added to the warnings
startreturns.
(ModAVD/ModAVD#81, ModAVDManager#44, ModAVDManager#53)
- Command line:
-
Data disk reclaim,
modavd disk <index> info | trim | compact:info: the data disk's logical size, the size it actually takes on this computer, the allocated size and the estimated reclaimable size. Read-only and usable while running (while running, only the first two are given).compact: after shutdown, rewrites the data disk, drops what the guest has deleted and shrinks the file. It checks free space first and works only on NTFS / ReFS; it refuses when the data disk has internal snapshots or the instance ...
发版:ModAVDManager v0.3.1 (#46)
ModAVDManager v0.3.1
ModAVD.exe:461d538cdd391928cdf29191c7461d694c7856d7d33bf66179996df839ca58dftools/modavd.exe:dbbb6b721d981af7aed2abcb648458120b9ea8277564b534d560fd8852cfe867
随 ModAVD 0.37.1 进包。下面是相对 v0.3.0 的改动。
新增
-
开发、测试用的根目录可以在
mas-avd.json里写portBase,这个根目录的实例就从它起算端口,不再和同一台电脑上别的根目录里同编号的实例抢端口。可以写 20000,或者 1100–65400 之间 100 的整数倍,每个根目录占一段 100 个端口。没写的根目录和以前一样从 20000 起。- 设了
portBase的根目录还要配自己的adbServerPort、scriptAdbServerPort,不能用 20049、20050。 - 不要把它加进 AUTO-MAS,AUTO-MAS 不认
portBase。 - 值不合规时,新建、挑编号、开机都拒绝,看状态的命令照常。
(ModAVD/ModAVD#75,ModAVDManager#39)
- 设了
变更
-
起模拟器时不再用 netsim(关掉 WiFi 包流、蓝牙模拟和 UWB),也就不再连整机共用的 netsimd。以前它一卡住,这台电脑上之后开的模拟器都开不了机。WiFi 改走模拟器自带的那条路,热点照旧叫 AndroidWifi;游戏的网络本来就不走 netsim,不受影响。(ModAVD/ModAVD#82,ModAVDManager#35)
-
modavd update和补全组件用同一套代理规则:先看HTTPS_PROXY/HTTP_PROXY/NO_PROXY;都没设,就用 Windows「Internet 选项」里手动设的代理。以前只在系统里设了代理的电脑上,补全组件能下,从 GitHub 更新却连不上。用自动配置脚本(PAC)的照旧不读,连不上时会提示设HTTPS_PROXY。(ModAVD/ModAVD#78 的代理这一半,ModAVDManager#38) -
关机(
modavd stop、管理器的「关机」):- 前台开着应用时,先按 HOME 让它退到后台,等 2 秒让它存数据。
- 发关机命令前,先把客体的数据写回磁盘。
- 关机命令换成走安卓框架的正常关机(
svc power shutdown),应用先收到要关机的通知。以前的命令绕过框架,前台应用来不及保存就被结束。 - 等安卓关机最多等到第 24 秒,总时限还是 28 秒。
- 以前等安卓关机超时以后,兜底时数据已经写不回去,结束进程就等于断电。
(ModAVD/ModAVD#88,ModAVDManager#41)
-
打开管理器时,不会再另外弹出一个完整的 Edge 浏览器窗口:
- 管理器窗口用的 Edge 不再自动用 Windows 登录的 Microsoft 账户登录,也不同步、不加载扩展。
- 关掉管理器窗口时,也不会再在后台启动你自己的 Edge。
- 配置目录换成新的
%LOCALAPPDATA%\ModAVD\ui-edge2。 - Edge 界面不是中文时,不再弹「翻译此页」。
(ModAVD/ModAVD#90,ModAVDManager#42)
-
显示 / 隐藏模拟器窗口(
modavd window,AUTO-MAS 静默模式会用)不再按窗口标题找:在实例自己的 qemu 进程里,按 Qt 的窗口类和属主认出主窗口。以前安全关机途中(标题后面多了「正在关机…」)或鼠标被模拟器捕获时,窗口藏不掉。也为以后把模拟器窗口标题改成实例名(ModAVD/ModAVD#58)做准备。(ModAVDManager#43) -
补全组件和收集问题信息(ModAVD/ModAVD#72,ModAVDManager#45):
- 某个镜像回 HTTP 416 时,不再删掉已经下了的部分(
.part),换下一个镜像接着下;所有镜像都回 416 时,提示删哪个文件再来。 - 镜像不支持断点续传、回了整个文件时,从头写。
- 收集问题信息:
live/下文件的换行和 adb 输出的一致;Windows 信息(WMI)每一类单独查、单独限时,一类卡住不再连累别的;收集途中按 Ctrl+C 会删掉暂存目录,不留半个 zip。
- 某个镜像回 HTTP 416 时,不再删掉已经下了的部分(
说明
-
旧的配置目录
%LOCALAPPDATA%\ModAVD\ui-edge新版不再用:升级后打开管理器,窗口出来以后在后台把它删掉。- 同一台电脑上还开着旧版管理器时先跳过,下次打开再删;删不掉只记日志,不影响打开。
- 里面是以前同步进去的收藏夹、历史记录和密码的副本,你自己的 Edge 和 Microsoft 账户里的数据不受影响。
- 退回旧版时,旧版会重新建一个
ui-edge。
(ModAVD/ModAVD#90,ModAVDManager#42)
给调用方(AUTO-MAS)
protocol还是 2,只加了字段:list、check的--json加port_base(实际用的端口段,不合规时是 20000);status --json加serial、adb_address、ports。(ModAVDManager#39)stop的总时限还是 28 秒,--json的结构不变。走兜底时,发关机命令前那次 sync 成功也算synced。(ModAVDManager#41)window的参数和--json不变,只是找窗口的办法变了。(ModAVDManager#43)modavd --json components fetch不带--accept-license现在一律报usage(退出码 2),在找根目录之前就报。以前根目录组件齐的时候,这条命令会成功。AUTO-MAS 的 avdcli 不调这条命令。(ModAVDManager#45)
下载与核对
使用 Go 1.26.5、GOTOOLCHAIN=local,运行仓库中的 build.ps1 可以编出相同字节。单独下载包还包含 Go 许可原文和文件清单;请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.3.1-win-x64.zip -Algorithm SHA256。
单独下载的管理器不会自己更新,新版本要手动替换;ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录覆盖整包中的文件。
English
Shipped in ModAVD 0.37.1. Changes since v0.3.0:
New
-
A root folder used for development or testing can set
portBaseinmas-avd.json; its instances then count their ports from that number and no longer collide with the same-numbered instances of another root folder on the same computer. Allowed values are 20000, or a multiple of 100 between 1100 and 65400; each root folder takes a block of 100 ports. Root folders without it start at 20000 as before.- A root folder with
portBasealso needs its ownadbServerPortandscriptAdbServerPort, not 20049 or 20050. - Do not add it to AUTO-MAS, which does not read
portBase. - With an invalid value, create, picking an index and start refuse; the status commands work as before.
(ModAVD/ModAVD#75, ModAVDManager#39)
- A root folder with
Changes
-
Emulators are started without netsim (Wi-Fi packet stream, Bluetooth emulation and UWB off), so they no longer connect to the netsimd that every emulator on the computer shares. Before, once it hung, no emulator started afterwards on that computer could boot. Wi-Fi now takes the emulator's built-in path and the hotspot is still called AndroidWifi; game traffic never went through netsim and is not affected. (ModAVD/ModAVD#82, ModAVDManager#35)
-
modavd updateand component download use the same proxy rules:HTTPS_PROXY/HTTP_PROXY/NO_PROXYfirst, and if none is set, the proxy set by hand in Windows' Internet Options. Before, on computers with the proxy set only in Windows, components could be downloaded but updating from GitHub could not connect. Proxy auto-config (PAC) is still not read; when the connection fails, the message suggests settingHTTPS_PROXY. (the proxy half of ModAVD/ModAVD#78, ModAVDManager#38) -
Shutdown (
modavd stop, "Shut down" in the manager):- If an app is in the foreground, it first presses HOME and waits 2 seconds so the app can save.
- Before the shutdown command, it writes the guest's data back to disk.
- The shutdown command is now Android's normal framework shutdown (
svc power shutdown), so apps are told first. The old command bypassed the framework, and the foreground app was ended before it could save. - It waits for Android to shut down until second 24; the total limit is still 28 seconds.
- Before, once waiting for Android timed out, the fallback could no longer write the data back, and ending the process was the same as pulling the plug.
(ModAVD/ModAVD#88, ModAVDManager#41)
-
Opening the manager no longer pops up a full Edge browser window:
- The Edge the manager uses no longer signs in automatically with the Microsoft account Windows is signed in with, does not sync and does not load extensions.
- Closing the manager window no longer starts your own Edge in the background.
- Its profile folder is the new
%LOCALAPPDATA%\ModAVD\ui-edge2. - When Edge's interface is not in Chinese, it no longer offers to translate the page.
(ModAVD/ModAVD#90, ModAVDManager#42)
-
Showing and hiding the emulator window (
modavd window, used by AUTO-MAS's silent mode) no longer looks for the window by its title: it picks the main window inside the instance's own qemu process by its Qt window class and owner. Before, the window could not be hidden during a safe shutdown (the title gets a "shutting down…" suffix) or while the emulator had captured the mouse. This also prepares for naming the emulator window after the instance later (ModAVD/ModAVD#58). (ModAVDManager#43) -
Component download and problem info (ModAVD/ModAVD#72, ModAVDManager#45):
- When a mirror answers HTTP 416, the part already downloaded (
.part) is no longer deleted; the next mirror continues it. If every mirror answers 416, the message says which file to delete before trying again. - When a mirror does not support resuming and sends the whole file, it is written from the start.
- Problem info: files under
live/have the same line endings as adb's output; Windows information (WMI) is queried one class at a time, each with its own time limit, so one class hanging no longer takes the others with it; pressing Ctrl+C while collecting removes the staging folder and leaves no half-written zip.
- When a mirror answers HTTP 416, the part already downloaded (
Notes
-
The old profile folder
%LOCALAPPDATA%\ModAVD\ui-edgeis no longer used. After the update, the manager deletes it in the background once its window is open.- If an older manager is still open on the same computer, it is skipped and deleted the next time; if it cannot be deleted, that is only logged and does not stop the manager from opening.
- The folder holds copies of favorites, history and passwords that were synced into it; your own Edge and the data in your Microsoft account are not affected.
- If you go back to an older version, it creates a new
ui-edge.
(ModAVD/ModAVD#90, ModAVDManager#42)
For callers (AUTO-MAS)
protocolis still 2; only fields were added:port_basein the--jsonoflistandcheck(the port block actually used, 20000 when invalid);serial,adb_addressandportsinstatus --json. (ModAVDManager#39)- The total limit of
stopis still 28 seconds and its--jsonhas the same shape. On the fallback path, a successful sync before the shutdown command also counts assynced. (ModAVDManager#41) - The arguments and
--jsonofwindoware unchanged; only the way it finds the window changed. (ModAVDManager#43) modavd --json components fetchwithout--accept-licensenow always fails withusage(exit code 2), before the root folder is looked up. Before, the same command succeeded when the root folder already had every component. AUTO-MAS's avdcli does not call this command. (ModAVDManager#45)
Download and verification
Building with Go 1.26.5 and GOTOOLCHAIN=local through the repository's build.ps1 gives the same bytes. The standalone package also holds the Go license text and a file list; check the zip and the two exes with the attached SHA256SUMS.txt, for example Get-FileHash .\ModAVDManager-0.3.1-win-x64.zip -Algorithm SHA256 in PowerShell.
The standalone manager does not update itself; replace it by hand. The copy in the ModAVD package is updated with the whole package. When you use it standalone, pass --root or set MODAVD_ROOT, or it reports that it cannot find the ModAVD root. Do not extract the standalone zip over the files of a ModAVD root.
v0.3.0
ModAVDManager v0.3.0
ModAVD.exe:d34287cb16d4ace4b9dce4999afcd9d657aef11a6127b351ca421a07f7c654b4tools/modavd.exe:fb28ebe7881ba69fe9330b537ec2f9d65dc8c4d64f9dd64e313a5fe47fc52f12
随 ModAVD 0.37.0 进包(0.36.0 包里是 v0.1.0,所以从包里升级上来的,v0.2.0 的改动也一并带上,见 v0.2.0 的说明)。下面是相对 v0.2.0 的改动。
新增
- 随包的三个脚本搬进命令行:
components status|fetch:照「补全组件.bat」下载 adb 和 Android 系统镜像。先显示《Android 软件开发套件许可协议》,输入 y 才下载(--json时要给--accept-license);断点续传;核对大小、SHA-1 和 adb 三个文件钉住的 SHA-256 后再挪到位;不完整的旧目录改名保留,不删。collect-info:照「收集问题信息.bat」打问题包,只读,不起 adb server。report-config:照「复制配置信息」输出配置信息。- ModAVD 包里的
.bat这一版还是调原来的 PowerShell 脚本,改调这几个命令留到下一版(ModAVD/ModAVD#45)。
变更
- 新建实例时,命令行、MCP 和管理器一直显示「新建中 NN%」,直到后台那次开机、开机后的设置、宿主输入法、首次初始化、执行桥都做完、正常关机以后才算新建完成。百分比按实际做完的步骤算,只增不减,关机做完才到 100%。别的进程(例如 AUTO-MAS)发起的新建,管理器里也看得到进度。(ModAVDManager#31)
- 管理器卡片的「更多」里,新建中的「强制关机」换成「取消新建」:正常关机,实例停在「新建失败」,之后可以「重试初始化」。命令行的
stop照旧能中止新建。(ModAVDManager#31) create --resume碰到上次新建时没关掉的模拟器,先把客体数据写回磁盘再正常关机,然后重做,不用再先手动stop;关不掉才报错。(ModAVDManager#31)- 新建过程中每次开机做完,不再提示「实例 N 已就绪」,改成「这次开机后的设置做完了」。(ModAVDManager#31)
- 管理器界面上的「开机」一律带窗口,卡片「更多」里去掉了「带窗口开机」「重启」「显示窗口 / 隐藏窗口」。无窗口开机只走命令行和 MCP;显示 / 隐藏窗口以后改做老板键,命令行的
modavd window <编号> show|hide和 MCP 的set_window_visible照旧。(ModAVDManager#33) - 实例运行中不再切换有窗口 / 无窗口:
start新增--headless,和--window二选一,都不给时新开机是无窗口,和以前一样。实例已经在运行、或者正被另一次start开着时,要的方式和它现在不一样,就报busy(退出码 5),提示先关机再换,不接管也不重启;都不给就照它现在的方式接管,和以前一样。MCP 的start_instance同样处理。(ModAVDManager#33) - L3 缓存分大小两组的处理器(例如 7950X3D)上,多开时按各组还空着的核数比例给新实例选组,不再全都绑到大 L3 那组;只开一台时和以前一样绑大 L3。只有一组 L3、或者各组一样大的处理器不绑核,和以前一样。(ModAVD/ModAVD#34)
- 下载时的忙等循环数按宿主的余量设上限:不超过本实例的核数,也不超过逻辑核数减去所有模拟器占的核数。几台同时下载时不会把一组核心占满;逻辑核数不到本实例核数两倍的电脑上,只开一台时下载会比以前慢一些。(ModAVD/ModAVD#34)
- 拆出平台层,为以后支持别的平台做准备。Windows 上的行为和以前一样;macOS、Linux 上目前只能编译,所有操作都返回
unsupported,不写任何东西。 - arm64 客体(
abi.type/hw.cpu.arch是 arm64、arm64-v8a、aarch64)不装执行桥;bridge verify写明不需要,uninstall删掉残留的开机标记。
不兼容的改动
- 去掉
modavd restart命令和管理器界面上的「重启」按钮。旧的modavd restart、modavd help restart报用法错误(usage,退出码 2),提示改用modavd stop <编号>再modavd start <编号>。AUTO-MAS 里调restart的地方已经改成先关机再开机(AUTO-MAS-Project/AUTO-MAS#1794,在 dev 分支上)。(ModAVDManager#33) --json输出里的protocol(buildinfo.Protocol)从 1 升到 2。和 1 的差别:去掉了restart;start加了--headless;运行中的实例和要的开机方式对不上时报busy,不再接管;MCPstart_instance的window没有默认值了;加了window、creation_progress两个字段。信封和其余已有字段、错误码的含义不变。只认 1 的调用方要改成也认 2:AUTO-MAS 那边已经改成认 1 和 2(同上)。(ModAVDManager#33)
修复
- 已经装了执行桥的实例,开机时发现桥的文件和包里的不一样(更新过 ModAVD 包),就在开机后的设置做完后换上新文件,再冷启动一次。以前要手动跑
modavd bridge <编号> install。只在这次是 modavd / 管理器拉起的开机时做;AUTO-MAS 自己开机的实例不经过这一步。(ModAVDManager#30) - 实例正在关机时(例如刚点了模拟器窗口的 ×,或 AUTO-MAS 正在关它)再开机,先等它关完(最多 30 秒)再开机。以前会当成「已在运行」,返回成功后实例又自己退出。(ModAVDManager#29)
modavd bridge install/uninstall要冷启动开着的实例时,照它原来的方式开回来:带窗口的还带窗口,无窗口的还无窗口。以前一律按无窗口重开。(ModAVDManager#33)
给调用方(AUTO-MAS)
--json的protocol升到 2,差别见「不兼容的改动」;其余已有字段和错误码的含义不变。status/list/info新增字段window:带窗口运行时为 true,无窗口运行或没开机时为 false,可以用running && !window判断「无窗口运行中」。(ModAVDManager#33)- 开机方式和运行中的实例对不上时,
start报busy(退出码 5),不接管、不重启;调用方把提示原样给用户就行。(ModAVDManager#33) status/list/info新增字段creation_progress(0–100,只在creating时有值,否则是 0),AUTO-MAS 不用显示。status是creating时running/booted可能是 true,以status为准;create ... --json照旧一直等到新建完成、实例关机后才返回。(ModAVDManager#31)- 新错误码:
license_declined(退出码 2),components_unavailable、components_rejected(退出码 9)。 - 非 Windows 平台上一律返回
unsupported。
下载与核对
使用 Go 1.26.5、GOTOOLCHAIN=local,运行仓库中的 build.ps1 可以编出相同字节。单独下载包还包含 Go 许可原文和文件清单;请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.3.0-win-x64.zip -Algorithm SHA256。
单独下载的管理器不会自己更新,新版本要手动替换;ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录覆盖整包中的文件。
v0.2.0: Merge pull request #17 from qiyinxi/release/0.2.0
ModAVDManager v0.2.0
ModAVD.exe:c248eb67641387faa789a5cbe580d0c94c6f89a5a6075ff0b734afad15ba7868tools/modavd.exe:38ca4270622de354bf99c9a704dd69100ce8a7b23d67047c3a8325f01ef37aa6
新增
- 新建实例时在后台做完初始化:
create(命令行、MCP、管理器)建完文件后,在后台无头开机一次,做完首次初始化、宿主输入法和执行桥,先 sync 再正常关机,才算新建完成。之后第一次开机和平常一样快。- 新建中,
status和busy都是creating,这时开机、修改、删除都会提示实例忙。 - 失败或超时记为
create_failed,creation_error写原因。用create --resume N重做初始化,或者删掉重建。 - 管理器里的新建和「重试初始化」都在后台跑,卡片上有进度。
- 新建中,
- 更新整个 ModAVD 包:
modavd update [status|check|prepare|install|recover],和 AUTO-MAS 的「魔改 AVD 一键更新」做同一件事,共用<根>\.update\目录,哪边更新到一半,另一边都能接着补完或退回。- 来源在管理器「设置」里选:GitHub,或者 Mirror 酱(填了 CDK 才能下载,能拿增量包)。CDK 加密保存,不进日志。
- 现在由 AUTO-MAS 调用命令行发起更新,管理器里的「更新」按钮暂时不可用。
- 加了 HTTPS 下载,
modavd.exe从约 4.9 MB 增大到约 8.3 MB。
info、list、status新增字段:bridge(off、pending、installed、unknown)、started_at_ms、creation、creation_error、creation_log。
修复
- 执行桥:装、卸期间持有实例锁(
busy为bridging);修好bridge install的回归;状态只问已经开完机的客体。 start返回之前,确认/sdcard真能写进文件(最多再等 60 秒)。以前开机刚完成时,脚本马上往/sdcard写文件可能失败。- 修复开机时的竞态,以及几个进程同时准备客体脚本时的共享冲突。
- 新建失败时的报错不再括号套括号;更新时按名字兜底找进程,不再把
crashpad_handler算进去。
给调用方(AUTO-MAS)
--json的新字段都是加的,protocol仍是 1。busy多了bridging、creating,status多了creating、create_failed;认不出的取值一律当忙处理。- 新错误码
update_unavailable、update_rejected,退出码 9。 - 新建会多花几分钟,但有进度;之后的
start不再做首次初始化,开机的超时可以收短。 - 客体脚本的头注释改了,AUTO-MAS
res/avd/guest/里的同名脚本要跟着改(只改注释)。
下载与核对
使用 Go 1.26.5、GOTOOLCHAIN=local,运行仓库中的 build.ps1 可以编出相同字节。单独下载包还包含 Go 许可原文和文件清单;请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.2.0-win-x64.zip -Algorithm SHA256。
单独下载的管理器不会自己更新,新版本要手动替换;ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录覆盖整包中的文件。
v0.1.0: Merge pull request #3 from qiyinxi/release/0.1.0
ModAVDManager v0.1.0
这是 ModAVDManager 的第一个独立版本。ModAVD.exe 与 tools/modavd.exe 和 ModAVD v0.36.0 包中的对应文件逐字节相同:
ModAVD.exe:3331b658a9f3a000091f4bda6ed13298e11eceee9962c1ce22e1bcfbccc4d65btools/modavd.exe:90cb0d9ad05b366144202600d38e6d1341a5b9e20b152a7fbe20a220d558723d
使用 Go 1.26.5、GOTOOLCHAIN=local,运行仓库中的 build.ps1 可以编出相同字节。单独下载包还包含 Go 许可原文和文件清单;请用附件 SHA256SUMS.txt 核对 zip 和解压出的两个 exe,例如在 PowerShell 里运行 Get-FileHash .\ModAVDManager-0.1.0-win-x64.zip -Algorithm SHA256。
管理器不会自己更新:单独下载的文件需要手动替换,ModAVD 包里的那份随 ModAVD 整包一起更新。单独使用时请给 --root 或设置 MODAVD_ROOT,否则会提示找不到 ModAVD 根目录。不要把单独下载的 zip 解压到 ModAVD 根目录覆盖整包中的文件。