Integration of 3G Wireless Modem Detection - 4.1.2 & 4.2.1

A home for all kinds of Puppy related projects
Post Reply
Message
Author
User avatar
rerwin
Posts: 2017
Joined: Wed 24 Aug 2005, 22:50
Location: Maine, USA

#121 Post by rerwin »

mill0001,
Thanks for your report. I would hope that all that effort would have been unnecessary if you had started out by downloading and installing tempestuous' newer sierra driver. Could you try it without any other changes to see whether the modem is detected automatically? That is my goal. You need the dotpets: 3G...-10, usb_modeswitch-0.9.7 (or maybe not at all, but it won't hurt), and tempestuous' sierra.

In what way was the sierra version of wvdial.conf different from what "3G-puppy" uses?

Let me explain the deal with usbserial. The sierra driver and all the other drivers that use ttyUSB0 are actually "front ends" to usbserial. My guess is that they handle the vendor and product IDs and probably invoke usbserial with the appropriate set. I suspect that, since you could not remove (modprobe -r) usbserial, your modprobe with the arguments had no effect, because usbserial was already loaded for sierra.

Getting back to usb_modeswitch: that entails some "udev rules" to control the switching of the device from a usb-storage impersonation to its modem state. There are rules for two sierra modems, but they do not include yours (1199:0025). Not a problem -- just make one! In the file:
/etc/udev/rules.d/51-usb_modeswitch-sierra-0x1199-0x0fff.rules
just modify one of the rules. Copy and change

Code: Select all

#ACTION=="add", SUBSYSTEM=="usb", ATTRS{idProduct}=="0fff", ATTRS{idVendor}=="1199", RUN+="/usr/sbin/usb_modeswitch.sh -v 0x%s{idVendor} -p 0x%s{idProduct} -V 0x1199 -P 0x0023 -S 1"
to:

Code: Select all

ACTION=="add", SUBSYSTEM=="usb", ATTRS{idProduct}=="0fff", ATTRS{idVendor}=="1199", RUN+="/usr/sbin/usb_modeswitch.sh -v 0x%s{idVendor} -p 0x%s{idProduct} -V 0x1199 -P 0x0025 -S 1"
removing the initial "#" and changing the end from "23 -S 1" to "25 -S 1" -- if you are certain that product-0x0025 is correct (since your use of it was probably ignored). If things still don't work, I would suspect that you need a different value for the "-P" argument. If you use the modem with Windows. look into the device manager driver details to see what the product/device ID is for the modem. The usb-storage part of the device is probably 1199:0fff.

Please try again with my setup, in case that reveals something more for me to address. Thanks.
Richard

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

#122 Post by rerwin »

kayan,
Thank you for posting to this thread and explaining more about your situation. I have looked into a different area of the modem-detection process as a result. However, I cannot find where you mentioned exactly which modem you have, and its vendor and product IDS. That would be helpful.

I have installed slax-pup and see that it uses a newer kernel than the standard puppy 4.1.2. The later kernels handle much of the mode switching, so might account for not needing the mode switcher. But, as you say, maybe yours is not one of the hybrid storage-modem devices I have been focused on. The fact that slax-pup allows you to use the modem means that my 3G-pupdial project may avoid the need for you to edit the wvdial.conf file.

It would be most helpful if you could try the 3G-pupdial...-10 dotpet with slax-pup in a fresh pupsave (pfix=ram) environment, without editing anything, and with the modem unplugged. The part of the detection I need information about is the selection of the modem, especially because you have the serial modem to complicate things. My intent is to sort that all out. There are several possibilities you might see while booting this setup.

1. I expect the first bootup to show "no modem detected". If ttyS0 is shown, please use the connect wizard and analog modem option to get to pupdial, then "probe" and "ERASE", to get "no modem detected".

2. Install the 3G-pupdial dotpet, after downloading it from this thread (first post). I have just now updated it with some delay logic for "option" modems; but if yours is different the logic is unimportant.

3. Plug in the modem, wait a couple of minutes, then look for a file: /etc/init.d/Option ( or some other file there with a name beginning with a capital letter). Let me know whether one is there.

4. Reboot, making a new pupsave file in the process. Ideally, the connect wizard should show detection of a ttyUSB0 device. Verify again whether there is a capitalized file name in /etc/rc.d.

5. Look in /tmp/udevtrace-modem.log for a line about the "option script" and how long it waited for mode switching.

6. If the modem is still not detected, try rebooting one more time, after erasing the ttyS0 selection in pupdial if it appears.

I am curious to see how far you get with this. I want to get right the choosing of the modem -- the USB modem in preference to the serial modem. Please do not do a probe>PROBE, because I suspect that will choose the serial modem.

Thanks for any help you can provide.
Richard

User avatar
zgp152
Posts: 114
Joined: Thu 08 Nov 2007, 19:37

Nooby deadlock

#123 Post by zgp152 »

rerwin wrote: zgp152,
Yes, I am automating the PupDial wireless dialup process, and think I have it done, other than handling individual problems with it. The downloads are in the first posting in this thread and should work with 4.2 when it comes out, as well as 4.1.x-standard. It is too late for me to request its inclusion in 4.2, and the package awaits further input from users, to this thread, to determine whether it works generally. Please try out the "-6" version of the dotpet and the driver dotpets, and tell us how it goes. I think someone reported that the E220 does work.
Richard
Yes, I have progressed to some degree with E220 and pet v 10, but I am not successful yet. The latest hiccup is that I selected in wizard the choice that "starts GPRS dialup next time you click Connect", while the setup was not yet functional. How to undo this selection? The response I get is "Connect script failed / Exit status is 0 / DISCONNECTED / Press ENTER to quit / Press r ENTER to reconnect/try again".

One thing I would like to know in advance, is there any 3G network strength monitoring SW to indicate how good the coverage is? I may be a bit at the edge of the coverage.

Rgds zgp152

User avatar
dejan555
Posts: 2798
Joined: Sun 30 Nov 2008, 11:57
Location: Montenegro
Contact:

#124 Post by dejan555 »

zgp152 right click on connect icon will give you option to execute connection wizard?
puppy.b0x.me stuff mirrored [url=https://drive.google.com/open?id=0B_Mb589v0iCXNnhSZWRwd3R2UWs]HERE[/url] or [url=http://archive.org/details/Puppy_Linux_puppy.b0x.me_mirror]HERE[/url]

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

#125 Post by rerwin »

zgp152,
Regarding signal strength: I stumbled upon an AT command that apparently reports signal strength. I cannot test it myself, but try this:

Edit /etc/wvdial.conf to insert (near the end):
# Current network signal strength
Init6 = AT+CSQ

The result should show as part of the dialup dialog.
Richard

kadil
Posts: 4
Joined: Mon 18 May 2009, 03:13

MF626 and puppeee 4.2 on eeepc 701

#126 Post by kadil »

Hi guys,

I am new to puppy, so please be gentle.

I have the MF626 (Telstra Prepaid usb dongle style) and a fresh install of pupeee 4.2. This system is so fast it is fantastic.

I installed the usb_modeswitch and 3G_pupdial-wireless-10.pet from the first page of this thread.

I uncommented the MF626 section on the conf file in /etc, then run usb_modeswitch, and the response is (among other bits and pieces):

error libusb speedup error handling needs improvement.

I have read this thread, but I am missing something. Can someone please help?

Thanks,
Kim

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

#127 Post by rerwin »

kadil,
Thanks for posting. I posted a reply here, as I am trying to get to bed, but addressed the wrong issue, so retracted it.

If usb_modeswitch is complaining about libusb, that component may have been left out of pupeee. I dare not mess with pupeee, so refer you to its developer about getting libusb.

Be warned, though, that others have had difficulty getting the MF626 working in puppy. They get an "error -110" from usb_modeswitch, and I have no solution for that.

Most have been testing with the standard puppy 4.1.2.
Richard

kadil
Posts: 4
Joined: Mon 18 May 2009, 03:13

#128 Post by kadil »

OK, I now have a 4.1.2 install on my eeepc701, and I think I have made some progress.

I uncommented the udev rele for the ZTE mf 626

If I issue modprobe usbserial with product and vendor and run pgprs-connect, I now get connection script failed, which I think is much better than cannot find the device. I am using /dev/ttyUSB0 in pgprs-setup.

Still keen for help if you can spare it?

Regards,
Kim

User avatar
zgp152
Posts: 114
Joined: Thu 08 Nov 2007, 19:37

E220 not recognized

#129 Post by zgp152 »

I have used pet v 10 and have run the modeswitch pet as well.
I have uncommented the two device-specific lines (354 and 355) for Huawei devices as adviced in usb_modeswitch.conf and tried both alternatives of usb_modeswitch values (lines 358 and 359). Setup wizard detects only eth0 but no modem (that is: E220), persistently. Should I make eth0 disappear, and if yes, how?

Running usb_modeswitch.sh in verbose mode, it says "default device found" and "for better success provide target IDs or class". Have I some shortcomings in the parameter settings? Where to insert "target ID" value(s)? Parameters from SIM ?OR? target ID value for Huawei E220?

A more basic question. After modifying any of the conf files, what is the minimum effort to activate the latest version of the file, if rebooting is overdone. I am running from CD and I have a .2fs file on HD.

Rgds zgp152

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

#130 Post by rerwin »

kadil,
Sorry about my late-night cryptic response to your request. I was able to reflect on more of an answer by morning. Got your PMed log file, thank you. It appears you did exactly right.

The log shows the error -110 that I have not been able to solve. The libusb message appears to be a quibble (or might be related to the -110, now that I think about it), since usb_modeswitch did actually run. The only alternate approaches I can think of bypass usb_modeswitch.

1. Later linux kernels handle some of the mode switching without needing usb_modeswitch. So one way would be to wait until puppy 5 comes out or try a puplet that uses a later kernel. Slax-pup is one and I thought I saw another in the forum (probably in the Puppy Derivatives section.

2. The simpler (and anecdotal) trick is to "eject" the storage-device, which apparently causes the mode to switch, so that the modem is identified. I don't know how to do that, but other postings probably explain, both in this thread and elsewhere in the forum. If you try this, be sure to re-comment the udev rule you activated, so that it does not interfere with the erase-modeswitch.

I am exhausted after weeks of testing and getting only the error -110 and no advice on what to do about it. Since the modem requires the two patched drivers in order to have any chance of working, I am inclined to wait for the later kernels, which include those patches and might resolve the issue.

Just a thought, after adding my aside about the libusb and -110 being related: Maybe puppy'sversion of libusb is old. I will have to edit this with details after I find them, but you could try replacing the libusb piece if there is a version later than puppy's.
Richard

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

#131 Post by rerwin »

zgp152,
Setup wizard detects only eth0 but no modem (that is: E220), persistently.
The Internet setup wizard works only with ethernet networks. Although called "broadband" the modems are considered as dialup connections and are not handled by the setup wizard, at all. Use the "Connect Wizard" at the left side of the screen. It should show ttyUSB0 or another modem if you have one.

I have seen reports where it was necessary to disable the ethernet interface to get the modem to work. That seems drastic. You could try turning off the interface by entering:
ifconfig eth0 down
if it is already active, but that apparently is not enough. As a last resort, disable the network hardware in the computer BIOS (or just remove it if it is USB or PCcard).

You say you used the "manual" method of running usb_modeswitch. Did you try the automated method? Did you check the usb_modeswitch.log after booting up and later unplugging and replugging the modem? I would expect it to show the same results, but will show multiple attempts. Could you PM me that log at that point, and the /tmp/udevtrace-modem.log?

If the computer has already found another modem, be sure to "erase" it in Pupdial (probe>ERASE) before rebooting. If none of this works, try forcing loading of "option" in the BootManager and reboot.

This is a lot of stuff, but it might save us some back-and-forth. BTW: usb_modeswitch.sh already runs usb_modeswitch in verbose mode, so no need for a "-W" argument.
After modifying any of the conf files, what is the minimum effort to activate the latest version of the file, if rebooting is overdone.
I'm not sure how to answer that. The only .conf file to modify is usb_modeswitch.conf. That is used only if you run usb_modeswitch.sh from the command line. For your modem, the corresponding udev rule is already active during boot-up. If you don't see a usb...log file after bootup with the modem plugged into or replugged, I need to know. That would implicate the rule as bad. As for restoring a clean .conf, you can simply uninstall and re-install the 3G-pupdial...-10.

Regarding target IDs: many modems change their hardware IDs as part of mode switching. Others change only their class: I assume the "Huawei Mode" parameter causes that to happen for the E220.
Richard

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

#132 Post by rerwin »

kadil and anyone getting the usb_modeswitch error -110,

Kadil's log had usb_modeswitch issuing a cryptic message about libusb, along with the error -110. Since usb_modeswitch seems to work -- other than for the message -- I assumed the version of libusb in puppy would be sufficient. Maybe it's not. Can someone test this for me, in a standard puppy 4.1.2?

I compiled what appears to be a later version and made it into a dotpet, attached. Please install that package and tell me if it makes any difference. If it doesn't, we might try moving it to where to puppy version is. But one thing at a time. This is particularly for the ZTE MF626 and any other ZTEs getting that error.
Richard
Attachments
libusb-1.0.0-i486.pet
For testing with some ZTE modems.
(22.89 KiB) Downloaded 429 times

User avatar
kayan
Posts: 90
Joined: Thu 14 Feb 2008, 18:26
Location: India

#133 Post by kayan »

@rerwin
Sorry for the delay ,i was out of station.
Here is my feedback
Fresh install of slaxer_pup in frugal ...
1. I expect the first bootup to show "no modem detected". If ttyS0 is shown, please use the connect wizard and analog modem option to get to pupdial, then "probe" and "ERASE", to get "no modem detected".
There was no modem detected on boot up ,WvDiail.conf was created after probe and ERASE .
2. Install the 3G-pupdial dotpet, after downloading it from this thread (first post). I have just now updated it with some delay logic for "option" modems; but if yours is different the logic is unimportant.
installed 3G-pupdial-wireless10.pet
3. Plug in the modem, wait a couple of minutes, then look for a file: /etc/init.d/Option ( or some other file there with a name beginning with a capital letter). Let me know whether one is there.
No new file was created.
4. Reboot, making a new pupsave file in the process. Ideally, the connect wizard should show detection of a ttyUSB0 device. Verify again whether there is a capitalized file name in /etc/rc.d.
No file was created after save and reboot

rebooted My WvDial.conf is as follows,
[Dialer Defaults]
Modem = /dev/MYDEVM
Baud = 57600
Init1 = ATZ
Init2 = ATQ0V1E1S0=0&C1&D2S11=55+FCLASS=0
Carrier Check = no
Dial Command = ATDT
Phone = MYISPPHONENUM
Username = MYUSERNAME
Password = MYPASSWORD
Auto Reconnect = yes

[Dialer isp2]
Phone = MY2ISPPHONENUM
Username = MY2USERNAME
Password = MY2PASSWORD
Auto Reconnect = yes
I edited my modem to /dev/ttyUSB0, and my login and password .
I left the init2 stings and Dial Command as it is.
My dial up connection is faster
Hope this was useful :)
Regards
kayan
Last edited by kayan on Mon 25 May 2009, 09:41, edited 1 time in total.
[color=blue]SAHARA laptop intel celeron M 1.4 GHz/ 768Mb Ram /40GB ,SIS 661 chipset,[/color]

mimeini
Posts: 37
Joined: Thu 04 Dec 2008, 10:49

HUAWEI E169 and denmark calling

#134 Post by mimeini »

Ok now I an trieing this. I only have my mobilephone to do this posting so I can't sent you any log files. I have installed the 3g-pupdial-wireless pet and the USB-modemswitch pet. And now I just tried different first the gprs wizard from the network icon on the disktop. Using Puppy 4.1.2. It seems my modem is found as dev/ttyS_PCTEL0. It did not work. That is pretty clear since I did not have the right APN. But I could call my provider and get it. The question is if I an doing the right thing here? If it is the gprs wizard I need to use or if it is something else? As phone number I put. *99***1#. What should I do here?

uhhu
Posts: 20
Joined: Sun 24 May 2009, 21:14

Probably a stupid question

#135 Post by uhhu »

Although I have not been able to figure out what I am supposed to do after installing the .pet packages to make use of them, I finally managed to connect with Huawei E160E even on a clean system (puppy pfix=ram) with a simple startup script:

Code: Select all

# cat > /root/Startup/mobile
#!/bin/sh
rmmod usbserial
modprobe usbserial vendor=0x12d1 product=0x1003

Code: Select all

# chmod a+x /root/Startup/mobile
[On a clean system,] I restarted X with Menu > Shutdown > Advanced X Server to test that the startup works. Then I filled the PGPRS modem settings dialog and changed the behavior of the connect icon, clicked connect and in a few seconds, I was online.

What should I have done after installing the .pet packages to make them work?

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

#136 Post by muggins »

rerwin,

sorry about being tardy in responding to this thread, but have been somewhat sidetracked by other issues. Anyway, I tried your newer libusb .pet, with an MF626, and still getting the -110 error. Maybe time to shelve worrying about MF626's until a newer kernel puppy is released?

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

#137 Post by rerwin »

kayan,
I take it that the only thing you needed to do was to set "modem = /dev/ttyUSB0 in wvdial.conf. The option module must have gotten loaded (since you did not say you force use of usbserial - the old way, please avoid). So the link (/dev/modem) is not being set to ttyUSB0 and wvdial is not set (as a consequence of that).

This tells me that the initialization script either did not run or did not wait long enough for the option module to load. I need to see different files than what you posted. Xerrs.log is not involved in the modem setup, so is unnecessary (and just fills up the thread, so you can edit it out of your post). The files I need to see are /tmp/udevtrace-modem.log and /tmp/usb_modeswitch.log (if any). Could you also post the output of the lsmod command, a few minutes after bootup with the modem plugged in?

Thanks again for helping me with this.
Richard

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

#138 Post by rerwin »

mimeini,
Welcome to this thread.
The question is if I an doing the right thing here? If it is the gprs wizard I need to use or if it is something else?
In a word: no. This project does not involve the GPRS wizard, at all. In fact, I do not fully understand what it does, but it appears to relate to a particular modem or provider. But maybe I should not even guess at that.

This project is about the regular dialup modem detection and support, primarily PupDial, and extending it to include wireless modems. So, everyone please avoid the GPRS wizard when working with me on this wireless integration project.
It seems my modem is found as dev/ttyS_PCTEL0. It did not work. That is pretty clear since I did not have the right APN.
Those are not effect and cause. You may not need the APN, so don't add it yet. First, please tell me what your modem really is. You apparently have a PCTEL wired dialup modem in your PC (What is it in, anyway?), so we have to deal with that. BTW, the phone number is fine.

One thing to try is to use PupDial probe>ERASE and then reboot, to allow Puppy to find the wireless modem on the second boot. At least that is how I expect it to work, but we may not be there yet.

I am eager to help, but need more information.
Richard

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

#139 Post by rerwin »

uhhu,
Thanks for joining. Although your method of connecting obviously works, this project attempts to eliminate the need for users to do all that and, instead, to use the analog modem (PupDial) connection interface.
What should I have done after installing the .pet packages to make them work?
If the dotpets work as intended, you should not have had to do any script writing or commanding (which would probably interfere with the automation). And do not use the GPRS wizard for this project (see my previous post). The Connect Wizard should show your modem as /dev/ttyUSB0. I think, though, it will require a second bootup to have it be detected.

Please try again, by booting up fresh (as you did), waiting a few minutes, use lsmod to see if the option module is loaded, then (assuming no other modem was detected) just reboot, to see if it is detected. Whatever happens, please post the content of the /tmp/udevtrace-modem.log and /tmp/usb_modeswitch.log files. Thanks
Richard

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

#140 Post by rerwin »

muggins,
Nice to see you back. There seems to be a lot of interest in that modem, but no success. Others are trying slax-pup, which has a later kernel, so you might, too. Please use the latest versions of the 3g-pupdial and usb_modeswitch dotpets. The patched drivers should not be needed with slax-pup.

You might also try Barry's alpha9. However, I cannot verify he picked up all the right pieces until Saturday, as I am without Puppy until then (only on a locked WinXP system), so cannot read the insides of the alpha.
Richard

Post Reply