Recovering Semi-Bricked E3276s-920
I recently purchased an E3276s-920. Modem works really well and it was a non Hi-Link version. I was curious about the Hi-Link version so I flashed the Hi-Link firmware and WebUI and it worked perfectly fine apart from not having the built in router functionality that I've read about.
I subsequently tried to flash back to normal mode since Windows was not sharing the ethernet connection with my wifi router. This is when the problems started. I tried flashing the non Hi-Link firmware first and it stopped and complained about user device info or unrecognised devices... cant remember which exactly. I thought it may be because the WebUI portion of the Hi-Link firmware may be attributing to the problem. So I flashed the normal dashboard firmware. It flashed fine without error. When the modem restarted only the virtual CD with Mobile Partner was available.
I had installed the Hi-Link drivers previously so the PC detected the Hi-Link Remote NDIS based internet sharing device and installed the driver. So basically I was running Hi-Link firmware and the normal non Hi-Link dashboard firmware.. a frankenstein combo of sorts.
Problem with this situation is no COM ports were available to flash back to the non Hi-Link firmware.... and I couldn't switch the modem back to serial port mode using
http://192.168.1.1/html/switchProjectMode.html at all. I have an inkling that it was because it needs the WebUI firmware and I had the Dashboard firmware flashed.
The below is how I managed to recover the modem as it was not able to reach the 192.168.1.1 address for the WebUI to connect and the normal dashboard could not detect any device since the modem was in ethernet mode (Hi-Link). I am unfamiliar with Linux so I'll try to cater for those members also.
1. I used the Ubuntu 14.04 Live DVD from
here. Its a hybrid iso and will prompt you to "try"(Live OS) or install.I used the 64 bit version.
2. Install
setserial_2.17-45.3_amd64.deb (Not sure if it helped communicate with the modem). Install it anyway.
3. Install
wvdial_1.60.3_amd64.deb.
4. Install
Huawei Data Cards Linux Driver. You might have a problem with the NDIS driver during installation. The fix and installation instructions are
here.
5. Open a terminal(Ctrl-Alt+T) and switch to superuser (admin).
6. Plug modem in and wait a few seconds. Enter "lsusb" to list all your USB devices. Your Huawei modem should appear with a vendor and product ID simular to "12d1:1f01". If its not in this mode (default Virtual CD mode) usb_modeswitch is probably switching your device automatically in the background when you plug it in. You need to extract the config file called 12d1:1f01 from the archive in /usr/share/usb_modeswitch/ to your desktop. Open the file and delete the "MessageContent" line with the long number then save it to /etc/usb_modeswitch.d/.
You might have permission issues when doing this. I used the Desktop as a middle ground for editing the file and the terminal using for copy commands to move the file into /etc/usb_modeswitch.d/. The copy command to copy the file from the desktop to /etc/usb_modeswtich.d/ is below.
Code:
cp /home/ubuntu/Desktop/12d1:1f01 /etc/usb_modeswitch.d/
After this has been done unplug your device and plug it back in. Make sure you're in 12d1:1f01 mode by running "lsusb" again.
7. Enter the command below to switch your modem out of its default mode into a mode that has a COM port.
Code:
usb_modeswitch -v 12d1 -p 1f01 -P 12d1 -V 1566 -M "55534243123456780000000000000011062000000000000200000000000000"
Note that in the command above "-v 12d1" is the current vendor ID and "-p 1f01" is your current product ID.
8. Run the lsusb command again. You will now notice that the vendor and product ID for your Huawei device has changed to 12d1:1566.
9. Run the below command to check which port your modem is on.
Make a note of the port. Mines was /dev/ttyUSB1. There could be multiple, note all of them.
10. Open another terminal window and switch to admin. Enter the below command.
Note that you should use the port that wvdial reported. If there are multiple you need to open multiple terminal windows using the respective ports. This window will act as an output and show the response of the modem once you query it.
11. Go back to your original terminal window and enter the below command.
Code:
echo "ATi^M" > /dev/ttyUSB1
Change the port portion of the command accordingly. "^M" is not how you would normally type it, it's obtained by holding Ctrl down and then pressing V and then M. This command instructs the device to provide information about itself. On your other terminal window you should see the modems reponse. It should give you its Brand, IMEI,etc. Now you know this is the correct device and you should use this port for communication.
12. The next command is below is to set the factory mode of your device.
Code:
echo "AT^SFM=1" > /dev/ttyUSB1
Your modem output window should report "OK".
13. Now enter the command that will enable all devices on the modem including the COM port in order to flash in Windows.
Code:
echo "AT^SETPORT="FF;1,2,3,A2"^M > /ttyUSB1
14. Pull the device and plug it into a Windows machine and flash your favourite firmware!
In my case it was the non Hi-Link firmware that I needed. Make sure Mobile Partner is installed as it contains all the drivers for the hardware detected.
Some of the steps above may be unecessary as I'm new to Linux and AT commands but they are exactly what I did in order to get my modem up and running again.
Hopefully this will assist someone else in the same situation. There's a lot of people to thank for the above information as its snippets from all over the web. Too many browser tabs and 3 days of researching to find this solution makes it difficult to name them all.