Skip to content

Sigmachan/dexwire

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dexwire

Run real Android apps and games from your phone/tablet as windows on your PC — no emulation.

dexwire is a thin, standalone CLI over scrcpy 4.0 that turns any connected Android device into a Samsung-DeX-style experience on Linux (built and tested on CachyOS / KDE Plasma 6 Wayland). Each app runs on the device's own hardware and appears as its own resizable desktop window on the PC, with audio and keyboard/mouse/gamepad input.

It's not an emulator and not a VM — the apps execute on real Android, dexwire just orchestrates scrcpy's virtual-display feature and adds the desktop glue (KDE launchers, games profile, wireless-adb auto-connect, killswitch integration).

Why

scrcpy 4.0 already does the hard part (--new-display + --start-app + --gamepad + --flex-display). What it lacks for a real "apps on my desktop" workflow is the glue: an app picker, per-app KDE menu launchers, sensible desktop/games profiles, a resizable window that actually re-lays-out the Android side, and one-command device handling. dexwire is that glue.

Features

  • Per-app windowsdexwire launch <app> opens one Android app in its own PC window (scrcpy --new-display --start-app=+<pkg>), running on the device.
  • Truly resizable (DeX-style) — uses --flex-display, so dragging the window resizes the Android virtual display and the app re-lays-out (not just scaling). Phone-only apps are made resizable via force_resizable_activities.
  • Games profiledexwire games <app> adds --gamepad=uhid, low-latency/perf flags, and a bigger bitrate for Android games with a real controller.
  • KDE menu integrationdexwire export <app> writes a .desktop launcher so the Android app shows up in your application menu (games land under the Games category).
  • App pickerdexwire apps lists installed apps (parsed from scrcpy --list-apps).
  • Wireless or USB — auto-connects to a configured wireless-adb endpoint, falls back to a single USB device; fails fast and clearly when the device is unreachable (no silent fallbacks).
  • killswitch-aware — registers with killswitch so the stream is paused (GPU encoder freed) while a PC game is running.
  • Persistent config~/.config/dexwire/config.json (device, profiles, audio).

Requirements

  • scrcpy 4.0+ and adb (android-tools) in PATH
  • An Android device with USB or wireless debugging enabled
  • (optional) KDE/any freedesktop menu for export; killswitch for the auto-pause integration

Install

install -m755 dexwire ~/.local/bin/dexwire
dexwire config init           # writes ~/.config/dexwire/config.json
dexwire config set-device auto # or 192.168.x.y:5555 for wireless adb
dexwire doctor                # check scrcpy/adb/device

Usage

dexwire apps                       # list installed apps
dexwire launch "Firefox"           # one app in its own desktop window
dexwire launch org.mozilla.firefox # by package id
dexwire desktop                    # a full Android desktop in a new display
dexwire games "Dead Cells"         # games profile (gamepad + perf)
dexwire export "Dead Cells" --games   # add a KDE menu launcher
dexwire export-all                 # menu launchers for every app
dexwire unexport --all             # remove dexwire launchers
dexwire launch X --dry-run         # print the scrcpy command without running

Pass extra scrcpy flags after --extra:

dexwire launch X --extra --turn-screen-off --stay-awake

Profiles

Edit ~/.config/dexwire/config.json. Defaults:

  • desktop--new-display=1920x1080/240, --flex-display, free resize, audio on.
  • games--new-display=1920x1080/160, --gamepad=uhid, --max-fps=60, --video-bit-rate=20M, --flex-display.

Tests

python3 test_dexwire.py

How it works

dexwire builds and runs:

scrcpy -s <device> --new-display=<WxH/dpi> --start-app=+<package> [--gamepad=uhid] --flex-display ...

The --new-display recipe and the --list-apps parser are adapted from escrcpy (desktop/electron/middleware/scrcpy/{index.js,helper.js}); scrcpy itself is the engine.

Credits

dexwire stands entirely on these projects:

  • scrcpy (Genymobile, Apache-2.0) — the display/audio/input engine.
  • escrcpy (viarotel-org, Apache-2.0) — the per-app virtual-display launch recipe and --list-apps parser were adapted from it.
  • Android-Dex (Shrey113) — UX inspiration (per-app audio, multi-app desktop); no code used.

See NOTICE.

License

Apache-2.0. See LICENSE.

About

Run real Android apps & games as resizable PC windows via scrcpy 4.0 — no emulation. DeX-style per-app virtual displays, gamepad games profile, KDE launchers, killswitch. Linux/Wayland.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages