Its been more than a month since i started to configure my Huawei modem for internet connectivity in Linux. Finally today i am logged in F10 and editing this post.
1. Firstly one has to check if the modem is being detected on the USB port.
dmesg | grep USB should show entries for 2 or 3 USB ports. (ttyUSB0-ttyUSB2). My system shows 2 entries. Look the messages of following type:
/***************************************************************************/
usb 4-3: GSM modem (1-port) converter now attached to ttyUSB1
scsi18 : SCSI emulation for USB Mass Storage devices
usb 4-3: New USB device found, idVendor=12d1, idProduct=1003
usb 4-3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
usb 4-3: Product: HUAWEI Mobile
usb 4-3: Manufacturer: HUAWEI Technologies
usb-storage: device found at 6
/****************************************************************************/
The kernel should be able to identify the modem as a usb-storage device.
If you have problems with this , workarounds for the problem from internet.
2. Enable FTDI module.
Issue the command :/sbin/modprobe ftdi_sio
Now unplug/plug the modem.
check with dmesg |grep "ftdi"
Later on we are going to put this command in some script to be executed at startup.
3. Download wvdial and wvstreams.
http://en.wikipedia.org/wiki/Wvdial
http://alumnit.ca/wiki/index.php?page=WvDial
A few dependencies were required by wvstreams, so i had to install them
also by transporting them from pen drive.
Install wvstream (.configure,make, make install).
Install wvdial (make, make install).
4. The following files and directories are created
/etc/wvdial.conf
/etc/ppp/peers/wvdial
5. Configure wvdial. This will populate the file /etc/wvdial.conf.
You can either directly edit the file or download genome PPP (GUI based interface.)
Using Genome PPP is helpful if you are not able to establish a connection. (Help on using GPP for wvdial :-http://www.nerdgirl.dk/linux/fc8/huawei_e220.php).
-->wvdial conf /etc/wvdial.conf
Now open the file and see. A few entries for the modem can be seen.
After numerous amount of trials i added the following entries to wvdial
/********************wvdial.conf*********************************************/
[Dialer pin]
Modem=/dev/ttyUSB0
Baud=460800
Init1=AT+CPIN=**** (enter your pin number here)
[Dialer Tele2]
Modem=/dev/ttyUSB0
Baud=460800
Init2=AT+CGDCONT=1,"IP","isp.nawras.com.om"
Phone=*99#
Username =one
Password =One
New PPPD=yes
Auto DNS=1
#The settings for your ISP (like baud rate / phone number ) can be seen from windows modem settings.
/*********************************************************************************/
To understand the commands in this file:
http://www.gsm-modem.de/gsm-modem-faq.html
6. Edit /etc/resolv.conf to add domain and IP address for primary and secondary domain of your ISP. The IP address can be resolved by ipconfig in windows cmd line
/********************************resolv.conf*****************************/
domain om16.omantel.net.om
nameserver 212.72.1.186
nameserver 212.72.23.4
/*************************************************************************/
7. Issue the command wvdial pin from CLI (you can give any name in wvdial.conf)
The standard output messages are:
/***************************************************************************/
WvDial: Internet dialer version 1.60
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: AT+CPIN=****
AT+CPIN=****
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.
/*****************************************************************************/
8. Next issue the command wvdial Tele2. The standard output messages are:
/******************************************************************************/
WvDial: Internet dialer version 1.60
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: AT+CGDCONT=1,"IP","isp.nawras.com.om"
AT+CGDCONT=1,"IP","isp.nawras.com.om"
OK
--> Modem initialized.
--> Sending: ATDT*99#
--> Waiting for carrier.
ATDT*99#
CONNECT
--> Carrier detected. Waiting for prompt.
--> Don't know what to do! Starting pppd and hoping for the best.
--> Starting pppd at Tue Jul 28 18:33:42 2009
--> Pid of pppd: *****
--> Using interface ppp0
--> local IP address *.*.*.*
--> remote IP address 10.64.64.64
--> primary DNS address 212.72.1.186
--> secondary DNS address 212.72.23.4
/***********************************************************************************/
If the command wvdial pin is not issued before wvdial Tele2 then the following messages are issued
/**********************************************************************************/
--> WvDial: Internet dialer version 1.60
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: AT+CGDCONT=1,"IP","isp.nawras.com.om"
AT+CGDCONT=1,"IP","isp.nawras.com.om"
+CME ERROR: SIM PIN required
--> Bad init string.
/**********************************************************************************/
8. Finally, i was able to use yum, wget and elinks to install, save and browse, but i was not being able to open firefox. A lot of head banging and finally discovered that by default firefox is in offline mode and it has to be disabled by unchecking File->Work offline in firefox browser page.
1. Firstly one has to check if the modem is being detected on the USB port.
dmesg | grep USB should show entries for 2 or 3 USB ports. (ttyUSB0-ttyUSB2). My system shows 2 entries. Look the messages of following type:
/***************************************************************************/
usb 4-3: GSM modem (1-port) converter now attached to ttyUSB1
scsi18 : SCSI emulation for USB Mass Storage devices
usb 4-3: New USB device found, idVendor=12d1, idProduct=1003
usb 4-3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
usb 4-3: Product: HUAWEI Mobile
usb 4-3: Manufacturer: HUAWEI Technologies
usb-storage: device found at 6
/****************************************************************************/
The kernel should be able to identify the modem as a usb-storage device.
If you have problems with this , workarounds for the problem from internet.
2. Enable FTDI module.
Issue the command :/sbin/modprobe ftdi_sio
Now unplug/plug the modem.
check with dmesg |grep "ftdi"
Later on we are going to put this command in some script to be executed at startup.
3. Download wvdial and wvstreams.
http://en.wikipedia.org/wiki/Wvdial
http://alumnit.ca/wiki/index.php?page=WvDial
A few dependencies were required by wvstreams, so i had to install them
also by transporting them from pen drive.
Install wvstream (.configure,make, make install).
Install wvdial (make, make install).
4. The following files and directories are created
/etc/wvdial.conf
/etc/ppp/peers/wvdial
5. Configure wvdial. This will populate the file /etc/wvdial.conf.
You can either directly edit the file or download genome PPP (GUI based interface.)
Using Genome PPP is helpful if you are not able to establish a connection. (Help on using GPP for wvdial :-http://www.nerdgirl.dk/linux/fc8/huawei_e220.php).
-->wvdial conf /etc/wvdial.conf
Now open the file and see. A few entries for the modem can be seen.
After numerous amount of trials i added the following entries to wvdial
/********************wvdial.conf*********************************************/
[Dialer pin]
Modem=/dev/ttyUSB0
Baud=460800
Init1=AT+CPIN=**** (enter your pin number here)
[Dialer Tele2]
Modem=/dev/ttyUSB0
Baud=460800
Init2=AT+CGDCONT=1,"IP","isp.nawras.com.om"
Phone=*99#
Username =one
Password =One
New PPPD=yes
Auto DNS=1
#The settings for your ISP (like baud rate / phone number ) can be seen from windows modem settings.
/*********************************************************************************/
To understand the commands in this file:
http://www.gsm-modem.de/gsm-modem-faq.html
6. Edit /etc/resolv.conf to add domain and IP address for primary and secondary domain of your ISP. The IP address can be resolved by ipconfig in windows cmd line
/********************************resolv.conf*****************************/
domain om16.omantel.net.om
nameserver 212.72.1.186
nameserver 212.72.23.4
/*************************************************************************/
7. Issue the command wvdial pin from CLI (you can give any name in wvdial.conf)
The standard output messages are:
/***************************************************************************/
WvDial: Internet dialer version 1.60
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: AT+CPIN=****
AT+CPIN=****
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.
/*****************************************************************************/
8. Next issue the command wvdial Tele2. The standard output messages are:
/******************************************************************************/
WvDial: Internet dialer version 1.60
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: AT+CGDCONT=1,"IP","isp.nawras.com.om"
AT+CGDCONT=1,"IP","isp.nawras.com.om"
OK
--> Modem initialized.
--> Sending: ATDT*99#
--> Waiting for carrier.
ATDT*99#
CONNECT
--> Carrier detected. Waiting for prompt.
--> Don't know what to do! Starting pppd and hoping for the best.
--> Starting pppd at Tue Jul 28 18:33:42 2009
--> Pid of pppd: *****
--> Using interface ppp0
--> local IP address *.*.*.*
--> remote IP address 10.64.64.64
--> primary DNS address 212.72.1.186
--> secondary DNS address 212.72.23.4
/***********************************************************************************/
If the command wvdial pin is not issued before wvdial Tele2 then the following messages are issued
/**********************************************************************************/
--> WvDial: Internet dialer version 1.60
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: AT+CGDCONT=1,"IP","isp.nawras.com.om"
AT+CGDCONT=1,"IP","isp.nawras.com.om"
+CME ERROR: SIM PIN required
--> Bad init string.
/**********************************************************************************/
8. Finally, i was able to use yum, wget and elinks to install, save and browse, but i was not being able to open firefox. A lot of head banging and finally discovered that by default firefox is in offline mode and it has to be disabled by unchecking File->Work offline in firefox browser page.
Comments
Post a Comment