rtl8723bu linux wifi驱动移植教程

rtl8723bu linux 驱动移植教程

  1. 将文件

rtl8723BU_WiFi_linux_v4.3.9.3_13200.20150106_BTCOEX20140929-5443.tar.gz

拷贝到linux源码目录drivers/net/wireless/net/下解压

tar xzvf rtl8723BU_WiFi_linux_v4.3.9.3_13200.20150106_BTCOEX20140929-5443.tar.gz

更改文件名

mv rtl8723BU_WiFi_linux_v4.3.9.3_13200.20150106_BTCOEX20140929-5443 rtl8723bu

更改wireless目录下的Kconfig文件

增加 source “drivers/net/wireless/rtl8723bu/Kconfig”

更改wireless目录下的Makefile

obj-$(CONFIG_RTL8723BU) += rtl8723bu/

更改rtl8723目录下的Makefile:

  1. 在Platform Related下面增加im6ull的默认支持,其他均为n
CONFIG_PLATFORM_ARM_IMX6ULL = y
  1. 在ifeq ($(CONFIG_PLATFORM_I386_PC), y)后面增加(根据自己的板子)
ifeq ($(CONFIG_PLATFORM_ARM_IMX6ULL), y)
EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN
EXTRA_CFLAGS += -DCONFIG_CONCURRENT_MODE
 EXTRA_CFLAGS += -DCONFIG_IOCTL_CFG80211 -DRTW_USE_CFG80211_STA_EVENT
ifeq ($(CONFIG_USB_HCI), y)
EXTRA_CFLAGS += -DCONFIG_USE_USB_BUFFER_ALLOC_TX -DCONFIG_FIX_NR_BULKIN_BUFFER
endif
ARCH := arm
CROSS_COMPILE := arm-linux-guneabihf-
 KVER := 4.9.88
KSRC := /home/myz/arn-linux/tool/imx-linux4.9.88
MODULE_NAME := 8723bu
endif

make menuconfig 配置

  1. usb配置
[*] USB support  --->   
    <*>   Support for Host-side USB 
    <*>     EHCI HCD (USB 2.0) support 
    <*>     OHCI HCD (USB 1.1) support    
    <*>     USB Mass Storage support
    <*>   ChipIdea Highspeed Dual Role Controller   
    [*]     ChipIdea device controller
    [*]     ChipIdea host controller
  1. wifi配置
[*] Network device support  ---> 
    [*]   Wireless LAN  --->
        <*>   IEEE 802.11 for Host AP (Prism2/2.5/3 and WEP/TKIP/CCMP)   
        [*]     Support downloading firmware images with Host AP driver 
        [*]       Support for non-volatile firmware download 
[*] Network device support  ---> 
[*]   Wireless LAN  --->
<*>   Realtek 8723B USB WiFi
  1. 支持 IEEE 802.11
[*] Networking support  ---> 
    -*-   Wireless  ---> 
    <*>   cfg80211 - wireless configuration API
    <*>   Generic IEEE 802.11 Networking Stack (mac80211)

修改源码目录下的.config文件,是能rf,增加

CONFIG_RFKILL=y

编译后,启动内核
启动wifi

$ ifconfig -a
$ ifconfig wlan0 up
$ ifconfig

扫描wifi

$ iwlist wlan0 scanning

修改wifi配置

$ vi /etc/wpa_supplicant.conf
ctrl_interface=/var/run/wpa_supplicant
update_config=1
ctrl_interface_group=root
ap_scan=1
network={
ssid=“ssid”//wifi名
key_mgmt=WPA-PSK
pairwise=CCMP
group=CCMP
psk=“password”//密码
}
$mkdir -p /var/run/wpa_supplicant

连接路由器

wpa_supplicant -Dwext -iwlan0 -c/etc/wpa_supplicant.conf &

自动分配Ip

udhcpc -i wlan0

手动分配ip

ifconfig wlan0 192.168.1.25

查看ip地址

ifconfig

检测网络连接(www.baidu.com)

ping 39.156.69.79

结果

PING 39.156.69.79 (39.156.69.79): 56 data bytes
64 bytes from 39.156.69.79: seq=0 ttl=47 time=137.386 ms
64 bytes from 39.156.69.79: seq=1 ttl=47 time=13.502 ms
64 bytes from 39.156.69.79: seq=2 ttl=47 time=28.295 ms
64 bytes from 39.156.69.79: seq=3 ttl=47 time=9.005 ms
64 bytes from 39.156.69.79: seq=4 ttl=47 time=8.850 ms
64 bytes from 39.156.69.79: seq=5 ttl=47 time=8.140 ms
64 bytes from 39.156.69.79: seq=6 ttl=47 time=13.138 ms
64 bytes from 39.156.69.79: seq=7 ttl=47 time=8.941 ms
64 bytes from 39.156.69.79: seq=8 ttl=47 time=11.827 ms
64 bytes from 39.156.69.79: seq=9 ttl=47 time=11.525 ms
64 bytes from 39.156.69.79: seq=10 ttl=47 time=8.471 ms
^C
--- 39.156.69.79 ping statistics ---
12 packets transmitted, 11 packets received, 8% packet loss
round-trip min/avg/max = 8.140/23.552/137.386 ms

  • 1
    点赞
  • 30
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值