Recently I wanted to create a screen capture on my Android phone to make a video on how to do something on Android. When looking around for "record android phone" or "create android video" it just led me to different applications. Then I got lucky and found that recording your phone is built in to the Android SDK. The steps below outline how to create a video of activity on your Android phone. (I tested this on an Moto X and Moto G, running Android 4.4)
Instructions and information are detailed in black font with no decoration.
Code and shell text are in black font, gray background, and a dashed border.
Input is green.
Literal keys are enclosed in brackets such as [enter], [shift], and [ctrl+c].
- On your Android phone, go to Settings -> About Phone. Then click "Build Number" 7 times, this enables developer options.
- On your Android phone, go to Settings -> Developer Options -> Debugging, check the box to enable USB Debugging.
- On your computer, download and install Java Runtime, https://www.java.com/en/download/manual.jsp
- On your computer, download your phone's drivers. For Motorola go here: https://motorola-global-portal.custhelp.com/app/answers/detail/a_id/88481. For other phones, make sure the driver includes the ADB driver, or Android Debug Bridge Driver.
- On your computer, download and install the Android SDK from here: https://developer.android.com/sdk/index.html. It is easiest if you scroll down and select "View All Downloads" and then download "SDK Tools Only" for your system.
- On your computer, connection your phone using a USB cable.
- On your phone, unlock the screen.
- On your phone, drag down the top menu and verify that your phone is listed as "Connected as a Camera." If it says "Connected as Media Device" then click where it says that and change the check box to Camera (PTP).
- On your computer, open command prompt / command line / console / terminal.
- On your computer, type
- On your computer, it will list your connected devices.
List of devices attached
T06620669M - Device
- On your computer, type
adb shell screenrecord /sdcard/myrecord.mp4[enter] This will begin the screen recording. Note that it will appear as if the console is hung, it does not flash or display anything.
- On your phone, perform the tasks you wish to record.
- On your computer, use an escape sequence to stop the recording
- On your computer, download the video, in the console type
adb pull /sdcard/zone73.mp4 c:/zone73.mp4[enter]
- Allow the download to complete.
- The video is available for you.
Keep in mind that when recording, orientation changes on the screen do not translate well to video. So if you start vertical and launch an application that moves to horizontal, the video will be cut off. Record the video after orientation is established. Additional options are available with the adb screenrecord command, review the developer options from the link below.
This document is my own and does not represent anything from any other entity. I will not be held liable for anything bad that comes of it.
Written by Eric Wamsley
Posted: October 18th, 2014 5:21pm