Controlling your phone without holding it is easy. Just set up Scrcpy and then just launch the app.
The function of controlling your smartphone from a PC has been tested for quite some time by owners of Samsung devices, but what about if you have a gadget from another manufacturer? Very unfortunate, but even my reference Google Pixel doesn't support such a feature without the use of third-party software. Well, let the cooperation between Microsoft and Samsung continue, and you and I will use an alternative solution to this interesting problem.
Hard to believe, but you and I won't have to install any apps on our smartphone, it doesn't even need to have Root access!
Scrcpy - An open-source program from a GitHub developer that not only allows you to stream an image from your Android smartphone display to your PC, but also to Control your smartphone directly from your computerTo which the image is transferred. Transferring a file and installing applications with a simple drag and drop is very convenient!
Installing and running scrcpy
To install the program, you need to do the following steps:
1. Download the latest version:
- File name: scrcpy-win64-v2.3.1.zip
- File size: 5.77 MByte
- Requirement: Windows x64
- File name: scrcpy-win32-v2.3.1.zip
- File size: 5.65 MByte
- Requirement: Windows x86
2. Create a folder "scrcpy“.
3. Copy the contents of the archive there.
This completes the installation of the program! Before using it you need to configure the smartphone from which you will broadcast the picture:
- Go to "About phone" and enable developer mode there. To do this, press 7 times either on assembly number device if you have "pure" Android, or to the MIUI version if you have MIUI.
- In the developer menu, you need to enable the "USB debugging", "USB Debugging (Security Settings)" and "USB Installation" (if you need sound).
- Connect your smartphone to your computer using a USB cable.
- Be sure to check the box "Always allow debugging from this computer" and press "Authorize“.
Now the device is ready to broadcast the picture to the PC. Now let's make sure that the PC can communicate with the smartphone:
- Launch "Command Prompt" by pressing Win+R and entering "cmd"..
- Go to the folder scrcpyby entering "cd c:/scrcpy."if the folder is in the root of the c:/ drive and run the command "adb shell ip route“ to get the IP address of the device, press Enter.
- Enter “adb tcpip 5555“, press again Enter.
You can now disconnect the smartphone cable from the computer. Connect to the device using the command “adb connect DEVICE_IP:5555“ (where DEVICE_IP is the IP address of the device. The result should be something like: "adb connect 192.168.0.2:5555“).
Finally, start the broadcast with the command "scrcpy“Press Enter on the keyboard again.
If done correctly, a window should appear with the contents of your smartphone's display in the same orientation as the smartphone itself.
Full list of keyboard shortcuts
Action | Key combination |
---|---|
Switching full screen mode | Left Alt+f |
Turn the display to the left | Left Alt+← (left) |
Turn the display to the right | Left Alt+→ (right) |
Resize window to 1:1 (pixel-perfect) | Left Alt+g |
Resize window to remove black borders | Left Alt+w | Double-left-click |
Press the HOME button | Left Alt+h | Middle-click |
Press the BACK button | Left Alt+b | Right-click |
Click on APP_SWITCH | Left Alt+s | 4th-click |
Click on MENU (unlock screen) | Left Alt+m |
Click on VOLUME_UP | Left Alt+↑ (up) |
Click on VOLUME_DOWN | Left Alt+↓ (down) |
Click on POWER | Left Alt+p |
Power on | Right-click |
Turn device screen off (keep mirroring) | Left Alt+o |
Turn on the device screen | Left Alt+Shift+o |
Rotating the device screen | Left Alt+r |
Expand the notification panel | Left Alt+n | 5th-click |
Expand the settings panel | Left Alt+n+n | Double-5th-click |
Collapse panels | Left Alt+Shift+n |
Copy to clipboard | Left Alt+c |
Cut to clipboard | Left Alt+x |
Synchronize clipboards and paste | Left Alt+v |
Inject computer clipboard text | Left Alt+Shift+v |
Enable/disable FPS counter (on stdout) | Left Alt+i |
Pinch-to-zoom | Ctrl+click-and-move |
Drag & drop APK file | Install the APK from your computer |
Drag & drop non-APK file | Transferring a file to a device |
Configuring broadcast parameters
The program allows you to set some parameters for the transmitted image. Let's touch the main ones:
- Changing the resolution: “scrcpy -m 1024“. After -m If you specify the number of vertical pixels, the program will automatically adjust the number of horizontal pixels according to the aspect ratio of your device.
- Bitrate change: "scrcpy -b 2M". After -b sets the required bitrate, which is 8 Mbit by default.
- Limiting the number of frames: “scrcpy -max-fps 15". After -max-fps sets the required number of frames.
To apply several parameters at once, you need to write them sequentially, for example, as follows: "scrcpy -m 1024 -b 2M -max-fps 15“.
A complete list of parameters can be viewed at GitHub page
Audio broadcasting
To transmit sound, you need to install and run the program sndcpywhich can also be downloaded from GitHub (you need to download the archive called "sndcpy-with-adb-windows"). It is worth specifying that for sound transmission you need Android 10 and installed on the computer VLC player.
- Install sndcpy in a manner similar to scrcpy.
- Connect your smartphone to your computer using a USB cable
- Click Win+R and in the window that opens, type “cmd", press OK.
- At the command prompt, type "cd c:/sndcpy", click Enter.
- Then enter "sndcpy", press again Enter.
- A program will be installed on your smartphone that will ask for permission to broadcast audio, click "Start".
- At the command prompt, press Enter. VLC may generate an error, just ignore it.
The sound will continue to play from your smartphone, to get rid of it, just turn the volume down to zero. It is adjusted on the two devices independently of each other. To stop the sound transmission, you need to either disconnect the cable from the device or press the corresponding button on the notification panel of your smartphone.
After the opening Scrcpy you can also use keyboard shortcuts to control screen rotation. Simply press the left Alt + arrow key to rotate the screen in that direction.
Difficult?
If you are a big fan of SCRCPY, but you don't really like using the command line for all the custom options and features of the application, then I suggest you use the SCRCPY GUI solution, which will make using SCRCPY a much simpler process.
SCRCPY is one of the most popular ways to view and control Android devices on Windows, Linux and macOS PCs. It's easy to set up, easy to use and works great both in the wiredand in wireless modes. The only real problem with SCRCPY is the way you enter options and commands. Because it requires the Command Line and a list of commands, most people can't either don't want to take full advantage of SCRCPY.
Fortunately, there is an alternative to using SCRCPY exclusively from the Command line
. It will give you a full graphical user interface with most of the basic functions and commands that people use in SCRCPY. This means that you can simply click a button to enable or disable certain features in SCRCPY. The only drawback is that not all commands are available.
Scrcpy-Plus
As mentioned above, Scrcpy-Plus is the easiest tool to use with the SCRCPY GUI. Just make sure you pre-configure SCRCPY and then run Scrcpy-Plus. The best part is that it comes in two variants: standard Windows installation and portable Version. It is necessary to link PC and Android device!
In developer mode on your Android On your device, select "Debug via Wi-Fi" and then "Connect your device using the connection code". In the app Scrcpy+and click [su_icon_text color="#8867c0″ icon="icon: link" icon_color="#886767c0″ icon_size="20″] CONNECT WIRELESSLY[/su_icon_text]
Next, you need to enter the "Wi-Fi connection code" and the "IP address and port". Press the "CONNECT" button, and then you will need to specify the "IP address and port" again (it may not have changed). Success!
It's done! In the "Device" section, information about your Android device appears. Scroll down and press "START SCRCPY".