Skip to main content

XPDC (X-Platform Device Connector) is designed to bridge the gap between devices across multiple platforms (Android, HarmonyOS, iOS).

Project description

pyecharts logo

Introduction

XPDC (X-Platform Device Connector) is designed to bridge the gap between devices across multiple platforms (Android, HarmonyOS, iOS).

It allows users to operate devices on different platforms with the same set of code.

Before using XPDC, you need to install the corresponding debug environment separately for each platform's device.

Android is adb, HarmonyOS is hdc

Installation

# Using uv
pip install uv
uv add xpdc

# Using pip
pip install xpdc

Quick Start

Install Dependencies

from xpdc import connection, DeviceType

# Specify connect device type
conn = connection(DeviceType.ADB)
# conn = connection(DeviceType.HDC)
# iOS will support it in the future.

conn.cmd(['devices'])

device = conn.devices[0]
# You can also specify the device by its device id
# device = conn.device(device_id='device_id')

device.tap(500, 500)
device.type_text(text='lanbaoshen')
device.screenshot()
device.cmd(cmd=['shell', 'ls'])
device.shell(cmd=['ls'])

# For Android devices, additionally install ADBKeyboard.apk and enable it to support Chinese input.
device.install_and_set_adb_keyboard()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

xpdc-0.1.2.tar.gz (7.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

xpdc-0.1.2-py3-none-any.whl (10.3 kB view details)

Uploaded Python 3

File details

Details for the file xpdc-0.1.2.tar.gz.

File metadata

  • Download URL: xpdc-0.1.2.tar.gz
  • Upload date:
  • Size: 7.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for xpdc-0.1.2.tar.gz
Algorithm Hash digest
SHA256 c7f9dd02df5b99dd7b3170d1ba2d10f47334d8b27722d9dbb09301601355f9bf
MD5 bc1c3fdf6afad62290ff78d9ba119779
BLAKE2b-256 9969c59ed9109aebadce3cfd6c019b8f9eb545366f3f080d4c9d0c00740ef537

See more details on using hashes here.

File details

Details for the file xpdc-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: xpdc-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 10.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for xpdc-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 2b6c352feeadf16091576134b613238bf0e69ee9ba867f62114a83b859cbbc01
MD5 5956f684c5c9e02e45a1fdaeac43b13c
BLAKE2b-256 cb369c83d7c20e7c021a6e0cf55e94ec861f48d32387bd64f99927763168d21a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page