Skip to content

Android Installation

Joris Borgdorff edited this page Dec 15, 2016 · 1 revision

Downloading Android image

Installing Android image on Mac OS

Formatting SD card

We need a SD card formatted with FAT32 file system.

  • Open Disk Utility
  • Select the device. In my case Apple SDXC Reader Media
  • Click Erase
  • Select MS-DOS (FAT) as format and GUID Partition Map as scheme
  • Click Erase

Disk Utility image

Installation

  • Open a terminal and run df -h
  • Connect the SD card reader with the SD card inside
  • Run df -h and look for the new device that was not listed before. In my case the device is /dev/disk2s2
  • Unmount the partition sudo diskutil unmount <partition>. In my case sudo diskutil unmount /dev/disk2s2
  • Infer the device name raw from the partition, removing the final s1 and adding a r. Therefore /dev/disk2s2 becomes /dev/rdisk2
  • Write the image to the card sudo dd bs=1m if=<img-path> of=<raw-name>. In my case sudo dd bs=1m if=Desktop/andrpi3-20160626.img of=/dev/rdisk2. This command does not provide any information until the end.
  • When dd command terminates, eject the device running sudo diskutil eject <raw-name>. In my case sudo diskutil eject /dev/rdisk2

Terminal result

Setting up the single-board computer

  • Connect at least the mouse by USB. If possible connect also a keyboard
  • Connect the HDMI cable
  • Insert the SD card containing the OS
  • Connect the power adaptor
  • Android will automatically boot

Setting up Android

  • Go to Settings > Wi-Fi
  • Sign in on your Wi-Fi connection
  • Go to Settings > Developer options
  • Enable USB debugging
  • Go to About tablet > Status > IP address and note down device's IP
  • Connect your laptop to the same network of Pi
  • Open a terminal and run ./adb connect <DEVICE-IP>:5555. You are now ready run and debug your Android application on the board
  • Alternatively, on your terminal run ./adb shell ip -f inet addr show wlan0. This command automatically finds the IP of your device
  • For shutting down your device open a terminal and run ./adb shell reboot -p

Installing Android image on Windows

See the video until 5:10 minute

Installing Android image on Ubuntu

See the video

Sources