Skip to content

Most visited

Recently visited


Raspberry Pi 3

Raspberry Pi 3 Model B is the latest iteration of the world's most popular single board computer. It provides a quad-core 64-bit ARM Cortex-A53 CPU running at 1.2GHz, four USB 2.0 ports, wired and wireless networking, HDMI and composite video output, and a 40-pin GPIO connector for physical interfacing projects.


See Raspberry Pi I/O for more details on the Peripheral I/O signals on this board.

Flashing the image

Before you begin flashing, you will need the following items in addition to your Raspberry Pi:

To flash Android Things onto your Raspberry Pi, download the latest preview image and follow these steps:

  1. Insert an 8 GB or larger microSD card into your development computer.
  2. Unzip the downloaded image archive on your development computer. Navigate to the unzipped image file.

  3. Follow the official Raspberry Pi instructions for writing the image to the SD card:

  4. Insert the flashed microSD card into your board.

  5. Make the following connections to your board:


    1. Connect a USB cable to J1 for power.
    2. Connect an Ethernet cable to your local network.

    3. Connect an HDMI cable to an external display.

  6. Verify that Android is running on the device. The Android Things Launcher shows information about the board on the display, including the IP address.

  7. Connect to this IP address using the adb tool:

    $ adb connect <ip-address>
    connected to <ip-address>:5555

Connecting Wi-Fi

After flashing your board, it is strongly recommended to connect it to the internet. This allows your device to deliver crash reports and receive updates.

To connect your board to Wi-Fi using adb:

  1. Send an intent to the Wi-Fi service that includes the SSID and passcode of your local network:

    $ adb shell am startservice \
        -n \
        -a WifiSetupService.Connect \
        -e ssid <Network_SSID> \
        -e passphrase <Network_Passcode>
  2. Verify that the connection was successful through logcat:

    $ adb logcat -d | grep Wifi
    V WifiWatcher: Network state changed to CONNECTED
    V WifiWatcher: SSID changed: ...
    I WifiConfigurator: Successfully connected to ...
  3. Test that you can access a remote IP address:

    $ adb shell ping
    PING ( 56(84) bytes of data.
    64 bytes from icmp_seq=1 ttl=57 time=6.67 ms
    64 bytes from icmp_seq=2 ttl=57 time=55.5 ms
    64 bytes from icmp_seq=3 ttl=57 time=23.0 ms
    64 bytes from icmp_seq=4 ttl=57 time=245 ms

If you want to clear all of the saved networks on the board:

$ adb shell am startservice \
    -n \
    -a WifiSetupService.Reset

Serial debug console

The serial console is a helpful tool for debugging your board and reviewing system log information. The console is the default output location for kernel log messages (i.e. dmesg), and it also provides access to a full shell prompt that you can use to access commands such as logcat. This is helpful if you are unable to access ADB on your board through other means and have not yet enabled a network connection.

To access the serial console, connect a USB to TTL Serial Cable to the device UART pins as shown below.


Open a connection to the USB serial device on your development computer using a terminal program, such as PuTTY (Windows), Serial (Mac OS), or Minicom (Linux). The serial port parameters for the console are as follows:

Configuring the UART mode

The Raspberry Pi has a single full-speed UART (UART0) that is multiplexed between various board functions. You may need to modify the boot configuration of the system to enable the functions you need for your application. The following modes are supported:

Use the following steps to configure the internal UART on your board:

  1. Remove power from your Raspberry Pi and remove the SD card.
  2. Insert the SD card into your development computer.
  3. Access the SD card volume on your computer:

    • Linux: Use dmesg to discover the disk name (e.g. sdX), followed by mount to make the first partition accessible:

      $ dmesg
      [...] sd 9:0:0:0: [sda] Attached SCSI removable disk
      $ mount /dev/sda1 /mnt/pisdcard
    • Mac: Use diskutil list to discover the disk name (e.g. diskX), followed by mount to make the first partition accessible:

      $ diskutil list
      /dev/disk0 (internal, physical):
      /dev/disk1 (internal, virtual):
      /dev/disk2 (external, physical):
      $ mount -t msdos /dev/disk2s1 /Volumes/pisdcard
    • Windows: Open File Explorer and locate the RPIBOOT volume.

  4. Locate the cmdline.txt file on the mounted volume:

    Bluetooth Mode:

    • Set the console attribute to the following:


    Application Mode:

    • Set the console attribute to the following:

  5. Locate the config.txt file on the mounted volume:

    Bluetooth Mode:

    • Remove the following line, if present:

    • Add the following lines:


    Application Mode:

    • Add the following line:

    • Remove the following lines:

  6. Save the changes to both files and eject the SD card from your development computer.

  7. Insert the card back into the Raspberry Pi and power it on.

This site uses cookies to store your preferences for site-specific language and display options.


This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.

Take a one-minute survey?
Help us improve Android tools and documentation.