1.修改设备树 /board/widora/mangopi/r3/devicetree/linux/devicetree.dts
&usb_otg {
dr_mode = "host"; /* host peripheral */
status = "okay";
};
2.下载驱动源码https://codeload.github.com/aircrack-ng/rtl8188eus/zip/v5.3.9
解压后拷贝到 /output/build/linux-5.4.66/drivers/net/wireless/realtek/rtl8188eus
2.1修改/output/build/linux-5.4.66/drivers/net/wireless/realte/Kconfig,加入
source "drivers/net/wireless/realtek/rtl8188eus/Kconfig"
2.2修改/output/build/linux-5.4.66/drivers/net/wireless/realte/Makefile,加入
obj-$(CONFIG_RTL8188EU) += rtl8188eus/
2.3修改 rtl8188eus/include/osdep_service_bsd.h,第120行改为
#define LINUX_VERSION_CODE KERNEL_VERSION(5, 4, 66)
3.加入wpa_supplicant工具
make menuconfig
localtion
->Target pckages
->Networking applications
[*] wpa_supplicant
4.make linux-menuconfig 配置网络
localtion
-*- Wireless --->
<*> cfg80211 - wireless configuration API
[*] support CRDA
[*] cfg80211 wireless extensions compatibility
<*> Generic IEEE 802.11 Networking Stack (mac80211)
[*] Minstrel
[*] Networking support --->
<*> RF switch subsystem support --->
->Device Drivers
[*] Network device support --->
[*] Network core driver support
<*> IEEE 802.1AE MAC-level encryption (MACsec)
[*] Wireless LAN --->
[*] mac80211-based legacy WDS support
[*] Ralink devices
<*> Ralink driver support --->
[*] Realtek devices
<M> Realtek 8188E USB WiFi
[*] USB support --->
<*> Support for Host-side USB
*** USB Host Controller Drivers ***
<*> EHCI HCD (USB 2.0) support
<*> Generic EHCI driver for a platform device
<*> OHCI HCD (USB 1.1) support
<*> Generic OHCI driver for a platform device
MUSB Mode Selection (Host only mode) ---> #别错过这里,否则USB模式可能会出错
<*> Inventra Highspeed Dual Role Controller
<*> ChipIdea Highspeed Dual Role Controller
[*] ChipIdea host controller
5.编译,刷机。
6.安装驱动,启动网卡,创建运行需要的临时文件夹
insmod ./lib/modules/5.4.66/kernel/drivers/net/wireless/realtek/rtl8188eus/8188eu.ko
ifconfig wlan0 up
mkdir -p /var/run/wpa_supplicant
7.新建配置文件 /etc/wpa_supplicant/wpa_supplicant.conf
ctrl_interface=/var/run/wpa_supplicant
ap_scan=1
network={
ssid="mishare" #wifi名字
psk="qwer1234" #wifi密码
}
8.链接网络
wpa_supplicant -B -i wlan0 -c /etc/wpa_supplicant/wpa_supplicant.conf
9.配置IP地址<暂时没有使用udhcpc工具>
ifconfig wlan0 192.168.137.202
离线
有时间了,再发布一个以package方式的驱动移植,完善脚本。
离线
支持8723BS吗这个驱动
离线
哪个板子,全志F1C200?
离线
请问我编译的时候总是报:ERROR unregister_inetaddr_notifier" undefined! 是怎么回事?是make menuconfig缺少了什么配置吗?
离线