topamax once a day

VNC setup on Raspberry Pi from Android

This tutorial will demonstrate how to setup and connect to a Raspberry Pi over VNC from Android. This process assumes you have Debian for Raspberry Pi installed on an SD card. If not, see RPi Easy SD card setup. It also assumes that you have a display connected to the Raspberry Pi. If you don’t have a display available, the steps to configure VNC remotely are outlined in my last tutorial: VNC setup on Raspberry Pi from Ubuntu

 

Getting the IP address of the Raspberry Pi

The first step is to locate the Raspberry Pi on your network. Open up a terminal on the Raspberry Pi and type:

ifconfig

All the network interface configurations will be displayed, including the IP address. Make a note of this, it will be needed later.

 

Configuring VNC

Next, we need to install the VNC server. In a terminal on the Pi type:

sudo apt-get install tightvncserver

Now, start the VNC server on the Raspberry Pi. Adjust the geometry paramater to your desired display size. 1200×720 works well for the Galaxy Nexus (image above) and the Xoom (image below):

vncserver :1 -geometry 1200x720 -depth 16 -pixelformat rgb565

You will be prompted to create a password for VNC login. Once you do, you should see a line looking something like this:

New ‘X’ desktop is raspberrypi:1

 

Connecting from Android

You will need to download any VNC client to connect to the Raspberry Pi VNC session. I use androidVNC, but any VNC client should work as long as the settings are correct:

Nick : pi (or whatever you want)
address : your_ip_address
port : 5901
password : your_password
Touch Mouse; D-Pad Pan; Mouse pointer
control mode: TouchPad

Be sure to replace your_ip_address and your_password with your own settings.

 

  • Pingback: Raspberry Pi part 2 | David Boyce()

  • Jonathan

    Visited with Chrome 24 on GNU/Linux/KDE, and had to leave again; the site is TOTALLY illegible with black text on a dark grey background. Can’t think what you’re thinking…

  • tobiz

    I fail to connect to my raspi from Android since raspi ui runs on Xwin screen 2 whereas there is no way to specify screen 2 from any Android VNC. I can connect to raspi from ubuntu VNC since specifying which screen to use is an option. Android apps need this option.

    • Cindy-in-Bama

      Port 5902 gets you screen 2.

      • tobiz

        Excellent, thanks.

  • Pingback: VNC from Android device to the Pi()

  • Sushant

    Host 192.168.x.x port 22 is not an RFB server

    this is the error Im getting when i hit connect on androidVNC…
    Can anybody help?

  • Excellent tutorial. Works perfectly on the Google Nexus 7

  • Jon

    Works great – 1st time trying it on HTC EVO. Interesting that it does not mirror what I have on my external monitor…

  • k meter

    Thanks. Couldn’t have been simpler . . . great article!

  • Mads Hougesen

    Thank you. Works 110% on my Nexus 10

  • Pingback: Setting Up a #RaspberryPi with VNC | Easy Computing()

  • Works fine on my android one… Need large screen for full display

  • Pingback: Raspberry Pi und Android: 5 Top-Tutorials()

  • Ryan

    How do I enable this to run on start-up?