Difference between revisions of "Category:How to - wifi"
From Gumstix User Wiki
(→Running DHCP Server on Ad-hoc Network) |
Geometrikal (Talk | contribs) |
||
Line 11: | Line 11: | ||
Change the wlan0 config to | Change the wlan0 config to | ||
− | + | auto wlan0 | |
− | auto wlan0 | + | iface wlan0 inet static |
− | iface wlan0 inet static | + | address 192.168.2.2 |
− | address 192.168.2.2 | + | netmask 255.255.255.0 |
− | netmask 255.255.255.0 | + | wireless-mode ad-hoc |
− | wireless-mode ad-hoc | + | wireless-essid gumstix-network |
− | wireless-essid gumstix-network | + | |
− | + | ||
Reboot | Reboot | ||
Line 24: | Line 22: | ||
'''Using ifconfig and iwconfig:''' | '''Using ifconfig and iwconfig:''' | ||
− | + | ifconfig wlan0 down | |
− | ifconfig wlan0 down | + | ifconfig wlan0 address 192.168.2.2 netmask 255.255.255.0 |
− | ifconfig wlan0 address 192.168.2.2 netmask 255.255.255.0 | + | iwconfig wlan0 mode ad-hoc essid gumstix-network |
− | iwconfig wlan0 mode ad-hoc essid gumstix-network | + | ifconfig wlan0 up |
− | ifconfig wlan0 up | + | |
− | + | ||
== Running DHCP Server on Ad-hoc Network== | == Running DHCP Server on Ad-hoc Network== | ||
Line 36: | Line 32: | ||
Create a configuration file: | Create a configuration file: | ||
− | + | vi /etc/udhcpd.conf | |
Put the following in the file: | Put the following in the file: | ||
Line 56: | Line 52: | ||
Create the leases file: | Create the leases file: | ||
− | + | touch /var/lib/misc/udhcpd.leases | |
Now run the dhcp server: | Now run the dhcp server: | ||
− | + | udhcpd /etc/udhcpd.conf | |
Connect to the gumstix ad-hoc network and you should notice that you have been assigned the start address in the config file above. | Connect to the gumstix ad-hoc network and you should notice that you have been assigned the start address in the config file above. |
Revision as of 16:46, 9 February 2009
Wifi Configuration
The wifi configuration file is located in
/etc/network/interfaces
Creating an Ad-hoc Network
On startup using the interfaces file:
Open /etc/network/interfaces
Change the wlan0 config to
auto wlan0 iface wlan0 inet static address 192.168.2.2 netmask 255.255.255.0 wireless-mode ad-hoc wireless-essid gumstix-network
Reboot
Using ifconfig and iwconfig:
ifconfig wlan0 down ifconfig wlan0 address 192.168.2.2 netmask 255.255.255.0 iwconfig wlan0 mode ad-hoc essid gumstix-network ifconfig wlan0 up
Running DHCP Server on Ad-hoc Network
Setting up a DHCP server on the ad-hoc network will allow you to connect to the gumstix without having to change your ip address.
Create a configuration file:
vi /etc/udhcpd.conf
Put the following in the file:
#start address
start 192.168.2.3
#end address
end 192.168.2.254
#interface to listen on
interface wlan0
#maximum number of leases
max_leases 64
Create the leases file:
touch /var/lib/misc/udhcpd.leases
Now run the dhcp server:
udhcpd /etc/udhcpd.conf
Connect to the gumstix ad-hoc network and you should notice that you have been assigned the start address in the config file above.
Pages in category "How to - wifi"
The following 2 pages are in this category, out of 2 total.