Using a Huawei E620 3G card in linux
January 11th, 2007
I’ve been using an option GPRS card for a while (without any problems) so I was very eager to try the new HSDPA cards in my linux laptop. It works like a charm (I’m so happy :))
Well, now the facts, what you need to make the card work?
- A working PCMCIA port
- To have the card detected as 3 USB Serial ports
- PPP Drivers
- Wvdial installed and configured
I’ll assume you have the pcmcia subsystem up and working (else google is your friend).
Secondly, you need the usbserial module. If you don’t have it available, you’ll need a kernel recompilation, else just load it with modprobe usbserial. Once loaded, when you plug the card on the PCMCIA slot, you’ll see a bunch of messages in your syslog, look for these three:
[...]
Jan 11 19:47:50 acsev-109 pl2303 6-1:1.0: pl2303 converter detected
Jan 11 19:47:50 acsev-109 usb 6-1: pl2303 converter now attached to ttyUSB0
Jan 11 19:47:50 acsev-109 pl2303 6-1:1.1: usb_probe_interface
Jan 11 19:47:50 acsev-109 pl2303 6-1:1.1: usb_probe_interface - got id
Jan 11 19:47:50 acsev-109 pl2303 6-1:1.1: pl2303 converter detected
Jan 11 19:47:50 acsev-109 usb 6-1: pl2303 converter now attached to ttyUSB1
Jan 11 19:47:50 acsev-109 pl2303 6-1:1.2: usb_probe_interface
Jan 11 19:47:50 acsev-109 pl2303 6-1:1.2: usb_probe_interface - got id
Jan 11 19:47:50 acsev-109 pl2303 6-1:1.2: pl2303 converter detected
Jan 11 19:47:50 acsev-109 usb 6-1: pl2303 converter now attached to ttyUSB2
Jan 11 19:47:50 acsev-109 usbcore: registered new interface driver pl2303
Jan 11 19:47:50 acsev-109 drivers/usb/serial/pl2303.c: Prolific PL2303 USB to serial adaptor driver
Jan 11 19:47:50 acsev-109 drivers/usb/serial/usb-serial.c: USB Serial support registered for GSM modem (1-port)
Jan 11 19:47:50 acsev-109 usbcore: registered new interface driver option
Jan 11 19:47:50 acsev-109 drivers/usb/serial/option.c: USB Driver for GSM modems: v0.7.1
If you can’t see those three messages, it just won’t work (again, google is your friend)
Install PPP: modprobe ppp.
Install and configure wvdial. Install it your preferred way (apt-get it, install from source, use emerge or rpm or whatever), then edit the file /etc/wvdial.conf. These are the settings needed for Vodafone users in Spain. People from other countries should try Tazz Tux’ files on mybroadband.co.za forums.
[Dialer Defaults]
Phone = *99***1#
Username = username
Password = password
Stupid Mode = 1
Dial Command = ATDT
[Dialer pin]
Init1 = AT+CPIN=XXXX
# You should change the XXXX for your PIN code
[Dialer option]
Modem = /dev/ttyUSB0
Baud = 460800
Init2 = ATZ
Init3 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ISDN = 0
Modem Type = Analog Modem
[Dialer internet]
Init5 = AT+CGDCONT=1,”IP”,”ac.vodafone.es”;
Although there’s a PIN section in the code, I have never been able to use any of my cards with PIN code enabled so I’ll just disable it (I’ve put the SIM card in my phone and told it not to ask for PIN anymore). Then just exec wvdial: wvdial option internet. Enjoy!
Feedback is welcome











2007-01-24 at 8.48 pm
First of all, thanks for the info. Nevertheless let me say i have not been able to connect my pcmcia card. I have done what you’ve said and i got the following output:
wvdial option internet
–> WvDial: Internet dialer version 1.56
–> Cannot get information for serial port.
–> Initializing modem.
–> Sending: ATZ
ATZ
OK
–> Sending: ATZ
ATZ
OK
–> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ERROR
–> Bad init string.
–> Cannot get information for serial port.
–> Initializing modem.
–> Sending: ATZ
ATZ
OK
–> Sending: ATZ
ATZ
OK
–> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ERROR
–> Bad init string.
–> Cannot get information for serial port.
–> Initializing modem.
–> Sending: ATZ
ATZ
OK
–> Sending: ATZ
ATZ
OK
–> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ERROR
–> Bad init string.
eduard@edgy:~$
Do you have any idea to help me?
2007-01-24 at 10.56 pm
Did you remember to tell the SIM card not to ask for the PIN code?
2007-01-29 at 12.39 pm
Actually i typed the order “wvdial option internet”, which asks for no pin. Anyhow i also tried the order “wvdial pin option internet” with negative results too, but this time the message concerns the modem, which it says is not detected.
2007-01-29 at 8.40 pm
Is not in the code where you shouln’t ask for the PIN code, is the SIM card the one that has to be instructed not to ask code. The easiest way to do this inserting the SIM in your own mobile phone and (ussually under securitty settings) you’ll find a menu entry to change if you want your phone (actually is a parameter for the SIM card) to ask your PIN number at init. Set it at no and accept. Place the SIM in the PCMCIA card and try again.
2007-02-22 at 4.09 pm
super!!!! very very gut!!!!! Bravo!!
Fantastico
Tomek.K
to dla Polaków 
U mnie to dziala