我刚买了一个 Wireless-N USB 适配器(我只是复制了盒子的名字),它附带一个驱动程序 CD。在 CD 中我发现了 4 个文件夹,Android、Linux、Mac 和 Windows。在 Linux 文件夹中,我发现了一个文件夹 (DOC),其中包含 3 个 pdf 文件和三个 tar 文件:DPA_MT7601U_LinuxSTA_3.0.0.4_20130916.tar.bz2
、DPA_RT5572_LinuxSTA_2.6.1.4_20121211.tar.bz2
和RT5572_RT5372_Linux_AP_V2.7.1.1_Beta_DPA_20121113.tar.bz2
。
问题是这 3 个 pdf 文件(软件编程指南 3.3、软件移植指南、软件编程指南 1.2)就像关于如何编程或适配卡的说明,我只想安装驱动程序并使卡工作(我已经连接但什么也没发生)
我应该怎么办?
我的联想 G400 笔记本电脑上安装了 Ubuntu 16.04 LTS(内置无线网卡不工作),而且我不是 Ubuntu/Linux 系统专家:)
当我sudo lsusb
在终端上放置时,它显示以下内容:
Bus 002 Device 003: ID 174f:148d Syntek
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 004: ID 0bda:0129 Realtek Semiconductor Corp. RTS5129 Card Reader Controller
Bus 001 Device 003: ID 105b:e065 Foxconn International, Inc. BCM43142A0 Bluetooth module
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
~/DPA_RT5572_LinuxSTA_2.6.1.4_20121211$ make
make -C UTIL/ osutil
make[1]: Entering directory '/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL'
cp -f os/linux/Makefile.6.util /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/Makefile
make -C /lib/modules/4.13.0-37-generic/build SUBDIRS=/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux modules
make[2]: Entering directory '/usr/src/linux-headers-4.13.0-37-generic'
CC [M] /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../common/rt_os_util.o
CC [M] /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux_symb.o
CC [M] /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_rbus_pci_util.o
CC [M] /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_usb_util.o
CC [M] /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.o
In file included from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_os.h:48:0,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_comm.h:63,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:35:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘duplicate_pkt’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:516:18: warning: passing argument 1 of ‘memmove’ makes pointer from integer without a cast [-Wint-conversion]
NdisMoveMemory(skb->tail, pHeader802_3, HdrLen);
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:494:61: note: in definition of macro ‘NdisMoveMemory’
#define NdisMoveMemory(Destination, Source, Length) memmove(Destination, Source
^
In file included from ./include/linux/bitmap.h:8:0,
from ./include/linux/cpumask.h:11,
from ./arch/x86/include/asm/cpumask.h:4,
from ./arch/x86/include/asm/msr.h:10,
from ./arch/x86/include/asm/processor.h:20,
from ./arch/x86/include/asm/cpufeature.h:4,
from ./arch/x86/include/asm/thread_info.h:63,
from ./include/linux/thread_info.h:37,
from ./arch/x86/include/asm/preempt.h:6,
from ./include/linux/preempt.h:80,
from ./include/linux/spinlock.h:50,
from ./include/linux/seqlock.h:35,
from ./include/linux/time.h:5,
from ./include/linux/stat.h:18,
from ./include/linux/module.h:10,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:18,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_os.h:48,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_comm.h:63,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:35:
./include/linux/string.h:312:24: note: expected ‘void *’ but argument is of type ‘sk_buff_data_t {aka unsigned int}’
__FORTIFY_INLINE void *memmove(void *p, const void *q, __kernel_size_t size)
^
In file included from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_os.h:48:0,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_comm.h:63,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:35:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:518:18: warning: passing argument 1 of ‘memmove’ makes pointer from integer without a cast [-Wint-conversion]
NdisMoveMemory(skb->tail, pData, DataSize);
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:494:61: note: in definition of macro ‘NdisMoveMemory’
#define NdisMoveMemory(Destination, Source, Length) memmove(Destination, Source
^
In file included from ./include/linux/bitmap.h:8:0,
from ./include/linux/cpumask.h:11,
from ./arch/x86/include/asm/cpumask.h:4,
from ./arch/x86/include/asm/msr.h:10,
from ./arch/x86/include/asm/processor.h:20,
from ./arch/x86/include/asm/cpufeature.h:4,
from ./arch/x86/include/asm/thread_info.h:63,
from ./include/linux/thread_info.h:37,
from ./arch/x86/include/asm/preempt.h:6,
from ./include/linux/preempt.h:80,
from ./include/linux/spinlock.h:50,
from ./include/linux/seqlock.h:35,
from ./include/linux/time.h:5,
from ./include/linux/stat.h:18,
from ./include/linux/module.h:10,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:18,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_os.h:48,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_comm.h:63,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:35:
./include/linux/string.h:312:24: note: expected ‘void *’ but argument is of type ‘sk_buff_data_t {aka unsigned int}’
__FORTIFY_INLINE void *memmove(void *p, const void *q, __kernel_size_t size)
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘duplicate_pkt_with_VLAN’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:583:9: warning: passing argument 5 of ‘VLAN_8023_Header_Copy’ makes pointer from integer without a cast [-Wint-conversion]
skb->tail, FromWhichBSSID,
^
In file included from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:37:0:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rt_os_util.h:214:7: note: expected ‘PUCHAR {aka unsigned char *}’ but argument is of type ‘sk_buff_data_t {aka unsigned int}’
UCHAR VLAN_8023_Header_Copy(
^
In file included from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_os.h:48:0,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_comm.h:63,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:35:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:588:18: warning: passing argument 1 of ‘memmove’ makes pointer from integer without a cast [-Wint-conversion]
NdisMoveMemory(skb->tail, pData, DataSize);
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:494:61: note: in definition of macro ‘NdisMoveMemory’
#define NdisMoveMemory(Destination, Source, Length) memmove(Destination, Source
^
In file included from ./include/linux/bitmap.h:8:0,
from ./include/linux/cpumask.h:11,
from ./arch/x86/include/asm/cpumask.h:4,
from ./arch/x86/include/asm/msr.h:10,
from ./arch/x86/include/asm/processor.h:20,
from ./arch/x86/include/asm/cpufeature.h:4,
from ./arch/x86/include/asm/thread_info.h:63,
from ./include/linux/thread_info.h:37,
from ./arch/x86/include/asm/preempt.h:6,
from ./include/linux/preempt.h:80,
from ./include/linux/spinlock.h:50,
from ./include/linux/seqlock.h:35,
from ./include/linux/time.h:5,
from ./include/linux/stat.h:18,
from ./include/linux/module.h:10,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:18,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_os.h:48,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_comm.h:63,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:35:
./include/linux/string.h:312:24: note: expected ‘void *’ but argument is of type ‘sk_buff_data_t {aka unsigned int}’
__FORTIFY_INLINE void *memmove(void *p, const void *q, __kernel_size_t size)
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘ClonePacket’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:709:20: warning: assignment makes integer from pointer without a cast [-Wint-conversion]
pClonedPkt->tail = pClonedPkt->data + pClonedPkt->len;
^
In file included from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_os.h:48:0,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_comm.h:63,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:35:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘RtmpOsPktInit’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:967:34: warning: assignment makes integer from pointer without a cast [-Wint-conversion]
((RTPKT_TO_OSPKT(_pkt))->tail) = (PUCHAR)((_start) + (_len))
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:728:2: note: in expansion of macro ‘SET_OS_PKT_DATATAIL’
SET_OS_PKT_DATATAIL(pRxPkt, pData, DataSize);
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘wlan_802_11_to_802_3_packet’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:755:15: warning: assignment makes integer from pointer without a cast [-Wint-conversion]
pOSPkt->tail = pOSPkt->data + pOSPkt->len;
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘__RtmpOSFSInfoChange’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:1209:20: error: incompatible types when assigning to type ‘int’ from type ‘kuid_t {aka const struct <anonymous>}’
pOSFSInfo->fsuid = current_fsuid();
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:1210:20: error: incompatible types when assigning to type ‘int’ from type ‘kgid_t {aka const struct <anonymous>}’
pOSFSInfo->fsgid = current_fsgid();
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘RtmpOsFreeSpinLock’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:4429:8: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
pLock = (OS_NDIS_MINIPORT_TIMER *) (pLockOrg->pContent);
^
In file included from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_os.h:48:0,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/rtmp_comm.h:63,
from /home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:35:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘RtmpOsPktTailAdjust’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:967:36: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
((RTPKT_TO_OSPKT(_pkt))->tail) = (PUCHAR)((_start) + (_len))
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:991:2: note: in expansion of macro ‘SET_OS_PKT_DATATAIL’
SET_OS_PKT_DATATAIL(_pkt, GET_OS_PKT_DATATAIL(_pkt), (-_removedTagLen)); \
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:5257:2: note: in expansion of macro ‘OS_PKT_TAIL_ADJUST’
OS_PKT_TAIL_ADJUST(pNetPkt, removedTagLen);
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:967:34: warning: assignment makes integer from pointer without a cast [-Wint-conversion]
((RTPKT_TO_OSPKT(_pkt))->tail) = (PUCHAR)((_start) + (_len))
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:991:2: note: in expansion of macro ‘SET_OS_PKT_DATATAIL’
SET_OS_PKT_DATATAIL(_pkt, GET_OS_PKT_DATATAIL(_pkt), (-_removedTagLen)); \
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:5257:2: note: in expansion of macro ‘OS_PKT_TAIL_ADJUST’
OS_PKT_TAIL_ADJUST(pNetPkt, removedTagLen);
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c: In function ‘RtmpThreadPidKill’:
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/include/os/rt_linux.h:526:37: error: implicit declaration of function ‘kill_pid’ [-Werror=implicit-function-declaration]
#define KILL_THREAD_PID(_A, _B, _C) kill_pid((_A), (_B), (_C))
^
/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.c:5355:9: note: in expansion of macro ‘KILL_THREAD_PID’
return KILL_THREAD_PID(PID, SIGTERM, 1);
^
cc1: some warnings being treated as errors
scripts/Makefile.build:308: recipe for target '/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.o' failed
make[3]: *** [/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux/../../os/linux/rt_linux.o] Error 1
Makefile:1550: recipe for target '_module_/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux' failed
make[2]: *** [_module_/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL/os/linux] Error 2
make[2]: Leaving directory '/usr/src/linux-headers-4.13.0-37-generic'
Makefile:500: recipe for target 'osutil' failed
make[1]: *** [osutil] Error 2
make[1]: Leaving directory '/home/brandon/DPA_RT5572_LinuxSTA_2.6.1.4_20121211/UTIL'
Makefile:3: recipe for target 'all' failed
make: *** [all] Error 2
答案1
查看可用驱动程序的文件名,可以推断出该设备使用 MT7601U 或 RT5572 ralink 芯片组。
MT7601U 应该可以在 Ubuntu 16.04 及更高版本上自动运行。
RT5572 使用 rt2800usb 驱动程序,也应该可以自动工作。
查看您在尝试编译驱动程序时收到的错误消息和警告,我相信它们是为旧内核编写的,因此无法在您的系统上编译。
当您插入/拔出适配器时,lsusb、dmesg 或 syslog 中都没有显示任何内容,这让我认为您的 USB 插槽没有为设备提供足够的电力。尝试使用有源 USB 集线器。