noccylabs/android

$ git tag
0.1.0

$ git branch
* master

Android/ADB Interface for PHP

Usage

Get device

To use a specific device:

$device = new Adb\Device($serial);

To use the default device:

$device = new Adb\Device();

To enumerate devices:

$devices = new Android\DeviceList();
foreach ($devices as $device) { ... };

Info, props and packages

Get information:

$serial = $device->getSerial();
$model = $device->getModel();
$vendor = $device->getVendor();

Get props:

$props = $device->getPropList();
$props->each($key,$value) { ... };
$val = $props->get("prop.key");

Get package list:

$packages = $device->getPackageList();
$packages->each($package) { ... };
$package = $packages->get("package.name");

Debugging

Use DEBUG_EXEC to trace all the exec() calls including those to adb:

$ DEBUG_EXEC=1 command