Search code examples
androidshelladbvideo-recordingscreen-recording

Android: how to make two screenrecord at same time?


Now I make

adb shell screenrecord sdcard/video.mp4

It works with one device. If I had two devices connected via USB running at the same time how could I start two video recording?


Solution

  • First get your device ids :

    >adb devices
    List of devices attached 
    emulator-5554   device
    7f1c864e        device
    

    Then run your recording with :

    >adb -s emulator-5554 shell screenrecord sdcard/video.mp4
    >adb -s 7f1c864e shell screenrecord sdcard/video.mp4
    

    As documentation says, you cannot save directly to your computer memory :

    To begin recording your device screen, run the screenrecord command to record the video. Then, run the pull command to download the video from the device to the host computer. Here's an example recording session:

    $ adb shell
    shell@ $ screenrecord --verbose /sdcard/demo.mp4
    (press Ctrl-C to stop)
    shell@ $ exit
    $ adb pull /sdcard/demo.mp4