Thursday, July 30, 2015

Convert Huawei E3372h-153 from HiLink/router-mode to Stick/modem-mode

Modern Huawei USB LTE modems can be used in two very different modes. Default is HiLink mode where it functions as router doing NAT and other nastiness much like more traditional 4G routers connected over WLAN or Ethernet. Unsurprisingly default mode is HiLink, but luckily it can be changed to Stick mode getting rid at least one layer of NAT, fixing IPv6 support etc.

Actually there's also third mode which is subset of Stick, instead of native NCM interface it uses legacy PPP over emulated serial port. This can be sometimes useful with older routers with USB port but you won't be able to reach full speed in this mode.

Internet has plenty of information on how to do that. As it often is not all of that is true. Most interesting bits are also written in Russian. Despite huge improvements in translations from Google Translate it's still bit hit and miss.

Following these instructions will also resolve Error Code 19 and "brick" with Error Code 13 (rapidly flashing green led). Which is also why some steps may seem bit pointless at first. Feel free to skip them and then start again from beginning when Mr Error #19 and Mrs. Error #13 bite you. :)

You'll need Windows PC for this. I used 64-bit Windows 7 PC myself.

If you've tried this before coming to here I'm sure you've seen those "open http://192.168.8.1/html/switchProjectMode.html" instructions. Those are for older models like E3372s and won't work with E3372h.

Hold tight!

  • Visit either one of these sites to calculate device specific "Flash code" based on your IMEI and write it down.
  • Download and extract this ZIP that contains required tools, drivers and firmware images
  • Install "[1] Mobile Broadband HL Service" by running mbbServiceSetup.exe
    • Installs RNDIS driver
    • Installs service to switch from CD emulation to RNDIS (like usb-modeswitch on Linux)
  • Install "[2] Datacard Driver" by running DriverSetup.exe
    • Installs serial port drivers (v5.05.01.00)
  • Insert E3372h-153 with HiLink firmware to USB port
    • Preferrably directly to PC, avoid cheap chinese USB extension cables.
    • Open Device Manager and verify that RNDIS interface is present under Network adapters
    • Open command prompt and "PING 192.168.8.1" to make sure HiLink firmware is running
  • Run "sw_project_mode.cmd" from "[3] Switchmode E3372h" folder
    • This will enable "PC UI" serial port required for firmware upgade
    • Wait until you can see it under Ports in Device Manager
  • Run "Update_WEBUI_17.100.06.00.03_Hilink_V7R2_9x25_CPIO.exe" from "[4] Huawei E3372h WebUI"
    • This updates user interface but doesn't touch rest of the firmware.
    • If you have Error Code 13 this will fix it. Code 13 ("Authentication failed") is caused by failed attempt to flash firmware resulting in Error Code 19 ("Download failed").
    • See HUAWEI_Module_Firmware_Upgrade_Guide_on_Windows_V100R001_01(5).pdf for complete list of error codes.
    • Wait until WebUI update is complete and you can ping 192.168.8.1 again.
  • Run "sw_project_mode.cmd" from "[3] Switchmode E3372h" folder
  • Run "E3372h-153_Update_22.180.05.00.00.exe" from "[5] Huawei E3372h-153 HiLink FW" folder.
    • This upgrades (or downgrades) your HiLink firmware version. You will need Flash code from one of those calculators to do this.
    • Wait until HiLink update is complete and you can ping 192.168.8.1 again.
  • Run "sw_project_mode.cmd" from "[3] Switchmode E3372h" folder
  • Run "E3372h-153_Update_21.180.01.00.00.exe" from "[6] Huawei_E3372h-153 Stick FW" folder.
    • This finally changes firmware from HiLink to Stick. You will need Flash code again.
    • Wait until Stick update is complete. You can no longer ping 192.168.8.1 and RNDIS adapter has changed to "HUAWEI Mobile Connect - Network Card".
  • Run "putty.exe" from "[7] Putty" folder
    • Find serial port name from Device Manager, for example in case of "HUAWEI Mobile Connect - PC UI Interface (COM15)" port name is COM15
    • Click Serial on right hand side of Putty screen and type COM15 or whatever your port is.
    • Click Open on botton of Putty
    • Type ' ATE1 ' without quotes, you won't see what you type and DO NOT try to use backspace. If you did it right you got ' OK ' as reply. Ignore ^RSSI etc. lines you might also see.
    • Type following commands one per line to see info about your device and verify connection works. 
      • ' ATI '
      • ' AT^FHVER '
      • ' AT^VERSION? '
    • Get current SETPORT value by typing ' AT^SETPORT? '. You might want to write these down if you ever want to revert back to defaults. Mine was ' ^SETPORT:A1,A2;12,1,16,A1,A2 '.
    • Set new SETPORT value by typing ' AT^SETPORT="FF;12,16" ', this disables CD emulation, disables modem emulation (PPP) and enables NCM mode.
    • If you want to keep PPP support for example for older router with USB port use ' AT^SETPORT="FF;12,10,16" ' instead. Remember that you won't get full speed with PPP.
    • Reset modem by typing ' AT^RESET '.
    • Close Putty now.
  • Done. 

Your E3372h is now in stick mode, presents itself as NCM device that's compatible with Windows Mobile Broadband feature and also with huawei_cdc_ncm under Linux. You don't need 3rd party mobile tools on Windows or usb-modeswitch in Linux either.

This means to connect Internet use built in features of your operating system, stay away from "Mobile Partner" etc. You can also now uninstall "Mobile Broadband HL Service", it's no longer necessary and means there's one suspicious service less running on background.

If you prefer keeping HiLink why not root it? If you don't root it someone else probably will given Huawei track record on security... There's excellent writeup and step-by-step instructions in English from Ivan. Modeswitch tools are also from him. 

Rest of files were collected from links found on lteforum.at4pda.ru and 3Ginfo.ru.

P.S. You can get E3372h-153's from Ebay for 29€/each including shipping from Latvia. Downside on these super cheap ones is broken locking tabs on top cover. This is because they're LMT branded and were superglued shut with LMT SIM card inside.

62 comments:

  1. thanks for your help, everything worked with a new lmt 3372h-153! (via lteforum.at) -dash

    ReplyDelete
  2. Thank you. Life saver for both error codes and for PPP trick as well. Owe you a bear mate.

    ReplyDelete
  3. Thank you very much! I converted my dongle without any problem.

    ReplyDelete
  4. Grazie mille!!!
    Thank you, worked flawless..but still not working with my dovado 4GR...any idea? Or should I switch to another router?

    ReplyDelete
  5. I did it, thanks....., but now i can't connect to internet (under XP sp3 - error 678), and even under Ubuntu 14, i can't create connection.....any idea, what is wrong - parameters?????

    ReplyDelete
  6. Thanks a mil. GREAT guide. Finally got my stick in non hilink mode.

    ReplyDelete
  7. Error code 10 after bad Flash :-( how fix IT?

    ReplyDelete
  8. Tutorial on the rating 6.
    Instead e3372s got from the seller e3372h, described the software change process flawlessly - thanks to you it worked.
    Thanks a lot
    Thanks a lot

    ReplyDelete
  9. Thanks you so much. Finally, My modem is converted. :)

    ReplyDelete
  10. Hi, it looks like I'm stuck at [3] Switchmode E3372h sw_project_mode.cmd

    curl: (56) Recv failure: Connection was reset
    Press any key to continue . . .

    ReplyDelete
    Replies
    1. Hello, It happened to me too but I just ignored and marked that step as completed(on my mind) and continued. Finally I converted my modem successfully.

      Delete
    2. try to install driver for modem

      Delete
  11. Hi, nice walk through, but I'm stuck trying to flash the WebUI in step 4, getting the #19 error. My stick is on firmware 22.200.15.00.00 and WebUI 17.100.05.06.965. Update Wizard is not asking for any key but stops working when it is just about half way. Stick restarts and after a while I get error #19. Rgds Sven

    ReplyDelete
    Replies
    1. Start from the beginning as mentioned on this post.

      Delete
    2. I have the same problem (firmware 22.200.15.00.182, WebUI 17.100.12.00.182), step 4 fails with error #19.
      Starting from beginning won't help, either.

      Also, the stick doesn't respond from IP 192.168.8.1, but from 192.168.1.1, which can be modified to cmd scripts.

      Delete
    3. Thanks for the procedure and tools.
      Unfortunately I have same problem here as mentioned by Gar and Olli.
      While loading WebUI firmware, it stops working when it is just about half way, and then error 19 pops up. Also I see that the "PC UI" port disappears from the Device Manager right after Web UI firmware loading has started.
      And I also get the error "curl: (56) Recv failure: Connection was reset" after running "sw_project_mode.cmd". IP is 192.168.1.1 not 192.168.8.1, but as was mentioned before, I also changed it to the script.

      Dongle is DNA branded E3372H-153 and my PC has Windows 10 64bit.
      Ohjelmistoversio(firmware): 22.200.15.00.182
      Web UI -versio: 17.100.12.00.182

      Delete
    4. i am haveing the same issue. i have tried everything i can think of but it still stops halfway after downloading the webui, and while it gets stuck there the PC UI port disappears. i have tried it on different machines no luck.

      Delete
    5. hi. For anyone having the same troubles as me. Recent firmwares are locked against updates. But there is one way to do it: http://4pda.ru/forum/index.php?showtopic=582284&st=8400#entry40683419
      It worked fine for me and i finally have the configuration i want together with openwrt. But it requires you to open the device. Google translate helped a lot. Let me know if there is a step you don't understand. For example i didn't remove the battery because i didn't find one, i simply disconnected and reconnected the device.

      Delete
  12. Hi,

    Thanks for gathering the info and putting them together here. I've got one problem now : how can I use it on linux?

    It's now working as NCM Network Control Modem instead of CDC Ethernet Control Model and I see a wwan0 in if config but I can not reach the Internet.

    Any clue on this?

    ReplyDelete
  13. should the microsd card work in such stick mode modem? I put a miscrosd card in the slot but windows doesn't see it.

    ReplyDelete
    Replies
    1. Like another Anonymous commented try playing with SETPORT values. You could start with: AT^SETPORT="FF;12,16,A2"

      Delete
  14. No (AT^SETPORT="FF;12,16"), you should be able to add it with proper AT^SETPORT=.

    ReplyDelete
  15. Wonderfull !! Worked fine with my E3372h-153 ! Very nice ! Thank you so much dude !

    ReplyDelete
  16. Hi
    I have E3372s-153 dongle.. I have difficulties finding firmmares (HiLink / Stick FW) for S model..

    http://translate.google.com/translate?hl=en&sl=auto&tl=en&u=https%3A%2F%2F3ginfo.ru%2Fdownloads1049.html

    Can you assist on this on?

    ReplyDelete
    Replies
    1. This comment has been removed by the author.

      Delete
    2. This comment has been removed by the author.

      Delete
    3. Here is the way and files I used to switch my e3372s-153 from hilink to stick
      https://drive.google.com/file/d/0B84-iQshkY89ZEtqSC1Tb1poV28/view?usp=sharing

      Delete
    4. I managed to get Hilink away from E3372s-153 - how ever Dongle is not any more working on Windows workstation.
      My usecase is to use it with WLAN router and dongle is working now well with it.
      So I didn't find out what caused the problem that it does not work in windows.

      Gnuton thanks for the files for S-model .. I will test to update the stick with those

      Delete
  17. did anyone get ipv6 working after after this convert?

    ReplyDelete
  18. This comment has been removed by the author.

    ReplyDelete
  19. I'm about to do this on 50 modems.. I might try to put together a tool to automate the process (depends on whether my boss wants me to put in the hours to do so)

    ReplyDelete
  20. Help me please i have my huawei with green flash light, i enter with com port 3 with putty, send comand like ate1 but it don't respose

    ReplyDelete
  21. Very well written, thank you.
    Is there any procedure to revert back to Hilink ?

    ReplyDelete
  22. Because this site helped me a lot I would like to share a tiny bit of knowlage that also helped me.
    I had Error 13 and/or Error 19, both with very often flashing blue led on the modem. That means modem hanged in "download mode". Basicly it means that modem is a "brick".. To do anything with that you have to "unbick it".
    Download stript below, unrar files. Next check a COM number of your modem in hardware manager in your Windows and run a script from a command shell with parameter "COMXX" where XX is a number taken from your hardware manager. I always found two coms assigned to my modem, the second one from the list worked with the script.

    https://www.dropbox.com/sh/szyiili6kyua5u8/AACC-4BPfSGX7FEyFPqABlDoa/exit_download_mode_E3372h/exit_download.rar?dl=0

    After that try to flash modem by using :
    "E3372h-153_Update_22.180.05.00.00.exe" from "[5] Huawei E3372h-153 HiLink FW" folder.

    from THIS SITE!!! I tried about 10 other updaters and only one from this site worked. I'm not really sure why, but is seems that e3372h-153 are in at least two subversions and custom roms from one can make an error on other one and you finish with brick state modem (error 13/19).

    Thank you and good luck!

    ReplyDelete
  23. do you also have a tool which converts the e3131 hilink to non hilink?

    ReplyDelete
  24. This shit broke my Win 7. Can't open device manager after steps 1 and 2. It just crashes Micro$oft Management Console. Tried to reboot but no. I guess I'll have to reinstall Windows now.

    ReplyDelete
    Replies
    1. OK had it fiex. I guess I had something else causing the problem.

      But I cant make the flash. I get Error 19 always. Marcins fix doesnt work either.

      Delete
  25. Thanks alot. Got the "curl: (56) Recv failure: Connection was reset", but just ignored that and followed the instructions and it worked perfectly for my LMT-branded e3372h-153, which i ordered last week from ebay. I wonder if theres a later version of this: "E3372h-153_Update_21.180.01.00.00.exe" from "[6] Huawei_E3372h-153 Stick FW" and if there is, would it be possible to just replace that file with a newer file?

    ReplyDelete
    Replies
    1. Let me know also if you find a newer version than that, which works.

      Delete
  26. Hello, thanks for great how-to, I successfully converted my e3372h to modem mode.
    There was only one problem in my case, after switching mode in step number 3 there was no serial port interfaces available.
    It seems that in step 2 there are some missing drivers, after typing "fcserial.sys" into google i downloaded missing driver from link:
    http://www.mediafire.com/download/39p188qk2bfu563/Huawei-Debug-and-Project-mode-drivers-FcSerial.zip
    Then I opened Device Manager and clicked on unknown huawei_mobile device and selected driver update and after that the serial port was detected.



    ReplyDelete
    Replies
    1. Thank you for this hint. I ran into the same problem and the drivers that you provided fixed it.

      Delete
  27. Hello , thank for your great post , can i use it for E3372 Not E3372h ?

    ReplyDelete
  28. Thank you for super step by step. I kill 2 days before found your post and convert e3372h to nonHilink mode in 15 minutes :). Also want know is safe to update to newest fw (or just use new fw in step 6).

    ReplyDelete
  29. For some reason my usb dongle restarts when i try to do step 4. Anyone have fix for that? I have tried it now several times and everytime Uptade fails in Error 19. Any fixes???

    ReplyDelete
  30. I needed the 3g/4g modem to disable the cd emulation but leave the SD card enabled (because I have a really tiny OpenWRT router that has 8 MB of flash, with this enabled I can expand its firmware features using the sd card in this device).

    this is the command I used (also leaving modem open) AT^SETPORT="FF;12,1,16,A2"

    Other interfaces are explained here

    http://forum.mikrotik.com/viewtopic.php?t=89458

    Quoting relevant part here just in case
    -------------
    found theese settings using AT^SETPORT, and AT^GETPORTNAME:
    AT^SETPORT="initial_mode;normal_mode"

    map:
    1 - Mobile Data Modem (MDM)
    5 - GPS interface
    6 - control interface
    12 - PC UI
    10 - modem?
    16 - NDIS
    A1 - Virtual cd
    A2 - TF card reader
    FF - Dummy (disable modeswitch when using this as the initial mode?)
    ----------------

    ReplyDelete
  31. Thank you for your great tutorial, it was very easy to follow.

    I've used Windows 10 (64 bits) and, for some reason, Putty was unable to connect to the COM port. I even tried running Putty as Administrator, but still no luck. So I booted in my Ubuntu 14.04 (also 64 bits), installed gtkterm and issued the following command under root account:
    gtkterm -e -p /dev/ttyUSB0

    This way you don't need to set echo on with the command "ATE1". After this, all the AT commands were successful.

    Meanwhile, my e3372h works in NCM mode under Windows, but not in Ubuntu. My kernel version is 3.16.0-67, maybe I need a newer kernel version, or are there any drivers I should install?

    For now I've enabled the PPP mode to keep compatibility with Linux.

    ReplyDelete
  32. Hello, Does anyone here have b315s-936? I think they are related to HiLink.
    Because when we flash/update the firmware to 21.313, when in USB Mode, it's not detected in COM Ports(PC UI) anymore unlike the low versions. As a result, we can't send AT commands as well as return to previous firmware version.

    I followed this tutorial hoping to get back the PC UI interface but sad to say it's not working. :(

    Any other way to detect in COM Ports or to send AT Commands?

    ReplyDelete
  33. nice work well !!
    how can we back to HiLink mode ?

    ReplyDelete
  34. Hi
    after setting modem into PPP (AT^SETPORT="FF;12,10,16") modem dosent go into debug mode. After writing: AT^GETPORTNAME i get only:
    ^GETPORTMODE: TYPE: WCDMA: huawei,,pcui:0,modem:1,ncm:2
    Whats wrong that it doesnt open all ports..wel it even doesn't open the ones I specified as a normal mode...
    any idea?

    ReplyDelete
  35. thanks, everything worked , only 10 minutes in the process

    ReplyDelete
  36. What is the procedure to come back from hilink?

    ReplyDelete
  37. Hello, Please help me.I have my e3372h on hilink mode and it is not connecting. I do not know what is the problem. Can I use windows 8.1 PC rather than Windows 7 and get it to stick mode.

    ReplyDelete
  38. I bricked my E3372h-153 stick, please I try everything and still nothing, please can someone help me...

    ReplyDelete
    Replies
    1. pls give more details, what u did before bricking, and now when connect it to pc what happens?

      Delete
  39. I try to upgrade him, I now when I connect him to PC nothing happen it only blinks

    ReplyDelete
  40. after flashing firmware from step 4 the modem is flashing fast the green light. how can i unbrick the modem?thank you

    ReplyDelete
  41. Tried and it works like a charm. But everytime (or almost) i plug in the stick i have to reinstall the datacard driver in order for the computer to recognize the key. Have i missed something?

    ReplyDelete
  42. I've bricked my e3372h, The process worked fine till I've installed the FW from forlder 5. Afterwords I could not connet to the stick anymore. If I plug it in nothing happends, just keeps blinking. No Com ports show up or network adapters in the device manager. Retryed the proceudre sevral time without luck. Can someone help me please?

    ReplyDelete
  43. Instructions worked well. Now when in stick-mode, Dovado pro ac works extremely well with e3372h but when connected to Asus RT-AC68U router, dongle can't get connection to 4G/LTE. Just tries to connect and keeps blinking cyan (trying to connect to 4G). What might be the issue with Asus?

    ReplyDelete
  44. Wow. Working very well on windows 10. I was ready to burn my E3772 150-2 dongle. Now it's seen as "cellular device" under windows 10 like any other before. Thx.

    ReplyDelete

Got something to say?!