Catégorie : Logiciels Libres
Affichages : 3361

ubuntu logo32Toujours grâce à Sébastien Sauvage, voici un moyen de piloter son ordiphone (au moins sous Android 5.0) à partir de son ordinateur sous Ubuntu : https://sebsauvage.net/links/?21CrwQ. Le post originel se situe ici : https://www.linuxuprising.com/2019/03/control-android-devices-from-your.html

Il peut être utile, lors d'une présentation notamment, d'afficher l'écran de son ordiphone pour faire une démonstration et même de pouvoir faire une capture de son écran (screencast). C'est possible avec les manip décrites dans les pages évoquées ci-dessus grâce à l'application SCRCPY.

Site du projet scrcpy : https://github.com/Genymobile/scrcpy

I- Installation sous Ubuntu 18.04

II- Lancement de scrcpy par liaison USB

III- Lancement de scrcpy par liaison Wifi (moins fluide)

IV- Options utiles

    -b, --bit-rate value
        Encode the video at the given bit-rate, expressed in bits/s.
        Unit suffixes are supported: 'K' (x1000) and 'M' (x1000000).
        Default is 8000000.

    -c, --crop width:height:x:y
        Crop the device screen on the server.
        The values are expressed in the device natural orientation
        (typically, portrait for a phone, landscape for a tablet).
        Any --max-size value is computed on the cropped size.

    -f, --fullscreen
        Start in fullscreen.

    -F, --record-format
        Force recording format (either mp4 or mkv).

    -h, --help
        Print this help.

    -m, --max-size value
        Limit both the width and height of the video to value. The
        other dimension is computed so that the device aspect-ratio
        is preserved.
        Default is 0 (unlimited).

    -n, --no-control
        Disable device control (mirror the device in read-only).

    -N, --no-display
        Do not display device (only when screen recording is
        enabled).

    -p, --port port
        Set the TCP port the client listens on.
        Default is 27183.

    -r, --record file.mp4
        Record screen to file.
        The format is determined by the -F/--record-format option if
        set, or by the file extension (.mp4 or .mkv).

    -s, --serial
        The device serial number. Mandatory only if several devices
        are connected to adb.

    -t, --show-touches
        Enable "show touches" on start, disable on quit.
        It only shows physical touches (not clicks from scrcpy).

    -T, --always-on-top
        Make scrcpy window always on top (above other windows).

    -v, --version
        Print the version of scrcpy.

IV- Raccourcis clavier

Ctrl+f : bascule en mode plein écran

Ctrl+g : redimensionne la fenêtre en 1:1 (pixel-perfect)

Ctrl+x : double-clic sur les bordures noires, redimensionne la fenêtre pour enlever les bordures noires.

Ctrl+h : Home, clic milieu, clic sur HOME

Ctrl+b : Ctrl+Backspace,
    Right-click (when screen is on)
        click on BACK
Ctrl+s : click on APP_SWITCH

Ctrl+m : clic sur MENU

Ctrl+Up : clic sur VOLUME +

Ctrl+Down : clic sur VOLUME -

Ctrl+p : clic sur POWER (allume/éteint l'écran)

Clic droit (quand l'écran est éteint) : rallume l'écran

Ctrl+n : étend le panneau de notification

Ctrl+Shift+n : réduit le panneau de notification

Ctrl+v : colle le contenu du presse-papier de l'ordinateur vers le smartphone

Ctrl+i : active/désactive le nombre de frame/sec (écrit les frames/seconde dans les logs)

Glisser & déposer un fichier APK : installation sur le smartphone