Android Debug Bridge¶
Important
Android Debug Bridge (adb) is required ONLY for those users pairing an Android mobile device with Cozmo.
Android Debug Bridge (adb) is necessary in order for the Cozmo SDK to work with Android mobile devices. Please ensure adb is installed before attempting to run the Cozmo SDK with a paired Android device.
macOS Installation¶
Type the following into a Terminal window (requires Homebrew to be installed):
brew tap caskroom/cask brew cask install android-platform-tools
Continue to Final Installation (All Platforms) below to complete installation.
Windows Installation¶
- In your internet browser, navigate to this link and download file
platform-tools-latest-windows.zip
to your Downloads folder. - Open a File Explorer window to your Downloads folder and see that your downloaded file
platform-tools-latest-windows.zip
is there. - Open a new File Explorer window and create a new folder in
C:\Users\your_name
namedAndroid
. Then, navigate into your new Android folder. You should now be inside folderC:\Users\your_name\Android
. - Move the zip file you downloaded in step 1,
platform-tools-latest-windows.zip
, to your new Android folder atC:\Users\your_name\Android
. - Right-click the
platform-tools-latest-windows.zip
file inC:\Users\your_name\Android
and select Extract All. - With File Explorer, navigate to
C:\Users\your_name\Android\platform-tools-latest-windows\platform-tools
and confirm that the adb is there. You will now add this path to your PATH environment variable in the next step. - Add adb to your PATH environment variable.
- Right-click the Start menu and select System.
- Select Advanced System Settings -> Advanced -> Environment Variables.
- Under User Variables, select PATH and click Edit.
- Under Edit Environment Variables, click New and add the path to the folder containing adb (e.g.
C:\Users\your_name\Android\platform-tools-latest-windows\platform-tools
). Click OK on all dialog boxes to confirm your change.
- Confirm that the PATH is correctly pointing to adb.
- Open new a Command Prompt window. (To find the Command Prompt, you may use the search box in the lower left-hand corner of your screen.)
- Type
adb
and adb instructions should print out.
- Continue to Final Installation (All Platforms) below to complete installation.
Linux Installation¶
In your internet browser, navigate to this link and download file
platform-tools-latest-linux.zip
. You may need to accept the license before downloading.Navigate to the zip file download location (e.g., ~/Downloads) and extract the files. The files will be extracted to folder
platform-tools
.In your home directory, create folder
android-sdk-linux
:cd ~ mkdir android-sdk-linux
Move the extracted
platform-tools
folder to your newandroid-sdk-linux
folder:mv Downloads/platform-tools android-sdk-linux
Confirm you see adb inside
platform-tools
:cd android-sdk-linux/platform-tools ls adb
Add adb to your PATH.
Edit your ~/.bashrc file and add this line:
export PATH=${PATH}:~/android-sdk-linux/platform-toolsSave .bashrc and then call:
source .bashrcConfirm that adb is in your PATH by calling the following command:
which adbThe result of this command should be the path where adb is installed.
- Continue to Final Installation (All Platforms) below to complete installation.
Final Installation (All Platforms)¶
- Enable USB Debugging on your phone.
- On Android devices:
- Tap seven (7) times on the Build Number listed under Settings -> About Phone.
- Then, under Settings -> Developer Options, enable USB debugging.
- On Amazon Kindle Fire:
- Tap seven (7) times on the Serial Number listed under Settings -> Device Options.
- Then, under Settings -> Device Options -> Developer Options, turn on Enable ADB.
Connect your Android device to your computer via USB. When the Allow USB Debugging? popup displays, tap OK.
At the command line, type this command to confirm that your device shows:
adb devices
At least one device should show in the result, for example:
List of devices attached 88148a08 deviceIf you are required to accept the connection request on the mobile device itself, a message will appear saying the device is unauthorized. For example:
List of devices attached 88148a08 unauthorized