[vc_row][vc_column][vc_column_text]pcDuino3 has built-in WiFI module, but the module type is rtl8188cus, which is different from the previous model rt5370. This wifi module also supports AP function. Many users have played with the AP mode of Rtl8188 on Raspberry Pi, but the same method just have issue on pcDuino3. In this tutorial, we will show how to start WiFi AP function on pcDuino.[/vc_column_text][vc_tour][vc_tab title=”Download the software” tab_id=”1418221661-1-76″][vc_column_text]1. Download the software tool
sudo su sudo apt-get update sudo apt-get install git gedit
If you do not know where to type, see the following picture.
2. Download the official driver code.
#http://www.realtek.com.tw/downloads/downloadsView.aspx?Langid=1&PNid=21&PFid=48&Level=5&Conn=4&DownTypeID=3&GetDown=false&Downloads=true#2742
First copy the code to the command line, then copy to the browser, then you can download. Notice the download path is under /home/ubuntu/Downloads, do not download wrong.[/vc_column_text][/vc_tab][vc_tab title=”Install hostapd and set dhcp” tab_id=”1418221661-2-69″][vc_column_text]1. The hostapd which build-in driver does not make into system services, here thanks to the open source, a player has successfully made into the service system.
git clone https://github.com/jenssegers/RTL8188-hostapd cd RTL8188-hostapd/hostapd sudo make install
Be patient and wait the command appear again.
2. Instal 8188 hostapd.
cd /home/ubuntu/Downloads unzip RTL8188C_8192C_USB_linux_v4.0.2_9000.20130911.zip cd RTL8188C_8192C_USB_linux_v4.0.2_9000.20130911/wpa_supplicant_hostapd tar xvf wpa_supplicant_hostapd-0.8_rtw_r7475.20130812.tar.gz cd wpa_supplicant_hostapd-0.8_rtw_r7475.20130812/hostapd sudo make install
3. Configure the hostapd.
Input the following command and check what you want.
ifconfig <img src="http://cnlearn.linksprite.com/wp-content/uploads/2014/12/%E5%9B%BE%E7%89%8731.png" alt="图片3" /> Note: all the command must write in lowercase
gedit /etc/hostapd/hostapd.conf The original iuse vim, to tell the truth for newcomers (especially do not good at keyboard) a bit too difficult, so use gedit directly.
# Basic configuration interface=wlan5 #根据你自己的接点 ssid=wifi channel=1 #bridge=br0 # WPA and WPA2 configuration macaddr_acl=0 auth_algs=1 ignore_broadcast_ssid=0 wpa=3 wpa_passphrase=12345678 wpa_key_mgmt=WPA-PSK wpa_pairwise=TKIP rsn_pairwise=CCMP # Hardware configuration driver=rtl871xdrv ieee80211n=1 hw_mode=g device_name=RTL8192CU manufacturer=Realtek <b>ervice hostapd restart </b>
Set the WiFi hot name as wifi, the password as 12345678
Now you need to clear the wifi password, then you can search the wifi hot through your telephone, but still can not connect.
4. Need to configure the network.
gedit /etc/network/interfaces
auto wlan5
iface wlan5 inet static
address 192.168.100.1
netmask 255.255.255.0
Copy this to the command, all will be well done.
sudo /etc/init.d/networking restart <b> 5. configure </b><b>dhcp </b>
gedit /etc/dhcp/dhcpd.conf #在最后面加 subnet 192.168.100.0 netmask 255.255.255.0 { range 192.168.100.10 192.168.100.100; option routers 192.168.100.1; option domain-name-servers 8.8.8.8; }
My option domain-name-servers is 202.102.152.3; ( do not miss ;), this is for the phone to set DNS service.
service isc-dhcp-server restart
[/vc_column_text][/vc_tab][vc_tab title=”Set the startup” tab_id=”1418221712479-2-10″][vc_column_text]After the Hostapd start then the dhcpd can start, dhcpd close then the hostapd can close.
update-rc.d hostapd defaults 80 20 update-rc.d isc-dhcp-server defaults 90 10 reboot At this time, the phone may still can't get into the website. It troubles me a few d
[/vc_column_text][/vc_tab][vc_tab title=”Set NAT ” tab_id=”1418221713322-3-7″][vc_column_text]
sudo apt-get install iptables sudo sh -c 'echo 1 > /proc/sys/net/ipv4/ip_forward' sudo iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE Now you can connect to the website.
[/vc_column_text][/vc_tab][/vc_tour][/vc_column][/vc_row]
Leave a Reply
You must be logged in to post a comment.