You are not logged in.

Dear visitor, welcome to HDSC-Board Home of Pur-E2 Image . If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.



  • "delfi" started this thread

Posts: 1,294

Activitypoints: 16,595

Date of registration: Mar 14th 2013

net.hawkes.userlevel.level 43 [?]

net.hawkes.userlevel.experience 3,461,177

net.hawkes.userlevel.nextlevel 3,609,430

Thanks: 1389 / 609

  • Send private message


Monday, December 9th 2019, 6:22am

Ralink 5370/samsung MediaTek 7601 WiFi

A bit obscure topic,alas, the intention is to spare some time for anybody trying to use **iwpriv** (and to remind me never to mess with WiFi drivers even if a good friend asks for it:) )
In new kernel (3x.+, especially 4.2+) these WiFi drivers work pretty good, even better, but sadly "iwpriv" capability is removed, hence... the fun and joy...

This is just a coarse bunch of suggestions as there are simply too many specifics and "what if" and "ahh, then else" situations, but could be useful as a start.

In most cases one needs some Linux distro with 2.6.xx-xx kernel.
This punishment is a sort of prerequisite for "iwpriv" command to work properly. See boring tech note 1.
Venerable ubuntu 10.04 should do nicely (with some hocus-pocus).

32 bit image: Ubuntu 10.04.4 desktop

Once the image is downloaded, flash it to an 4GB+ USB stick, preferably, with some tool that supports persistence. For Linux check something like mkusb: How to - persistence
For Win, there are a few USB writers that support this feature. Please google it.

Flash the ISO. Try to avoid latest and best USB 3.x sticks as they **might** NOT boot from an older PC/laptop. See boring tech note 2.

Once you boot your laptop/whatever from an USB stick, we do enter a bit of drama. See boring tech note 3.

At this stage one should be able to use "iwpriv" in RW mode.
For more advanced stuff or possible other needs:

Install a HEX editor: "sudo apt-get install okteta" (this is a biggie as it usess KDE support environ, sadly, "bless" or similar are not in the feeds).
Crucial for me: install mc (sort of Norton Commander clone from MSDOS era). Again, not in the feeds, get it from, say here: mc for ole stuff
Just a reminder - See boring tech note 4.

With the last step one could edit *.ko drivers and change ViD/PiD to make drivers support a normal OS (say you want to get back an old Samsung only WiFi adapter or vice versa).

Or, compile a driver that needs "iwpriv" fix. Check the old, or rather original and working for this purpose sources from the ralink web or elsewhere. Be sure NOT to use newer drivers that might support new kernels but not the iwpriv, which is the whole idea of this post.
You might wish to add your ViD/PiD in a file that defines it, usually something along lines of "rtusb_dev_id.c". dev-id in the name should point you to the right stuff.
See boring tech note 5.

For 5370 devices e2p addresses are 208 for ViD and 20A for PiD
"sudo iwpriv ra0 e2p 208=140f" (or 4E8 for Samsung TV)
"sudo iwpriv ra0 e2p 20a=5370" (or 2018 to make it for Samsung TV)

For 7601 devices e2p addresses are 12 for ViD and 14 for PiD

Again, this is really not a "how to" guide but a simple directions. Hope it helps someone and save the time that I have wasted:)

Boring Tech Note 1:
Anything newer with kernel above 2.6.xx-xx will make your life miserable. On some older distros like Mint 13, iwpriv might read data, but canNOT write it to nvram/eeprom. VMware or Virtualbox may work, but you'll spend more time adjusting it then preparing/booting good ole' 10.04.x from an USB stick.

Boring Tech Note 2:
It might be prudent to use an older (say 2005+ up to 2015 laptop/Desktop). Newer/newest boxes should work, but if you get in trouble with unrecognized HW --> not worth the trouble.

Boring Tech Note 3:
Feeds for old ubuntu, as is, are down. The list for updates/sw dload points to a non existing url in "/etc/apt/sources.list". You might not need them, otherwise: from the terminal enter: "sudo sed -i 's/archive/old-releases/' /etc/apt/sources.list" OR "gksudo etc/apt/sources.list" and replace all the occurances of 'archive' with 'old-releases'
After this step, do type in the terminal; "sudo apt-get update"

Boring Tech Note 4:
New linux distros (some of them) enforce digital signing of drivers (*.ko stuff). Therefore, one cannot hexedit them.

Boring Tech Note 5:
Whilst a simple "make" in the driver directory will **usually** make the trick, sometimes it may not be enough. 7601 drivers need a writable "/tftpboot" (mkdir, chmod 0777, chown, etc). This should not prevent a nice compile as a new *.ko driver/LKM is in the source like os/linux or similar.

1 registered user thanked already.

Users who thanked for this post:

terrajoe (09.12.2019)