Now after my pc is up and running once again(and yes, I formatted it again!), I did some configurations so that I am able to connect it to the internet using my cell phone. I have Nokia N72 and connecting internet on Windows was not an issue. Just installed the Nokia PC Suite rest it did by itself. I just had to select my service provider which was Warid Telecom.
Now comes Linux’s turn. The procedure was similar to installing a CDMA phone to connect internet but this time I was able to get hold of an easier way below.
Plugged in my phone into my computer using the USB cable and disconnected the established gprs connection on my phone. Went to the Terminal and wrote a command which almost did everything by itself.
Below is the command and the output I got with it.
======================================================
rao@rao-desktop:~$ sudo wvdialconf /etc/wvdial.conf
[sudo] password for rao:
Editing `/etc/wvdial.conf’.
Scanning your serial ports for a modem.
ttyS0: ATQ0 V1 E1 — failed with 2400 baud, next try: 9600 baud
ttyS0: ATQ0 V1 E1 — failed with 9600 baud, next try: 115200 baud
ttyS0: ATQ0 V1 E1 — and failed too at 115200, giving up.
ttyS1: ATQ0 V1 E1 — failed with 2400 baud, next try: 9600 baud
ttyS1: ATQ0 V1 E1 — failed with 9600 baud, next try: 115200 baud
ttyS1: ATQ0 V1 E1 — and failed too at 115200, giving up.
Modem Port Scan: S2 S3
WvModem: Cannot get information for serial port.
ttyACM0: ATQ0 V1 E1 — OK
ttyACM0: ATQ0 V1 E1 Z — OK
ttyACM0: ATQ0 V1 E1 S0=0 — OK
ttyACM0: ATQ0 V1 E1 S0=0 &C1 — OK
ttyACM0: ATQ0 V1 E1 S0=0 &C1 &D2 — OK
ttyACM0: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 — OK
ttyACM0: Modem Identifier: ATI — Nokia
ttyACM0: Speed 4800: AT — OK
ttyACM0: Speed 9600: AT — OK
ttyACM0: Speed 19200: AT — OK
ttyACM0: Speed 38400: AT — OK
ttyACM0: Speed 57600: AT — OK
ttyACM0: Speed 115200: AT — OK
ttyACM0: Speed 230400: AT — OK
ttyACM0: Speed 460800: AT — OK
ttyACM0: Max speed is 460800; that should be safe.
ttyACM0: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 — OK
Found an USB modem on /dev/ttyACM0.
Modem configuration written to /etc/wvdial.conf.
ttyACM0: Speed 460800; init “ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0”
======================================================
After this I needed to edit the wvdial which I did like this
rao@rao-desktop:~$ sudo gedit /etc/wvdial
[Dialer Defaults]
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
Modem Type = USB Modem
;Phone =
ISDN = 0
;Username =
Init1 = ATZ
;Password =
Modem = /dev/ttyACM0
Baud = 460800
Stupid Mode = 1
I then edited the commented lines by entering the phone no (*99#) and removing the semi-colon and comments. I left the username and password fields blank as there is none required to connect to internet through Warid.
Entered sudo wvdial to dial to the connection which was just configured and gave the below output.
======================================================
rao@rao-desktop:~$ sudo wvdial
[sudo] password for rao:
WvDial: WvDial: Internet dialer version 1.56
WvModem: Cannot get information for serial port.
WvDial: Initializing modem.
WvDial: Sending: ATZ
WvDial Modem: ATZ
WvDial Modem: OK
WvDial: Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
WvDial Modem: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
WvDial Modem: OK
WvDial: Modem initialized.
WvDial: Configuration does not specify a valid login name.
WvDial: Configuration does not specify a valid password.
======================================================
Last two lines show that a username and password is required for wvdial to work. I entered dummy username and password and again tried to connect.
======================================================
WvDial: WvDial: Internet dialer version 1.56
WvModem: Cannot get information for serial port.
WvDial: Initializing modem.
WvDial: Sending: ATZ
WvDial Modem: ATZ
WvDial Modem: OK
WvDial: Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
WvDial Modem: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
WvDial Modem: OK
WvDial: Modem initialized.
WvDial: Sending: ATDT*99#
WvDial: Waiting for carrier.
WvDial Modem: ATDT*99#
WvDial Modem: CONNECT
WvDial Modem: ~[7f]}#@!}!} } }2}#}$@#}!}$}%\}”}&} }*} } g}%~
WvDial: Carrier detected. Starting PPP immediately.
WvDial: Starting pppd at Mon Jan 28 12:29:48 2008
WvDial: Pid of pppd: 5625
WvDial: Using interface ppp0
WvDial: pppd: (�[06][08]H�[06][08]
WvDial: pppd: (�[06][08]H�[06][08]
WvDial: pppd: (�[06][08]H�[06][08]
WvDial: pppd: (�[06][08]H�[06][08]
WvDial: local IP address 10.20.71.30
WvDial: pppd: (�[06][08]H�[06][08]
WvDial: remote IP address 10.6.6.6
WvDial: pppd: (�[06][08]H�[06][08]
WvDial: primary DNS address 10.2.3.4
WvDial: pppd: (�[06][08]H�[06][08]
WvDial: secondary DNS address 10.2.3.5
WvDial: pppd: (�[06][08]H�[06][08]
======================================================
To see if the connection has been established or not try pinging any ip. I did the following
rao@rao-desktop:~$ ping http://www.ssuet.edu.pk
PING sirsyed.ssuet.edu.pk (221.120.196.129) 56(84) bytes of data.
64 bytes from khi77.pie.net.pk (221.120.196.129): icmp_seq=1 ttl=33 time=658 ms
Ping reply was there… so yay! I’m connected.
To disconnect I will use Ctrl +C. Will I said because i still haven’t disconnected after I first logged in. 😀