IMX6ULL开发板Linux_WIFI驱动实验

1.在迅为i.MX6ULL开发板上使用的是 usb 接口的 RTL8723 wifi 模块,原理图如下所示:

可以看到 RTL8723 模块的接口非常简单,只有 DP1 和 DM1 连接到 usb HUB 芯片上,就可以完成通信电路
RTL8723 是 realtek 公司的 wifi 芯片,已经提供了 wifi 驱动源码,就不需要我们自己去编写了,只需要将提
供的 wifi 驱动源码添加到 Linux 内核中进行编译就可以了。

1.1在Linux内核中添加wifi驱动
首先获取 wifi 驱动源码,放到 Linux 内核 drivers/net/wireless 目录下,如下所示:

rtl8723BU 目录下内容如下所示:

其中 Kconfig 文件是 rtl8723 驱动的配置文件,这样可以通过 Linux 内核图形化配置界面来选择是否编译
WIFI 驱动,Kconfig 文件内容如下所示:
config RTL8723BU
tristate "Realtek 8723B USB WiFi"
depends on USB
---help---
Help message of RTL8723BU
当添加完 rtl8723 wifi 驱动时,需要修改上一级的 Kconfig 和 Makefile。
修改 drivers/net/wireless/Kconfig,添加如下内容:
source "drivers/net/wireless/rtl8723BU/Kconfig"

添加完成后如下所示:

添加完成后,在 Linux 内核的驱动配置界面上才会出现 rtl8723 的配置选项。
修改 drivers/net/wireless/Makefile 文件,添加如下内容:
obj-$(CONFIG_RTL8723BU) += rtl8723BU/
修改后如下所示:



1.2  配置 Linux 内核
添加好 rtl8723 wifi 驱动并修改完配置文件后,需要在 Linux 内核中在进行配置。
1、配置支持 USB 设备
Linux 内核配置路径如下:
Device Drivers --->

  • USB support --->
    <*> EHCI HCD (USB 2.0) support
    <*> ChipIdea Highspeed Dual Role Controller
  • ChipIdea device controller
  • ChipIdea host controller
    配置完成如下图所示:



    2、配置支持 wifi 设备
    Linux 内核配置路径如下:
    Device Drivers --->
  • 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
    配置完成如下图所示:



    3、配置支持 IEEE 802.11
    Linux 内核配置路径如下:
  • Networking support --->
    -*- Wireless --->
  • cfg80211 wireless extensions compatibility
    <*> Generic IEEE 802.11 Networking Stack (mac80211)
    配置完成如下图所示:



    4、配置 rtl8723 wifi 驱动
    Linux 内核配置路径如下:
    Device Drivers --->
  • Network device support --->
  • Wireless LAN --->
    <*> Realtek 8723B USB WiFi
    配置结果如图所示:


    直接将 rtl8723 wifi 模块的驱动编译到内核中去。
    以上 Linux 内核配置完成后,重新编译内核生成 zImage,使用新的 zImage 启动开发板。


    1.3 rtl8723 wifi  模块驱动测试
    使用新的 zImage 镜像启动开发板,系统启动过程中会有如下信息打印:

    上图说明在 Linux 系统启动过程中使用了 rtl8723 wifi 模块的驱动程序。当启动完成驱动后使用“ifconfig -a”
    命令查看 wlan 网卡是否存在,结果如下图所示:


    可以看到存在一个 wlan0 设备,这个就是 rtl8723 wifi 模块对应的网卡设备。说明驱动程序测试正常,但是
    如果要联网的话,还需要第三方组件才可以。下面就来看一下如何使用第三方组件进行联网测试。
1. General Description 1-1. Product Overview and Functional Description AzureWave Technologies, Inc. introduces the first IEEE 802.11b/g/n WLAN & Bluetooth stamp module ---AW-NB300SM. The stamp module is targeted to mobile devices including Personal Digital ShenZhen Header Office Contact:JackyChen PhoneNo.,:13510094765.email:jackychen@flycastle.com flycastle@126.com Assistants (PDAs), Netbook, Tablet and Gaming Devices which need small package stamp module, low power consumption, multiple interfaces and OS support. By using AW-NB300SM, the customers can easily enable the Wi-Fi, and BT embedded applications with the benefits of high design flexibility, short development cycle, and quick time-to-market. Compliance with the IEEE 802.11b/g/n standard, the AW-NB300SM uses Direct Sequence Spread Spectrum (DSSS), Orthogonal Frequency Division Multiplexing (OFDM), DBPSK, DQPSK, CCK and QAM baseband modulation technologies. A high level of integration and full implementation of the power management functions specified in the IEEE 802.11 standard minimize the system power requirements by using AW-NB300SM. In addition to the support of WPA/WPA2 and WEP 64-bit and 128-bit encryption, the AW-NB300SM also supports the IEEE 802.11i security standard through the implementation of Advanced Encryption Standard (AES)/Counter Mode CBC-MAC Protocol (CCMP), Wired Equivalent Privacy (WEP) with Temporal Key Integrity Protocol (TKIP), Advanced Encryption Standard (AES)/Cipher-Based Message Authentication Code (CMAC), and WLAN Authentication and Privacy Infrastructure (WAPI) security mechanisms. For the video, voice and multimedia applications the AW-NB300SM support 802.11e Quality of Service (QoS). For Bluetooth operation, AW-NB300SM is Bluetooth 4.0, also complaint with Bluetooth 2.1 + Enhanced Data Rate (EDR). The AW-NB300SM supports SDIO for WLAN to the host processor. UART interface are available to connect the BT core the host processor. AW-NB300SM is suitable for multiple mobile processors for different applications. AW-NB300SM stamp module adopts Realtek latest highly-integrated WLAN & Bluetooth SoC---RTL8723BS. All the other components are implemented by all means to reach the mechanical specification required.
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值