DuoPlus-Agent: Enable Agents to Control DuoPlus Cloud Phones via ADB Broadcasts

Preface

To run automation on cloud phones or remote Android devices, common practice is to write Appium or Maestro scripts locally, or piece together adb shell input and screenshot capture yourself. When the device lives in a server room and the UI is in the cloud, agents often lack a set of “reproducible, verifiable” operation conventions.

The duoplus-agent described below is a community Skill on SkillHub (coordinates @user_1df07c13/duoplus-agent, category ai-agent). It turns clicks, swipes, input, screenshots, and UI hierarchy analysis into a fixed workflow, and under the hood delivers JSON instructions via ADB broadcasts to the DuoPlus CloudPhone service running on the device. The page shows requires_api_key=false, so it does not depend on any additional API key.

What Is This

duoplus-agent (display name: DuoPlus CloudPhone Agent) is published by community user user_1df07c13; the current SkillHub page version is v1.0.0, and the source is community.

One-sentence positioning: provided adb is installed and the target device is running DuoPlus CloudPhone-related system services, it lets a coding agent connect to the device, dispatch operations, and validate with screenshots or uiautomator, following the Skill docs.

Official Skill page and API entry points:

  • Display page: https://www.skillhub.cn/skills/user_1df07c13/duoplus-agent
  • API: https://api.skillhub.cn/user_1df07c13/duoplus-agent

Core Functions

The following capabilities come from the Skill package’s SKILL.md and the helper script scripts/send_command.sh.

Device Connection

After connecting wirelessly, specify the device with -s <DEVICE_ID> for subsequent commands:

adb connect <IP>:<PORT>
adb devices -l

UI Control via JSON Actions

The Skill provides scripts/send_command.sh to wrap action_name and params into a complete payload, Base64-encode it, and send it via a broadcast:

adb -s <DEVICE_ID> shell am broadcast -a com.duoplus.service.PROCESS_DATA --es message "<BASE64>"

Actions listed in the docs include but are not limited to:

Type Example action_name Notes
Launch app OPEN_APP Requires package_name
Click CLICK_COORDINATE, CLICK_ELEMENT Match by coordinates or element attributes such as text
Gestures LONG_COORDINATE, DOUBLE_TAP_COORDINATE, SLIDE_PAGE Include direction and start/end coordinates
Input INPUT_CONTENT, KEYBOARD_OPERATION Focus the input field before typing; supports enter/delete and other keys
Navigation GO_TO_HOME, PAGE_BACK System-level back and home
Wait WAIT_TIME, WAIT_FOR_SELECTOR Fixed delay or wait for element to appear
End END_TASK Docs recommend using it when stuck

The docs emphasize: action commands are fire-and-forget and do not return execution results. You should verify each step with a screenshot or UI dump.

UI Analysis and Screenshots

  • Hierarchy: use uiautomator dump to pull view.xml, then locate elements by text or resource-id and read bounds.
  • Visual: use screencap to capture PNG, optionally compress to WebP with cwebp and pass it to a vision model for analysis.

The Skill metadata requires adb and cwebp on the host (if cwebp is absent, you can use PNG directly).

The typical loop in the docs: analyze UI → execute via send_command.sh → local sleep 1–3 seconds → screenshot or dump again → repeat until done.

The coordinate system uses 0–1000 relative coordinates (not pixels); for swipes, it is recommended to use non-integer start/end coordinates.

Installation and Activation

1. Install the SkillHub CLI (if not already installed)

Check and install per https://skillhub.cn/install/skillhub.md:

command -v skillhub && skillhub --version

If not installed, run:

curl -fsSL https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/install.sh | bash

2. Install duoplus-agent

When installing, you must point --dir to the current agent’s skills directory; otherwise the default ./skills/ may not be recognized:

skillhub install @user_1df07c13/duoplus-agent --dir <your skills directory>

Common paths (aligned with the official installation docs):

  • Cursor: ~/.cursor/skills/
  • Claude Code: ~/.claude/skills/
  • Codex: ~/.codex/skills/ or .agents/skills/ under the project

Alternatively, follow the prompts on the SkillHub page and have the agent read https://skillhub.cn/install/skillhub.md before installing @user_1df07c13/duoplus-agent.

The Skill package README also provides the ClawHub coordinates duoplus/duoplus-agent and a method to copy into the local OpenClaw skills directory; if you are using an OpenClaw-based client, follow the README.

After installation, restart or refresh the agent so it loads the new Skill.

Typical Usage

The examples below use paths relative to the Skill installation directory, consistent with the official SKILL.md.

Launch WeChat (example package name):

scripts/send_command.sh <DEVICE_ID> '{"action_name":"OPEN_APP","params":{"package_name":"com.tencent.mm"}}'

Click “Login” by text:

scripts/send_command.sh <DEVICE_ID> '{"action_name":"CLICK_ELEMENT","params":{"text":"Login"}}'

Focus the input, clear it, then type:

scripts/send_command.sh <DEVICE_ID> '{"action_name":"CLICK_ELEMENT","params":{"text":"用户名"}}'
scripts/send_command.sh <DEVICE_ID> '{"action_name":"INPUT_CONTENT","params":{"content":"Hello","clear_first":true}}'
scripts/send_command.sh <DEVICE_ID> '{"action_name":"KEYBOARD_OPERATION","params":{"key":"enter"}}'

Pull the UI hierarchy to locate elements:

adb -s <DEVICE_ID> shell uiautomator dump /sdcard/view.xml && adb -s <DEVICE_ID> pull /sdcard/view.xml ./view.xml

Take a screenshot and optionally compress:

adb -s <DEVICE_ID> shell screencap -p /sdcard/screen.png
adb -s <DEVICE_ID> pull /sdcard/screen.png ./screen.png
cwebp -q 60 -resize 540 0 ./screen.png -o ./screen.webp

Natural-language tasks for the agent (examples in the Skill README) can be: “Connect to 192.168.1.100:5555 and open WeChat,” “Take a screenshot of the current screen on the device,” “Click the Login button.” The agent should choose the above scripts and ADB commands according to the Skill’s constraints rather than invent undocumented interfaces.

Use Cases and Caveats

Who It’s For

  • Users already using or planning to use DuoPlus Cloud Phones who want to have agents like Cursor / Claude Code / Codex orchestrate “tap, swipe, form filling, screenshot verification.”
  • Automation that can accept step-by-step screenshot or dump verification (since broadcast commands do not return execution results).

Limitations and Prerequisites

  • The device must be running DuoPlus-related services; the broadcast action is com.duoplus.service.PROCESS_DATA.
  • The host must have adb reachable to the target DEVICE_ID; in wireless scenarios, run adb connect first.
  • The Skill is an instruction set for agents, not a standalone SaaS; cloud phone accounts, instances, and networking are provisioned and maintained on the DuoPlus side.
  • It is a community-sourced Skill; before using it in production, it is recommended to run the full flow on an isolated instance.

Current SkillHub statistics (as of the data retrieved): rating 100000, downloads 2711, installs 33.

Conclusion

duoplus-agent converges DuoPlus cloud phone control into a fixed pattern: “ADB connection + send_command.sh JSON actions + screenshot/UI dump verification,” making it easier for agents to reproduce steps within conversations. If you want your agent to control DuoPlus cloud phones, install from the official Skill page and read the bundled SKILL.md:

https://www.skillhub.cn/skills/user_1df07c13/duoplus-agent

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye