2011年10月1日

在Linux上安裝Zyxel NWD2105 USB無線網卡

作業系統:Linux ubuntu 2.6.32-23-generic
先測試看是否有抓到Zyxel的USB網卡
root@ubuntu:~# lsusb
Bus 008 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 007 Device 002: ID 046d:c019 Logitech, Inc. Optical Tilt Wheel Mouse
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
BBus 002 Device 007: ID 0586:341e ZyXEL Communications Corp.
確認有抓到USB網卡後,接下來要安裝driver
[DOWNLOAD DRIVER]
cd /root 
wget http://eimer.ch/nwd2105.tar
tar -zxvf nwd2105.tar
cd 2011_0107_RT3070_RT3370_Linux_STA_v2.5.0.1_DPO
make
make install
裝好後修改vim /etc/Wireless/RT2870STA/RT2870STA.dat 設定檔
詳細參數可參考https://wiki.archlinux.org/index.php/Rt2870
重要參數如下:
Default
CountryRegion=5
CountryRegionABand=7
CountryCode=TW         <==台灣國碼
SSID=HTC        <==無線基地台的SSID
NetworkType=Infra
WirelessMode=0         <==無線 AP 支援的協定有關
Channel=3              <==依據偵測到頻道做對應的設定!
AuthMode=WPAPSK        <==依基地台的設定認證模式
EncrypType=TKPI         <==認證碼的加密機制
WPAPSK=xxxxxxx  <==基地台連線的金鑰密碼
修改好後存檔,接著再設定無線網路卡的IP取得方式(固定IP或DHCP)
vim /etc/network/interfaces   (相關參數可參考此網站)
加入下面兩行
auto ra0    #讓網卡插入後,自動啟用
iface ra0 inet dhcp   #使用DHCP來取得IP位置
存檔離開後,再重新啟用網路介面卡取到IP後
/etc/init.d/networking restart
即可利用ZyxelNWD2105 USB無線網卡上網

















root@ubuntu:~# ifconfig ra0
ra0       Link encap:Ethernet  HWaddr 50:67:f0:11:48:f9 
          inet addr:192.168.173.102  Bcast:192.168.173.255  Mask:255.255.255.0
          inet6 addr: fe80::5267:f0ff:fe11:48f9/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:31770 errors:0 dropped:0 overruns:0 frame:0
          TX packets:7446 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:6836222 (6.8 MB)  TX bytes:1673528 (1.6 MB)

root@ubuntu:~# iwconfig ra0
ra0       Ralink STA  ESSID:"HTC"  Nickname:"RT2870STA"
          Mode:Managed  Frequency=2.422 GHz  Access Point: 00:0F:CB:A4:3E:C9  
          Bit Rate=54 Mb/s  
          RTS thr:off   Fragment thr:off
          Encryption key:09B2-072D-FA59-F950-0B5E-B941-B724-62C3   Security mode:open
          Link Quality=100/100  Signal level:-36 dBm  Noise level:-65 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0

root@ubuntu:~# iwlist
Usage: iwlist [interface] scanning [essid NNN] [last]
              [interface] frequency
              [interface] channel
              [interface] bitrate
              [interface] rate
              [interface] encryption
              [interface] keys
              [interface] power
              [interface] txpower
              [interface] retry
              [interface] ap
              [interface] accesspoints
              [interface] peers
              [interface] event
              [interface] auth
              [interface] wpakeys
              [interface] genie

0 回應:

Copyright © 2009 New Life in Taipei All rights reserved. Theme by Laptop Geek. | Bloggerized by FalconHive.