Scrcpy for Android
Estas notas son más bien para aquellos profesores que quieran usar esta herramienta durante sus clases
Visualize cellphone screen on desktop or laptop
Sometimes it may be useful to visualize the screen of your cell phone, or tablet, on the monitor of your laptop or desktop (which in turn can be projected on the CCA screen). All the instructions below apply to an Android device. Scrcpy stands for screen copy.
Here go some notes on how to achieve it on a CCA machine.
Enable debug option
The cellphone or tablet must have the "Developer Options" enabled. To do that, follow the instructions in https://developer.android.com/studio/debug/dev-options
Scrcpy usage
- Connect the Android device (phone or tablet) to the machine, for example japon, with the appropriate cable
- Launch scrcpy by typing
scrcpyon a terminal window
You may get a message on the phone or tablet about giving permissions, like "Allow USB debugging?" or similar. Answer yes or mark the appropriate checkbox.
Troubleshooting
- If scrcpy issues some sort of error messages, check if your device is correctly recognized with the command:
adb devices
If you get the device ID followed by "unauthorized", you may need to reset (disable and enable again) the "USB Debug" option. The device can then ask you for permission to establish the connection. - If the device is not recognized, you may try to stop and start again the adb server:
sudo adb kill-serverfollowed by:sudo adb start-server(administrative access required) - If launching scrcpy you get an error message like:
"ERROR: Could not open video stream"
modify the size of the window with, for instance,scrcpy -m 1280(you might try different values and see which works best).
Shortcuts
Action Shortcut ================================================================= switch fullscreen mode Ctrl+f resize window to 1:1 (pixel-perfect) Ctrl+g resize window to remove black borders Ctrl+x | Double-click (1) click on HOME Ctrl+h | Middle-click click on BACK Ctrl+b | Right-click (2) click on APP_SWITCH Ctrl+m click on VOLUME_UP Ctrl++ click on VOLUME_DOWN Ctrl+- click on POWER Ctrl+p turn screen on Right-click (2) paste computer clipboard to device Ctrl+v enable/disable FPS counter (on stdout) Ctrl+i
(1) Double-click on black borders to remove them.
(2) Right-click turns the screen on if it was off, presses BACK otherwise.
Tools for drawing on cellphone or tablet
- Simple draw (Android app)
- Adobe Illustrator Draw (Android App - requires registration on Adobe)
- www.youidraw.com (requires login with Google or Facebook)
- https://sketch.io/sketchpad/ (very good)