Tag Archives: pi

Raspberry pi how to connect raspberry to android phone

After you are able to install and connect you raspberry pi via laptop and lan.
maybe its necesarry for you to connect your rasberry pi via android phone.

here is how

What you need.

1. wifi module
2. access to rasberry pi (via putty or direct).
3. android phone with SSH Client application installed
here is to download SSH Client application https://play.google.com/store/apps/details?id=com.anstudios.ssh&hl=en

Step by step

1. plug in wifi module to raspberry pi
2. turn on raspberry pi. enter ifconfig command, wlan0 should come up in list, but not connected to any address
pi@raspberrypi ~ $ ifconfig
wlan0     Link encap:Ethernet  HWaddr
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

4. turn on wifi hotspot/tethering on your android phone
5. enter command sudo iwlist wlan0 scan | grep ESSID

pi@raspberrypi ~ $ sudo iwlist wlan0 scan | grep ESSID
ESSID:”HP-Print-41-Officejet Pro 8600″

6. edit wpa_supplicant.conf
sudo nano /etc/wpa_supplicant/wpa_supplicant.conf
add this line

ssid=”your essid name/copy paste from earlier scan result”
psk=”you hotspot password”

for example with my handphone


7. save file, and reboot raspberry pi.
8. after reboot you’ll see that now your raspberry wlan module is connected to you hotspot. enter command sudo ifconfig wlan0 to see its ip address.
9. open SSH client on your android phone and enter raspberry pi address,
10. Now you can access your raspberry via your android phone. :D.

raspberry SSH from android phone
raspberry SSH from android phone

to restart raspberry networking you can enter this command instead rebooting raspberry
sudo /etc/init.d/networking stop
sudo /etc/init.d/networking start