MT7601 Drive Porting

Source: Internet
Author: User

1, decompression MT7601 drive
*TAR-XVF dpo_mt7601u_linuxsta_3.0.0.4_20130913.tar.bz2
CD dpo_mt7601u_linuxsta_3.0.0.4_20130913*

2, modify the makefile
This version of the driver package supports a variety of different platform compilation configuration, the default makefile compiler platform is the PC, see Makefile Line 30th:
#PLATFORM: Target PLATFORM
PLATFORM = PC
Modify the cross-compilation parameters and kernel paths for the PC platform (makefile line 198th) as follows:

Modified to:

Save Close

3. Check the WiFi node name
Android under Hal and the WiFi device node name in the script in the Wlan0, embedded in the Linux device in the WiFi device node name is generally used RA0, so you need to modify according to the actual application object, name definition location:
*CD dpo_mt7601u_linuxsta_3.0.0.4_20130913
VI include/rtmp_def.h +1604*
As follows:

So, if you are compiling a 7601 driver for the ANDROID platform, you need to turn on the compile macro parameter: Android_support. This parameter is defined in OS/LINUX/CONFIG.MK, see Config.mk line No. 373:
Ifeq ($ (has_android_support), y)
Wflags + =-dandroid_support
endif
That is, has_android_support=n or has_android_support=y to determine whether the WiFi node name is using "WLAN" or "RA". The "RA" node name in the Linux environment is used by default in the driver package.

4. Compile code to generate Mt7601usta.ko driver module
Since I was compiling the device for the arm platform, the compiler parameters of the PC platform were modified, and the makefile was dependent on the arch parameters, so we should also specify Arch=arm, and the following can compile the module:
Make Arch=arm chipset=7601u
If there is no problem with the above modification, the station mode WiFi driver module Mt7601usta.ko can be obtained after compiling, as follows:

5. Precautions
An error occurred at compile time, as shown in the following figure:

The reason is that the LINUX-3.0.Y kernel path was specified when modifying the Makefile PC platform compilation parameters: "LINUX_SRC =/lodb3/hi3518_sdk_v1.0.8.1/osdrv/kernel/linux-3.0.y", However, the kernel under this path is not compiled in advance, resulting in a missing kernel configuration file and module version information that is 7601 dependent and cannot be compiled. WORKAROUND: Recompile the kernel, and then compile the 7601 driver module after the kernel compiles.

6. Compiling Mt7601uap.ko
Before compiling the method of modification as above, do not repeat here.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.