October 3, 2009

Reliance Netconnect on Ubuntu

Note: These are specific instructions for using ZTE-AC2726 modem on Ubuntu Jaunty.
If you are using a different modem, instructions may vary.

I got one of the newer modems with my wireless broadband connection from Reliance. It is a model that I had not come across in other blog posts, but I was encouraged by seeing 'Linux OS' mentioned among the system requirements.

Step 1: Open box and first look
The linux support is in the form of a driver on the cd that comes in the package. There is a deb package, but an attempt to install it fails because it seems to support kernels upto 2.6.27 only. The modem looks nice though!

Step 2: Plug in modem
On plugging in the modem, it gets mounted and shows up in nautilus like any storage drive. 'lsusb' confirms the bad news - the device is listed as 'Bus 007 Device 006: ID 19d2:fff5'. The modem is being recognised as a storage device only.

PS: In Ubuntu 9.10 (Karmic), the device is recognized as a modem directly and the steps 3 and 4 are not required.

Step 3: usb_modeswitch to the rescue
usb_modeswitch is an application written specifically for this purpose.



wget http://www.draisberghof.de/usb_modeswitch/usb_modeswitch-1.0.5.tar.bz2
tar -xjvf usb_modeswitch-1.0.5.tar.bz2
cd usb_modeswitch-1.0.5
sudo make install


If there were no errors, you can add this snippet to /etc/usb_modeswitch.conf. I have broken MessageContent into 2 lines so that it can be shown in entirety. You should put everything on one line.



# ZTE AC2726
#
DefaultVendor= 0x19d2
DefaultProduct= 0xfff5

TargetVendor= 0x19d2
TargetProduct= 0xfff1

MessageContent="5553424312345678c00000008000069f03
0000000000000000000000000000"


Now run


sudo usb_modeswitch


You should see the success message and lsusb should show the product id is now fff1.

Step 4: Load the usbserial module


sudo mobdprobe usbserial vendor=0x19d2 product=0xfff1


Step 5: Connect using wvdial
If all has gone well, the modem should be recognised and ready to use.
'ls /dev/ttyUSB*' should show some USB devices


sudo apt-get install wvdial


You can run 'wvdialconf' to generate the initial configuration file and then edit it to enter your phone number and password.
This is my wvdial.conf


[Dialer Defaults]
Init1 = ATZ
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
Modem Type = Analog Modem
Baud = 460800
New PPPD = yes
Modem = /dev/ttyUSB0
ISDN = 0
Phone = #777
Password = XXXXXXXXXX
Username = XXXXXXXXXX
PPPP Path = /usr/sbin/pppd
New PPPD = 1
Stupid Mode = 1
Tonline = 0


Now you are all set to


sudo wvdial


and get connected.

Notes:
1. I did the initial activation of the device from a windows pc. Not sure if it can be done with wvdial by using the phone number for that purpose.
2. Loading of the specific usbserial module can be automated by adding it to the kernel line in the boot menu. udev rules can be used for running usb_modeswitch on plugging in the modem - these are not covered here.

6 comments:

Anonymous said...

Thanks a lot.. I was having tough time, now its working :)

- Karthik

Anonymous said...

Thanks a bunch, It works now.

One small correction

'mobdprobe' should be read as modprobe

Rgds,
Siva.

Anonymous said...

Thanks a lot that works like a charm.

A small correction.
'mobdprobe' should be read as 'modprobe'

Rgds,
Siva.

Anonymous said...

Wonderful, too good, and the best part is that the instructions work for 64 bit system also. Reliance's native drivers are only 32bits.

Anonymous said...

Hi,

I am able to go upto the "sudo make install" without any errors. But on the next step "sudo usb_modeswitch", I get the error

Error: Could not find file /etc/usb_modeswitch.setup

Can you please tell me what to do for this? I am a linux newbie. Thanks...

Regards,
Arjun

Anonymous said...

Thanks a million, was struggling to get this on 10.04, your help got me started.
Thanks again,
rgds,
gautm.