Wednesday, May 28, 2008

Linux: Using your 3G/CDMA plug-and-play usb modems for mobile broadband

So you recently purchased a USB 3G/CDMA modem for that wireless, anytime anywhere mobile broadband.
Let's see how to use it on Linux.
Most of the linux distros will autodetect the modem. These steps were performed on Ubuntu Gutsy but should work on all flavors.

1. Fire you terminal and run wvdialconf. This should detect your modem and auto generate a config file.
$ sudo wvdialconf /etc/wvdial.conf

2. Open the config file and edit it
$ sudo gedit /etc/wvdial.conf

3. This is how it looks on my system. Add the phone no, username and password as provided by your isp.
[Dialer Defaults]
Init1 = ATZ
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
Modem Type = USB Modem
Baud = 460800
New PPPD = yes
Modem = /dev/ttyACM0
ISDN = 0
Phone = <>
Password = <>
Username = <>
stupid mode = 1

You might also want to add stupid mode as it disables any prompts from the terminal server and starts pppd immediately after the modem connects.

4. Save the file. Now dial the modem and get connected.
$ wvdial

Great! You are good to go. Easy right! Enjoy surfing.

No comments: