Installing Mediatek drivers - Orin NX

Hello,

I am attempting to get both Mediatek MT7612u and MT7612e wifi modules working on my Orin NX. However, there do not appear to be any Mediatek drivers included in my Ubuntu install. Is it possible to manually install them?

Running Jetpack 6 DP/Ubuntu 22.04 installed via SDKmanager on a custom carrier board.

If you run “dmesg --follow”, and the monitor what new log lines occur as a result of plugging this in, what do you see?

Also, what do you see from:
zcat /proc/config.gz | egrep 'MEDIATEK'

There might be firmware required. Most of the time the firmware which goes on a wireless device is independent of the host architecture, so if this is required, then probably it is the same across desktop Linux and 64-bit ARM.

I have not looked closer, I’ve never seen one of these devices, but found this reference on the device:

“dmesg” output:

[  293.885072] usb 2-1.1: new SuperSpeed USB device number 6 using tegra-xusb

“zcat” output

CONFIG_ARCH_MEDIATEK=y
# CONFIG_ARM_MEDIATEK_CPUFREQ is not set
CONFIG_ARM_MEDIATEK_CPUFREQ_HW=m
# CONFIG_PCIE_MEDIATEK is not set
# CONFIG_PCIE_MEDIATEK_GEN3 is not set
# CONFIG_SCSI_UFS_MEDIATEK is not set
# CONFIG_NET_VENDOR_MEDIATEK is not set
# CONFIG_DWMAC_MEDIATEK is not set
# CONFIG_MEDIATEK_GE_PHY is not set
CONFIG_WLAN_VENDOR_MEDIATEK=y
# CONFIG_MEDIATEK_WATCHDOG is not set
# CONFIG_VIDEO_MEDIATEK_JPEG is not set
# CONFIG_VIDEO_MEDIATEK_VPU is not set
# CONFIG_VIDEO_MEDIATEK_MDP is not set
CONFIG_DRM_MEDIATEK=m
CONFIG_DRM_MEDIATEK_HDMI=m
# CONFIG_USB_MUSB_MEDIATEK is not set
CONFIG_COMMON_CLK_MEDIATEK=y
# CONFIG_MEDIATEK_MT6577_AUXADC is not set
CONFIG_PWM_MEDIATEK=m

And for a little more general info on the wiki adapters. I’m using the AsiaRF WS2433 adapter which is a PCIe module based on the MT7612e. Also I’m using the Alfa network AWUS036ACM which is a USB module based on the MT7612u. The terminal output in the previous post is from the Alfa network adapter.

I don’t know which drivers are used for the PCIe version (I don’t know much about this hardware in general, but what I read was on USB versions).

Generally speaking one needs a driver for some function, plus a driver for the physical interface (the PHY). The USB and PCIe versions would use the same drivers for function, but as you can see in your /proc/config.gz you are missing some PCIE symbols. I don’t know which, but I suspect one of these two (this really needs some research to verify):

  • # CONFIG_PCIE_MEDIATEK is not set
  • # CONFIG_PCIE_MEDIATEK_GEN3 is not set

Something to think about while experimenting with this: Not all drivers are compatible with each other, and many drivers have dependencies on other drivers. You are likely going to need to do some kernel compiling, but if you can try these as module format, and if you start with a kernel configuration otherwise matching the running kernel (such as via the tegra_defconfig build target), and if you set to the default CONFIG_LOCALVERSION of “-tegra”, then it is as simple as copying files to the correct subdirectory of “/lib/modules/$(uname -r)/kernel” to test.

Regarding some of those requirements, be sure when building any kernel source to change and edit with a dependency-aware editor. A lot of people use the make target menuconfig, but I like nconfig (which is the same as menuconfig, but it has a symbol search function).

If you need more information on kernel build and install just ask. The official docs are good for cross compile on a host PC, but are centered around flashing for adding kernel customization. Just ask for whatever details you need as you go along. There are probably some differences in the JetPack 6 kernel instructions compared to the earlier releases, and I have not tried to compile for that yet, but it’s the install steps which you’d most likely need help with.

I did a test on an Orin Nano and Orin NX with Jetpack 5.1.2/Ubuntu 20.04 installed. The drivers are present and functional for both the USB and PCIe based adapters. I may stick with this for now as kernel compiling is out of my range of experience.
Hopefully once Jetpack 6 is out of developer preview status, it will have comparable driver support.

One other thing to consider, other than drivers, is that many Wi-Fi devices have firmware which has to upload into the device each time it is booted. At some later time when you revisit a JetPack 6 non-DP release is that sometimes if the driver is there, but it doesn’t work, then it might be because the Wi-Fi device still needs firmware.

Trivia: Radio transmitters are regulated differently in different regions of the world. Manufacturers must comply in order to sell there. Manufacturers have to use one of these choices:

  • Don’t sell in regions the device is not compliant in.
  • Create a different model of device for every region.
  • Create the same device, but use firmware to load into the device such that it complies with the region of the firmware.

Obviously the latter is what most manufacturers choose. Whenever you have issues with a device that has a transmitter in it be careful to check if the device has firmware. Note that since the firmware uploads into the device it is usually independent of which platform it runs on, e.g., the same firmware probably works for desktop PC Linux as that used in arm64 Linux, and maybe the same firmware even works in Windows too (though it would likely have different packaging).

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.