Mirroring Android Screen on Ubuntu
Mirroring the screen of your android phone on ubuntu via USB can be done by following the following steps.
I have tested the app using Android 9 on Ubuntu 20.10
The application:
Scrcpy - https://github.com/Genymobile/scrcpy
"This application provides display and control of Android devices connected on USB (or over TCP/IP). It does not require any root access."
[Facts]
- Allows a window on the laptop to use to control your Android phone
- Easy for developers to drag drop from laptop and install apk directly
- Playing games is nice on laptop
- The interaction is real-time
- Its open source
- use of mouse and keyboard
Installation on Ubuntu
apt install scrcpy -y
Developer Mode on Android
On the Android Phone, enable Developer Options for USB debugging
For Android 4.2 and newer, Developer options is hidden by default; use the following steps:
- On the device, go to Settings > About <device>.
- Tap the Build number seven times to make Settings > Developer options available.
- Then enable the USB Debugging option.Tip: You might also want to enable the Stay awake option, to prevent your Android device from sleeping while plugged into the USB port.
For more information, see Unlocking Jelly Bean and Higher Devices
USB Debugging on Android
- Go to settings, tap system
- Tap on Developer Options
- On DEBUGGING section, check USB Debugging
Using scrcpy on laptop,
- Ensure the phone is connected via USB to the laptop
- On terminal, type scrcpy
root@KD2A-vivobook:~# scrcpy
INFO: scrcpy 1.14 <https://github.com/Genymobile/scrcpy>
/usr/share/scrcpy/scrcpy-server: 1 fil...shed. 0.7 MB/s (31693 bytes in 0.045s)
[server] INFO: Device: HUAWEI VKY-L29 (Android 9)
INFO: OpenGL shaders: ENABLED
INFO: Created renderer: opengl
- Accept the connection on the phone, click on OK
The mirror screen will popup