android avec raspberry pi logo

Install Android on his Raspberry Pi

Updated the 28 March 2018 - 32 Comments - , , ,

ⓘ Cet article peut avoir été partiellement ou totalement traduit à l'aide d'outils automatiques. Nous nous excusons des erreurs que cela pourrait engendrer.

This article will explain how to install and configure Android 7.1.1 (with the Play Store) on your Raspberry Pi.

Above all, it is important to point out that this is only an experimental setup. No version of Android is officially compatible with the Raspberry Pi and therefore the version we will install is not optimized for our dear motherboard. It is therefore difficult today to use Android on a daily basis on its Raspberry Pi even if the installation we are going to present turns relatively well.

Prerequisites to install Android

After this short introduction, let’s take stock of everything we need to complete this installation.

Then you will need to download the Android image and sh script that will install the Play Store.

ATTENTION, for the last part of the tutorial, you will have to use a machine with an unix OS (Linux or Mac OS) to be able to execute the sh script. If you do not have one, you can use a virtual machine. Here we indicate commands for a Debian like distro (such as Ubuntu, Linux Mint, Elementary Os, and a lot of others).

Installing Android on the SD card

Once downloaded, the installation of the Android image on the SD card is very simple, it’s the same manipulation as to create an SD card on raspbian. You can go back to the articles that we wrote about it for Windows or Linux. However in this tutorial, I will use a software released after the writing of these articles which is very easy to use and above all compatible for all OS, it is Etcher .

etcher interface

 

Just select the .img file from Android that you extracted from the zip archive downloaded in the introduction, Etcher automatically detects the SD card on which to install the operating system but it is possible to change it. Finally click on Flash to start the creation of the SD card. It can take long minutes.

When done, insert the SD card into your Raspberry Pi connected to a screen. Here you are now with a functional Android. However, as you can see, this one does not have a Play Store.

Installing the Play Store

To install the Play Store, you must first connect to the internet (wi-fi or Ethernet). For that, pull the options panel by clicking on top of screen and pull down, just like smarpthone.

Once done, we will need the IP address of the Raspberry Pi. To retrieve it, you have to go to the parameters, go down to the bottom of the various parameters and go to “About tablet” and then to “Status”. we can now see our IP address (198.168.xx).

Now that we have recovered this address, we will be able to return to our unix computer as indicated in the introduction while leaving the Raspberry Pi running Android. I remind those who are on Windows that they can use a virtual machine to perform these steps.

Open the downloaded gapps.sh file in the introduction. You will find the following lines

SHOW_HELP = false 
ADB_ADDRESS = "192.168.10.173" 
ARCHITECTURE = "arm" 
PACKAGE_NAME = "pico" 
INIT_FILE = "/etc/init.d/gapps"

It is necessary to replace the IP address (ADB_ADDRESS) by that of your Raspberry Pi. In addition, if the other fields are empty, fill them in as above.

After that, in a terminal, run the command

sudo apt install android-tools-adb

This command will allow you to connect to your Raspberry Pi under android from your PC. Then install “LZip”

sudo apt install lzip

After these orders, we will be able to connect to our Raspberry Pi.

adb connect IP_RASPBERRY_PI

And finally, run the script to install the Play Store. Go through the terminal in the folder where the gapps.sh script is located, make the executable and run it.

sudo chmod u+x ./gapps.sh 
sudo ./gapps.sh

Be carefull, the script is so looooooooong… Once it’s finished, the Raspberry Pi will restart. You will find yourself with a nice Android with the Play Store. However, some applications will have problems downloading them. Also as said in the introduction, this is an experimental setup and the GPU is not very well supported. It is therefore likely that Android is experiencing slowdowns. If you want a card that can run Android well, we recommend using an Odroid . We did not test on it but the returns are good.

Notez cet article.
Share
Newsletter
Author:
Raspberry Pi FR
Join the Raspberry Pi community
A $35 computer already sold 10 million copies
BUY THE NEW RASPBERRY PI 4
Related tutorials
Create a Wi-Fi hotspot in less than 10 minutes with Pi Raspberry! How to install a web server on the Raspberry Pi (Apache + PHP + MySQL) Create a NAS with your Raspberry Pi and Samba How to recover the password of your Raspberry Pi if you lost it. 2018 Update. Install WordPress on a Raspberry Pi (with Nginx).
32 Comments

  1. Stanciu Danut says:

    Hi! Thank you for your tutorial. The script didn’t work for me but i downloaded manual the package in gapps forlder, disable download from script and then run script; everything after that worked. Thanks again.

  2. PK says:

    Hi , Seems like my installation was successul but the pi is no displaying anything on screen , it does have some signal.

  3. Matthias Findeis says:

    Hi, i’m sorry.
    I Do your Tutorial, but i stuck at the last part.
    Connection is succeed, but i think, the Github Link is not right.
    Can you help please?

    I copied my screen:

    Used package: open_gapps-arm-7.1-pico-201904020.zip
    […]

    –2019-11-11 01:53:28– https://github.com/opengapps/arm/releases/download/201904020/open_gapps-arm-7.1-pico-201904020.zip
    Auflösen des Hostnamens github.com (github.com) … 140.82.118.3
    Verbindungsaufbau zu github.com (github.com)|140.82.118.3|:443 … verbunden.
    HTTP-Anforderung gesendet, auf Antwort wird gewartet … 404 Not Found
    2019-11-11 01:53:28 FEHLER 404: Not Found.

    […]
    ERR: unzipping the package failed!

    1. Hello, apparently the script we was using wasn’t valid anymore as the maintainers of gapps have changed the way they distribute their package.
      I have done a quick update of the script but cannot test it right now and so cannot ensure it’s working as expected.

  4. YOU SAID: “It is necessary to replace the IP address (ADB_ADDRESS) by that of your raspberry pi. In addition, if the other fields are empty, fill them in as above. After that, in a terminal, run the command”

    I have no idea how to get to a terminal so I can run the commands. What happens between the above two steps? Where is the terminal? I have been all over the Android desktop and cannot find it.

    1. As said before in the tutorial, thoses commands should be run from you main computer, on a Linux system (use a virtual machine if you are on Windows), not the android one.

  5. Derek says:

    For anyone doing this in 2019. The timestamp in the script is old I had to update it to 201904020. I think the zip on github is corrupt or missing.

  6. Ludo says:

    Can’t sign in in the Play Store (even if I can from a computer).
    Any suggestion on how I could install app on the Pi3?

    p.s. Thanks, the script worked like a charm.

  7. JouMasePoes says:

    Wifi constantly disconnects…no sound…your script sucks

    1. Your mom too, and i dont feel like i nee’d to say it online though…
      For my part i dont experience Wi-Fi disconnection, for sound i didn’t test. But, if you just read like the first paragraphe, you can see that it clearly say this is a testing system, not a production ready one…

  8. cc says:

    Not running on Rapsberry pi 3 b+

    1. New processor, old image :/ And i think we will not be able to find a new image soon.

  9. Allan Knisley says:

    Tried twice and both times after ./gapps.sh is done and the Pi rebooted, it is stuck is boot loop.

    1. Hello, we have not experienced this problem, are you sure the script gapps.sh work properly ?

  10. Wayne O'Donnell says:

    Is there a technical reason that prevents anybody creating an image file that already contains Play Store? It would be a lot simpler just to install a fully remade image directl6 to the SD card.

    1. I absolutly don’t know :/. Maybe legal issues too.

  11. Alexandre says:

    Afther i install the image in the SD Card and insert in the raspberry, i see the letters “android” and then a full black screen. I wait a long but noting happends

    1. Well, it seems that few peoples have this problem, but i just don’t know where it comes from. Can you tell us what setup you are using ?

  12. RaghuCk says:

    Awesome !! Thank you very much for the detailed steps. I was able to launch the Android OS and google play installed by running the script.

    I am having issue in using the playstore though, it says “Couldn’t sign in. There was a problem communication with Google servers. Try again later”

    I checked accessing and logging into my google account from browser and that works fine. Could you please help me as what needs to be done in google play ?

    1. Sorry, i’ve never had the problem, maybe ask on specialized forums.

  13. B says:

    How the hell did you compress 7.9Gb into 232Mb? I really need to know,

    1. A lot of empty space i presume wich compression easily remove.

  14. Zach Lewis says:

    I am struggling to execute the last 2 lines of code. I entered the first line but i get the error “chmod : invalid mode: ‘u’
    Try chmod –help for more information”

  15. Noob says:

    Does anyone have a video on how to install the Google Play Store? I’m a Noob and I’m just learning how to do such things!

    1. Sorry, we didn’t have video. But you could just like copy/paste (more or less) and it should work.

  16. Yahx says:

    ehy bro … very well job but don’t work for me … when i paste the command in terminal “sudo chmod u + x ./gapps.sh” (modified with the real position of file) the terminal give me error “chmod invalid way : u”….
    Where am I wrong?

    i use ubuntu 16.04 lts
    Sorry for bad english i m little italian boy
    Thank you

    1. My bad, you have to remove spaces arround “+”

  17. neXt says:

    The author presumes that *nux = a Debian derivative, which, in most of the cases, might not be entirely true.

    1. Yes, your absolutly right ! It’s mostly because we are using Debian systems all the times. We add a sentence to indicate we show commands for Debian like distros.

  18. M says:

    I am having trouble installing the play store. The commands are not working for me.

    1. It should work, but keep in mind this command is just soooooooo long !

  19. Jack Huang says:

    Great tutorial, Thank you so much.

Share
Newsletter Sign-Up
Subscribe to the newsletter.
¿Te gustó este artículo?
¡Suscríbete y mantente informado!