Easier control of the phone

There is several way to avoid having to type out every command with the phone touch keyboard, which can be cumbersome and prone to errors.

  • Using an external bluetooth or USB keyboard with an adapter
  • Remote connection via Open SSH
  • Mirroring the phone’s screen on an other device with src-cpy

Mirroring phone screen via src-cpy

scr-cpy

scr-cpy is a command line tools that helps take control of an android smartphone by connecting to it via Wi-Fi or USB. It’s available on Mac, Windows and Linux.

Installation

Careful, the packaged versions below are obsolete, but will work with old devices. For latest version see build instructions.

For Linux: $ apt install scrcpy For Mac: $ brew install scrcpy

Information

  • Compatible with Android 5.0 and +.
  • The documentation is available on Github here

Usage

1. Configure the phone

Your phone must be configured with enabled USB debugging.

  1. Enable Developer options:
    • On Android 4.1 and lower, the Developer options screen is available by default. On Android 4.2 and higher, you must enable this screen
    • Find the Build Number info. Go to Settings > About phone > Build number or similar. If you don’t find it: search ā€˜build number’
    • Tap the Build Number option seven times until you see the message You are now a developer! This enables developer options on your device.
    • Return to the previous screen to find Developer options at the bottom.
  2. Enable USB debugging
    • Go to: Settings > System > Advanced > Developer Options > USB debugging or similar. If you don’t find it: search ā€˜debugging’
    • Toggle and confirm enabling USB debugging.

2. Mirror screen

  1. Connect you phone to your laptop with a USB cable that can transmit data (not just charging).
  2. Open the terminal, make sure you have scrcpy installed
  3. type scrcpy and press enter.
  4. Your computer screen should appear

3. Other options

Use scrcpy --otg for keyboard and mouse only