Chinaunix首页 | 论坛 | 博客
  • 博客访问: 316678
  • 博文数量: 63
  • 博客积分: 2018
  • 博客等级: 大尉
  • 技术积分: 694
  • 用 户 组: 普通用户
  • 注册时间: 2010-02-23 16:34
文章存档

2010年(63)

我的朋友

分类: LINUX

2010-08-25 21:22:36

本文通过udev机制实现sdio+wifi的挂载,当然,如果是arm处理器核,wifi所需的固件可以和wifi驱动一同编进linux内核;如果wifi驱动不认识你的核,则使用udev加载wifi模块是很好的方式。
 
udev的支持见《udev详细》一文。udev属于用户级程序,你的文件系统支持就可以了。
 
首先保证你的文件系统已经支持udev了,当然内核也支持了:
 
 
 
你需要选上MMC/SD卡驱动:
 
 
而后是wifi的驱动:
 
 
 
 
而后:
 
/ # udev
udevd      udevstart
/ # udevd --daemon
/ # udevstart
/ # insmod libertas_sdio.ko
libertas_sdio: Libertas SDIO driver
libertas_sdio: Copyright Pierre Ossman
libertas_sdio mmc0:0001:1: firmware: requesting sd8686_helper.bin
libertas_sdio mmc0:0001:1: firmware: requesting sd8686.bin
libertas: 00:24:7e:a7:11:9d, fw 9.70.3p24, cap 0x00000303
libertas: wlan0: Marvell WLAN 802.11 adapter
 
 
你的nfs需要wirlesstolls工具,里面有iwlist,iwconfig,iwpriv等无线命令。
/ # ifconfig wlan0 up
/ # iwlist wlan0 scanning
wlan0     Scan completed :
          Cell 01 - Address: 00:10:18:00:00:B6
                    ESSID:"wireless"
                    Mode:Managed
                    Frequency:2.412 GHz (Channel 1)
                    Quality=89/100  Signal level=-61 dBm  Noise level=-96 dBm
                    Encryption key:on
                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 18 Mb/s
                              24 Mb/s; 36 Mb/s; 54 Mb/s; 6 Mb/s; 9 Mb/s
                              12 Mb/s; 48 Mb/s
                    IE: WPA Version 1
                        Group Cipher : TKIP
                        Pairwise Ciphers (1) : TKIP
                        Authentication Suites (1) : PSK
                    IE: IEEE 802.11i/WPA2 Version 1
                        Group Cipher : TKIP
                        Pairwise Ciphers (1) : TKIP
                        Authentication Suites (1) : PSK
          Cell 02 - Address: 00:21:91:6F:F1:F2
                    ESSID:"dlink"
                    Mode:Managed
                    Frequency:2.437 GHz (Channel 6)
                    Quality=95/100  Signal level=-55 dBm  Noise level=-96 dBm
                    Encryption key:off
                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 6 Mb/s
                              9 Mb/s; 12 Mb/s; 48 Mb/s; 18 Mb/s; 24 Mb/s
                              36 Mb/s; 54 Mb/s
          Cell 03 - Address: 00:21:29:8E:C4:3A
                    ESSID:"cisco-wireless"
                    Mode:Managed
                    Frequency:2.442 GHz (Channel 7)
                    Quality=95/100  Signal level=-55 dBm  Noise level=-96 dBm
                    Encryption key:off
                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 18 Mb/s
                              24 Mb/s; 36 Mb/s; 54 Mb/s; 6 Mb/s; 9 Mb/s
                              12 Mb/s; 48 Mb/s
/ # iwconfig wlan0 essid dlink
 
而后配上ip,即可以ping通 热点:
 
64 bytes from 192.168.1.254: seq=97 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=98 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=99 ttl=64 time=40.000 ms
64 bytes from 192.168.1.254: seq=100 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=101 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=102 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=103 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=104 ttl=64 time=40.000 ms
64 bytes from 192.168.1.254: seq=105 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=106 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=107 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=108 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=109 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=110 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=111 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=112 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=113 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=114 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=115 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=116 ttl=64 time=60.000 ms
64 bytes from 192.168.1.254: seq=117 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=118 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=119 ttl=64 time=60.000 ms
64 bytes from 192.168.1.254: seq=120 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=121 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=122 ttl=64 time=40.000 ms
64 bytes from 192.168.1.254: seq=123 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=124 ttl=64 time=20.000 ms
64 bytes from 192.168.1.254: seq=125 ttl=64 time=20.000 ms
 
阅读(2702) | 评论(0) | 转发(0) |
0

上一篇:udev详细

下一篇:Writing udev rules

给主人留下些什么吧!~~