Its possible to access internet in Linux via GPRS even if you don’t have drivers for your Cellphone. Thats all the magic of Linux Kernel.
Method 1
- Connect the mobile via USB cable.
- Open terminal and type su to become root.
- It will ask for the root password, type in there.
- Then use the command
wvdialconf /etc/wvdial.conf
Your phone will be detected as Modem
- Then using a Text Editor open wvdial.conf using commands
kwrite /etc/wvdial.conf (for KDE)
gedit /etc/wvdial.conf (for GNOME)
When we issued command in point 4, it showed the address of your phone that in which USB port it has been connected. note it down from there.
“Modem = /dev/***” - When Text Editor opens the file, erase everything and paste the following code
[Dialer Defaults]
Modem = /dev/ttyUSB0 # <– Replace it with the reading you got
Phone = *99#
Username = aa
Password = bbc
Baud = 230400
Init1 = ATZ
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ISDN = 0
Modem Type = Analog Modem
Carrier Check = No - This will configure your mobile phone as a modem
To dial the internet connection, type
wvdial
If everything goes fine it would say that connected successfully.
Press Ctrl+C to disconnect.
Method 2
- Open Terminal and type the command
lsusb
Bus 001 Device 004: ID 0421:0445 Nokia Mobile Phones
- Then use command
/sbin/modprobe usbserial vendor=0x(vid) product=0x(pid)
Ex in my case for above output
/sbin/modprobe usbserial vendor=0×421 product=0×445
- Then using a Text Editor open wvdial.conf using commands
kwrite /etc/wvdial.conf (for KDE)
gedit /etc/wvdial.conf (for GNOME)
- Paste following contents in the file
[Dialer Defaults]
Init1 = ATZ
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
Modem Type = USB Modem
ISDN = 0
New PPPD = yes
Phone = *99#
Modem = /dev/ttyACM0
Username = b
Password = a
Baud = 460800 - This will configure your mobile phone as a modem
To dial the internet connection, type
wvdial
If everything goes fine it would say that connected successfully.
Press Ctrl+C to disconnect.
Filed under: Internet, Linux Tagged: | GPRS, Internet, Linux, Modem, wvdial
[...] — techvishal @ 7:24 am Tags: Internet, wvdial This is with reference to the post Internet via GPRS in Linux. But it can be used for any Internet connection that uses [...]
Thank you ya….
Sorry selva, I have never used Fedora 9. I tried to search net, for any package manager in Fedora.
I got a few links for you see if they help.
http://rpmfind.net/linux/rpm2html/search.php?query=compat-gcc-34-g77
http://rpmfind.net/linux/rpm2html/search.php?query=libg2c.so.0()(64bit)
http://atrpms.net/dist/f9/f2c/
Dear sir,
I wanna thank you for your kind reply. Now i have made the connection successfully.. And also thank you for your advice about showing mail id.. And now i want to download and install the Fortran 77 Compiler. how can i do that sir? Thank you..
Hello Selva, sorry for the late reply.
When you use ‘vi gedit’ a new file called ‘gedit’ is created in your current folder (mostly the home folder).
use ‘gedit /etc/wvdial.conf’ (for GNOME destop environment) or
try ‘kwrite /etc/wvdial.conf’ (for K Desktop environment)
both gedit and kwrite are text editors
else try ‘vi /etc/wvdial.conf’ (i dont use vi so sorry for your inconvenience)
what you did was, that you created two files using vi and not editing the file ‘wvdial.conf’
Also try using the Method-2 it works for many people.
Just paste this in file /etc/wvdial.conf
[Dialer Defaults]
Init1 = ATZ
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
Modem Type = USB Modem
ISDN = 0
New PPPD = yes
Phone = *99#
Modem = /dev/ttyACM0
Username = b
Password = a
Baud = 460800
One more request never give you email-id on any blog, it might be used by spammers. I have removed it.
For more help do comment, if you encounter any errors. If everything goes ok, you can also suggest me some topic you want to know.
Thank you,
Respected sir,
I had tried to connect my Nokia N72 on Fedora 9 via USB cable by using the Method 1. It shows some error( I am very new. so could u kindly explain in detail sir).. The following is the one which comes throught my execution:
[selva@localhost ~]$ su
Password:
[root@localhost selva]# wvdialconf /etc/wvdial.conf
Editing `/etc/wvdial.conf’.
Scanning your serial ports for a modem.
Modem Port Scan: S0 S1 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″
[root@localhost selva]# vi gedit /etc/wvdialconf
[Dialer Defaults]
Modem = /dev/ttyACM0 #
Phone = *99#
Username = aa
Password = bbc
Baud = 230400
Init1 = ATZ
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ISDN = 0
Modem Type = Analog Modem
Carrier Check = No
(After this i had used Esc and
to come out of the vi editor..But it showed as follows)
“gedit” 62L, 258C written
E173: 1 more file to edit
– More –
(Then i did the enter,then again did the
to come out.. Then it came as follows)
[root@localhost selva]# vi gedit /etc/wvdial.conf
2 files to edit
(Finally i did the following command)
[root@localhost selva]# wvdial
–> WvDial: Internet dialer version 1.60
–> Cannot get information for serial port.
–> Initializing modem.
–> Sending: ATZ
ATZ
OK
–> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
OK
–> Modem initialized.
–> Configuration does not specify a valid phone number.
–> Configuration does not specify a valid login name.
–> Configuration does not specify a valid password.
Respected sir,
I am using Fedora 9 and Nokia N72.. i am very new to Linux.. So i cant able to understand many things in this.. I want to connect to the internet by using these devices(Airtel Gprs, Usb connection).. Could u kidly help me sir? (I am very new.. so pls guide me from initial stage) Thank you..