Connecting to internet with wifi

If you need technical help with anything you've bought from Dawn Robotics, please post here.

Connecting to internet with wifi

Postby Adeste » Fri Jan 30, 2015 11:22 pm

Hi
I have set static ip for the etho and wlano see config below. By sharing the internet connection on my ethonet I can get the bot to connect to the internet. This works fine. I have tried to get the bot to connect directly to my router/internet with no luck. Any pointers please
you can see some of my efforts commented out with a # in the "interfaces" file

ifcopi@raspberrypi ~ $ ifconfig
eth0 Link encap:Ethernet HWaddr b8:27:eb:f3:a6:d1
inet addr:192.168.137.110 Bcast:192.168.137.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:423 errors:0 dropped:0 overruns:0 frame:0
TX packets:234 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:44349 (43.3 KiB) TX bytes:39119 (38.2 KiB)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:2 errors:0 dropped:0 overruns:0 frame:0
TX packets:2 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:100 (100.0 B) TX bytes:100 (100.0 B)

wlan0 Link encap:Ethernet HWaddr 74:da:38:00:79:38
inet addr:192.168.42.1 Bcast:192.168.42.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:688 errors:0 dropped:0 overruns:0 frame:0
TX packets:196 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:120141 (117.3 KiB) TX bytes:31415 (30.6 KiB)
======================================================================================

pi@raspberrypi ~ $ sudo nano /etc/network/interfaces
GNU nano 2.2.6 File: /etc/network/interfaces

auto lo

iface lo inet loopback
iface eth0 inet static
address 192.168.137.110
netmask 255.255.255.0
broadcast 192.168.137.255
gateway 192.168.137.1

allow-hotplug wlan0
#auto wlan0

iface wlan0 inet static
address 192.168.42.1
netmask 255.255.255.0
#wpa-ssid "SKY2EA28"
#wpa-psk "QY*****"

#iface wlan0 inet manual
Adeste
 
Posts: 12
Joined: Fri Dec 26, 2014 9:37 am

Re: Connecting to internet with wifi

Postby Alan » Sat Jan 31, 2015 12:42 am

Hi Adeste,

Not massively hot on Linux WiFi I'm afraid, but perhaps if you try getting rid of the static IP address and using something like the following, you may have more luck

iface wlan0 inet dhcp
wpa-ssid "SKY2EA28"
wpa-psk "QY*****"

If you can get another Pi SD card to connect over wifi then you should be able to use the same elements in your /etc/network/interfaces file.

Regards

Alan
Alan
Site Admin
 
Posts: 311
Joined: Fri Jun 14, 2013 10:09 am

Re: Connecting to internet with wifi

Postby Adeste » Sat Jan 31, 2015 11:03 am

Hi
Thanks. I thought it might require another card or another connection. I want to keep static addresses for remote internet access.

It works fine and happy to connect by ethernet for the odd time the bot needs updating etc.

Cheers Ade
Adeste
 
Posts: 12
Joined: Fri Dec 26, 2014 9:37 am


Return to Technical Support

Who is online

Users browsing this forum: No registered users and 0 guests