Hey, what’s up. Android is the most widely used mobile operating system in the world. Also, it’s an open-source system run by Google, but it’s based on Linux. Currently, its most recent version is number 10. On the other hand, the possibility of casting the screen is present since version 5.0. Well, in this post we will see how to cast an android screen in Ubuntu 18.04. With this intention, we’ll use Scrcpy. This is a free, open-source application that allows you to view and control Android devices connected via USB or wirelessly. It offers 30 ~ 60 FPS with a resolution that can go up to 1920×1080. In addition, the communication between the server and the client is done through ADB. But perhaps its most interesting feature is that it does not require Root on android. So let’s get down to business.
- An Android device with at least 5.0 version
- It is necessary to enable ADB debugging. On some devices, it is also necessary to enable USB debugging in the security options. In fact, this function is essential to manage the Android device via USB.
- ADB and Fastboot installed. To download and install it, simply run this command:
sudo apt-get install android-tools-adb android-tools-fastboot
After installation, check the version of ADB with the following command:
We must obtain a result similar to this:
- An android device connected to the computer via USB It is also possible to connect via wireless. However, the connection loses effectiveness.
Step 1. Install the scrcpy snap package.
The Snapd package is present from Ubuntu 16.04 so there is no need to install it. So to install Scrcpy please run the following command:
sudo snap install scrcpy
This snap package is updated with the latest version of scrcpy available. It also installs the snap core dependency needed to run the program.
Step 2. Connect the phone via USB.
Once the preparations are done, you just have to connect the phone with the USB cable.
Step 3. Start Scrcpy.
Then from the terminal, you run the following command:
Please note that the Android device screen must be unlocked. Also, confirm the USB connection by accepting the pop-up window on your phone.
Once the program is started, it is possible to manage and transmit the Android screen in Ubuntu.
To stop the Scrcpy server, just run this command.
And if you finally decide to uninstall it, then from the terminal run it:
sudo snap remove scrcpy
Finally, we have seen how to cast the android screen in Ubuntu 18.06. As you can see, it is a simple procedure that allows you to manage the android device from the Ubuntu machine. This is all for the moment, before saying goodbye I invite you to see our post about fixing errors in Windows 10.