How to use Huawei USB Modem E220?

Message
Author
Jan E
Posts: 19
Joined: Wed 04 Jan 2006, 20:57

How to use Huawei USB Modem E220?

#1 Post by Jan E »

Is there anyone that has been able to connect the Huawei USB modem to a puppy?
Attachments
usb_pic.JPG
picture of the modem
(9.29 KiB) Downloaded 8837 times

User avatar
Aitch
Posts: 6518
Joined: Wed 04 Apr 2007, 15:57
Location: Chatham, Kent, UK

#2 Post by Aitch »

Hi, Jan E

see the posts by wescht here;

http://www.murga-linux.com/puppy/viewtopic.php?t=12603

I believe this was puppy v3.01, but I can't say for puppy v4/dingo

try it!

Aitch :)

kjoe
Posts: 27
Joined: Wed 25 Jul 2007, 19:17
Location: Austria

#3 Post by kjoe »

Hi Jan E,

I am using puppy 4 and I've got the modem working based on a script.
For more information see

http://www.murga-linux.com/puppy/viewtopic.php?p=209496

Hope thats useful for you.

kjoe

whooa
Posts: 3
Joined: Tue 27 May 2008, 11:25

#4 Post by whooa »

Try DSL(DamnSmallLinux) instead, it works directly off the live cd. Puppy is not worth the effort, I struggled for several days getting it to recognize hua wei e220 correct.

At boot prompt DSL, give command dsl toram and DSL will run in your ram memory(lang={sk} will give you the correct keyboard as well). When booted, open terminal(Aterm) and command sudo moodprobe usbserial vendor=0x12d1 product=0x1003, set up a connection using program dialupPPP(choose chap) and you are connected. Otherwise, give xubuntu a try, it works after giving command sudo modprobe -r uhci_hcd and then sudo modprobe uhci_hcd. Use the wvdial you configured.

//Peter, sweden.

User avatar
ecube
Posts: 88
Joined: Fri 11 Jul 2008, 17:00
Location: Västerås, Sweden

Solved

#5 Post by ecube »

To my surprise I was able to connect my E220 modem by PupDial in Puppy 4.1, without any problems. No username or password were needed only phone-number (#99***1#).

Give it a try!
Ecube :o
Attachments
e220modem.jpg
(80.71 KiB) Downloaded 7069 times
Last edited by ecube on Fri 10 Oct 2008, 12:04, edited 1 time in total.

User avatar
Aitch
Posts: 6518
Joined: Wed 04 Apr 2007, 15:57
Location: Chatham, Kent, UK

#6 Post by Aitch »

Well done ecube

Would you like to let other people searching, know that you succeeded?
Just edit [blue icon top right] your original post to show 'Solved' in the subject line & your done

thanks & welcome to the kennels

who needs dsl when you have puppy? eh? :wink:

Aitch :)

kjoe
Posts: 27
Joined: Wed 25 Jul 2007, 19:17
Location: Austria

problem with modem detection by PupDial solved

#7 Post by kjoe »

Hi Ecube,

I gave it a try (using puppy 4.1.2) but did not succeed at this time. PupDial could not detect the modem. It seems that it is primarily recognized as an USB storage drive. For instance I get an optical drive icon after plugging in the modem.

But entering the following line into the console did fix the problem:

modprobe usbserial vendor=0x12d1 product=0x1003

PupDial now could detect the modem. I just entered the right phone number (*99# in my case) and here I am.

Thank you, Ecube, for reporting that PupDial was working for you. Using this is much easier than modifying the script I've mentioned some months ago (see above).

kjoe

(@whooa: maybe this brings you back to puppy ... ;-) )

plumtreed
Posts: 68
Joined: Sun 07 Dec 2008, 08:41
Location: Australia

#8 Post by plumtreed »

A great way to start the new year and I would like to thank Kjoe and other forum participants for the freely provided advice! Lets face it, without being able to connect to the net, an OS is of little value.

With the info given I was able to get on the net in the UK via the '3' 3G network. Just adding that line in a terminal made it happen. After that I just followed the prompts in the gprs GUI, using /dev/ttyUSB0; 3internet as the APN; 'three' as user & password, '1234' as pin.

I had to make the connection attempt 2 to 3 times but this can also happen with my usual, Ubuntu, OS. I was elated when it scored!

Thanks everybody!

(Using Puppy 4.1.2; E160G USB Modem; '3' UK mobile broadband)

User avatar
rerwin
Posts: 2017
Joined: Wed 24 Aug 2005, 22:50
Location: Maine, USA

#9 Post by rerwin »

kjoe, et al,
But entering the following line into the console did fix the problem:

modprobe usbserial vendor=0x12d1 product=0x1003
If this is the only remaining obstacle to fully automated detection of this device, maybe I can contribute. I have just learned about the udev rules that puppy now uses to set up drivers for the devices -- and am now really dangerous!

Although I cannot test it, could you try adding a new rule file to issue the special modprobe command for the device? Just create a new file in /etc/udev/rules.d and call it:
30-udev-usb-serial-modem.rules

Code: Select all

#Huawei USB Modem E220
#SYSFS{vendor}=="0x12d1", SYSFS{device}=="0x1003" RUN+="modprobe -r usbserial"
SYSFS{vendor}=="0x12d1", SYSFS{device}=="0x1003" RUN+="modprobe usbserial vendor=0x12d1 product=0x1003"
(Do not break up the three lines.)
If it does not work as expected, try uncommenting the "#SYSFS" line and rebooting. This all assumes the device is plugged in at bootup. I have not experimented with hotplug detection, but suspect that prepending whatever SYSFS lines you end up using, with:
ACTION=="add",

might handle plugging in while running. Thanks for any help you provide.
Richard

User avatar
scotto_puppy
Posts: 39
Joined: Thu 22 Mar 2007, 21:56
Location: Elvina Bay, NSW,Australia

#10 Post by scotto_puppy »

I have been reading with great interest all of the entries in this section of the forum. I am using puppy 4.1.2, have a huawei 220 wireless modem and have tried to follow all the steps outlined.
What I have done: I thought I had blacklisted my internal modem and after rebooting the BootManager shows it is blacklisted. I have run the command modprobe usbserial vendor=0x12d1 product=0x1003 in a terminal window.
When I go into PupDial and re-probe the modem I get the only device selected as /dev/ttySL0 rather than my usb modem.
I am sure it is my ignorance that is causing this to be a problem and I hope you might be able to put me straight!

plumtreed
Posts: 68
Joined: Sun 07 Dec 2008, 08:41
Location: Australia

#11 Post by plumtreed »

Scotto, I type in /dev/ttyUSB0 only because it was declared the 'device' by other operating systems, Ubuntu, Knoppix, and successfully!

Try it, :?

User avatar
scotto_puppy
Posts: 39
Joined: Thu 22 Mar 2007, 21:56
Location: Elvina Bay, NSW,Australia

#12 Post by scotto_puppy »

plumtreed wrote:Scotto, I type in /dev/ttyUSB0 only because it was declared the 'device' by other operating systems, Ubuntu, Knoppix, and successfully!

Try it, :?
Sounds good! But where do you type it?

muggins
Posts: 6724
Joined: Fri 20 Jan 2006, 10:44
Location: hobart

#13 Post by muggins »

scotto_puppy,

after running modprobe usbserial vendor=0x12d1 product=0x1003, have you tried running pupdial & then running Probe to rescan for modems?

User avatar
scotto_puppy
Posts: 39
Joined: Thu 22 Mar 2007, 21:56
Location: Elvina Bay, NSW,Australia

#14 Post by scotto_puppy »

muggins wrote:scotto_puppy,

after running modprobe usbserial vendor=0x12d1 product=0x1003, have you tried running pupdial & then running Probe to rescan for modems?
Hi Muggins

You were absolutely correct! I am so impressed that puppy can now use my wireless modem. Fantastic resurrection of a ten year old laptop.
BUT: One small hiccup. I seem to have to run the modprobe command on each reboot. Is there a way to avoid this?

tempestuous
Posts: 5464
Joined: Fri 10 Jun 2005, 05:12
Location: Australia

#15 Post by tempestuous »

rerwin, before you delve too deeply into pupevent, let me add something to the mix;
under recent kernels there is a module called "option" which works as a "helper" module with usbserial.
From what I've read, the option module is compatible with with most usb modems. Indeed, if you run "modinfo option" you will see that the option module is compatible with the Huawei e220: vendor/product 12d1 1003 is listed.
And since the option module specifies vendor/product ID's, it's no longer necessary to load the usbserial module with forced device recognition.

EDIT:
The Huawei E220 wireless modem is known by several different USB device id's.
12d1:1003 is recognised by the "option" module, but with other USB device ID's it may be necessary to use the old-fashioned method of loading the "usbserial" module with the correct USB ID's specified, as explained by forum member wescht here -
http://www.murga-linux.com/puppy/viewto ... 973#102973
Last edited by tempestuous on Sun 15 Mar 2009, 04:19, edited 1 time in total.

User avatar
rerwin
Posts: 2017
Joined: Wed 24 Aug 2005, 22:50
Location: Maine, USA

#16 Post by rerwin »

tempestuous,
Thanks for telling me about option.ko. Saves a lot of unnecessary work. Should it now be handling the "modprobe usbserial" issue? If so, why are there complaints?

Is it because they are using the retro isos, which do not have that update (only in 2.6.23+)? It seems that anyone reporting a problem should upgrade to the standard kernel version of puppy 4.1+. Only if that still does not help, should we investigate udev rules.

If there is still a problem, the user might enter "lsmod | grep '^option'" to verify option.ko is loaded. Maybe that is a problem.

Maybe there are devices out there that option.ko doesn't handle (such as non-GSM devices), that need a rule. What do you make of it all? I feel like an amateur at this udev and exotic modem stuff, so can benefit from anything you know about them.
Richard

tempestuous
Posts: 5464
Joined: Fri 10 Jun 2005, 05:12
Location: Australia

#17 Post by tempestuous »

rerwin wrote:Should it now be handling the "modprobe usbserial" issue?
Yes.
rerwin wrote:If so, why are there complaints?
Because 99% of USB modem HOWTO's on the web refer to the old method of "modprobe usbserial vendor=xxxx product=yyyy".

I'm no expert on USB/wireless modems, but I summarised the current driver situation here -
http://www.murga-linux.com/puppy/viewto ... 448#254448
Note that the very latest wireless modems require a new driver called "hso", and this driver requires some udev "magic" to activate the ozerocdoff utility. I included all of the necessary files (including udev rule) in the hso dotpet, but no one has confirmed if it works - even though it's been downloaded 30 times.

User avatar
rerwin
Posts: 2017
Joined: Wed 24 Aug 2005, 22:50
Location: Maine, USA

#18 Post by rerwin »

tempestuous,
Thanks for setting me straight about all this. It is much more complicated than I imagined. I think I should just bow out of the discussion, since my knowledge areas are not needed. I do not have any of the devices to test, so cannot contribute. You are definitely "on top" of this. (I am focusing on udev rules to restore detection of the odd-ball PCI modems that got left behind in 4.1, as well as rules to detect O2 Micro CardBus controllers that have frustrated users of laptops containing them.)
Richard

muggins
Posts: 6724
Joined: Fri 20 Jan 2006, 10:44
Location: hobart

#19 Post by muggins »

I seem to have to run the modprobe command on each reboot. Is there a way to avoid this?
Just add the command to /etc/rc.d/rc.local, and it will be run whenever you reboot.

User avatar
rerwin
Posts: 2017
Joined: Wed 24 Aug 2005, 22:50
Location: Maine, USA

#20 Post by rerwin »

muggins, scotto_puppy.
Your solution appears to conflict with tempestuous' advice above, that the "option" driver in the standars 4.1+ Puppy should make unnecessary the specific loading of usbserial. I want to provide a solution for all puppy users such that they need not load any modules for the Huawei modem -- or any others. Could you, scotto_puppy, help us resolve this issue?

Starting with a fresh, standard-kernel Puppy, to avoid any aftereffects of your experimentation, blacklist "slamr" (or whichever Smartlink driver that gets loaded automatically, as you have already done). Then go into pupdial and, if it shows ttySL0 as the modem, click on "probe" and then "erase", to clear that out. Reboot with that in effect and determine whether
(1) the modem is detected in the "connect" dialog and
(2) the "option" module is actually loaded (lsmod).

If both are true, you need do nothing more. If neither, try "modprobe option"; if it has no immediate effect, try unplugging and replugging the (usb) modem. If that still is ineffective, put that command in rc.local and reboot. If tempestuous has it correctly, that should cause the modem be detected.

Please post how things go. Thanks.
Richard

Post Reply