Please enable javascript, or click here to visit my ecommerce web site powered by Shopify.
Jump to: navigation, search

Difference between revisions of "Rock2/wireless"

(Rock2 AP6335 AP mode)
 
Line 4: Line 4:
 
   insmod wlan.ko  or echo 1 > /sys/class/rkwifi/driver
 
   insmod wlan.ko  or echo 1 > /sys/class/rkwifi/driver
  
2 install hostapd
+
2 install and config hostapd
 +
  apt-get install hostapd
 
   edit /etc/hostapd/hostapd.conf
 
   edit /etc/hostapd/hostapd.conf
 
   interface=wlan0
 
   interface=wlan0

Revision as of 07:50, 5 May 2015

1 change ap6335 mode and install driver

 echo 2 > /sys/module/bcmdhd/parameters/op_mode
 install ap6335 driver 
 insmod wlan.ko  or echo 1 > /sys/class/rkwifi/driver

2 install and config hostapd

 apt-get install hostapd
 edit /etc/hostapd/hostapd.conf
 interface=wlan0
 ctrl_interface=/var/run/hostapd
 ssid=squareAP
 channel=6
 wpa=2
 wpa_passphrase=12345678
 #bridge=br0

3 install and config dnsmasq

 apt-get install dnsmasq
 edit /etc/dnsmasq.conf 
 interface=wlan0 
 bind-interfaces 
 except-interface=lo 
 dhcp-range=192.168.2.150,192.168.2.254,12h #configure the range of available ip
 dhcp-option=3,192.168.2.1 #configure the server

4 edit /etc/network/interfaces

 # interfaces(5) file used by ifup(8) and ifdown(8)
 auto wlan0
 iface wlan0 inet static
 address 192.168.2.1
 netmask 255.255.255.0

5 install haveged

 apt-get install haveged

6 start ap

 hostapd -B /etc/hostapd/hostapd.conf 
 ip addr add 192.168.2.1/24 dev wlan0
 service dnsmasq start 
 echo 1 > /proc/sys/net/ipv4/ip_forward 
 iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
 /etc/init.d/haveged start