How comes my modem gets switched when plugged during boot?
This post is inspired by a similar question made by a Linux user. Exact question answered by this post is:
When my USB modem is plugged during boot, it gets switched, although modem-modeswitch, Usb-ModeSwitch and Sakis3G are not installed on my system. How is that possible?
Some modems automatically switch mode (and, most of them, their product ID along the way), on their own (without the need for Usb-ModeSwitch), when they are simply "ejected". Reason we call it "eject" is that they indeed actually "fool" computer/operating system into presenting themselves as USB CD-ROMs (their commercial name now turns relative: "ZeroCD"). When those pseudo-CD-ROM devices receive the "eject-your-media" SCSI command, they instead switch mode, and become usable as modems.
Some others, switch mode (again, on their own), if being plugged on computer for some seconds (e.g. modem might switch on its own after 60 seconds of inactivity have expired). This one case is self-explained and we will not bother more on this post.
Sakis3G: 0.2.0 Unleashed
After a severe networking problem which resulted into:
- extended downtime during 2010-04-28 (problem persists, resulting in network being dropped for 1-2 minutes, be patient and try again), and
- three days of delay against scheduled release date:
I am finally proud to announce version 0.2.0 of Sakis3G All-in-one script!!! Sakis3G script now has:
- Its own mini-site: http://www.sakis3g.org/.
- And its own Wiki, to get documentation out of my blog: http://wiki.sakis3g.org/.
- And its own forum for supporting users: http://forum.sakis3g.org/.
- Sakis3G.org is also affected by fore mentioned network problem.
- If you provide links on your site, referring to Sakis3G script, please update your site so it now points to www.sakis3g.org.
I really hope that you enjoy new version (especially those disappointed by previous versions)!!!
- By the way, if you are one of those who prefer legacy version's interface, use "--legacy" command line switch.
Release notes:
Version 0.2.0 is written from scratch and is not derived from 0.1.3 (now called legacy) series.
- Examples, user guides, instructions and documentation for legacy version, are not applicable to 0.2.0 series.
- Modified functionality:
- Drastically improved workflow and device selection procedure, allowing even more USB modems to work with Sakis3G script.
- Permanently dropped dependency to sharutils/uudecode. Script now depends on bunzip2 and tar instead.
- 9menu binary is not anymore embedded in script, still can be used if "--9menu" or "--legacy" switches are specified.
- Menu, presented by user interface, now has more options.
- Removed "replacedefaultroute" from pppd arguments since several pppd versions do not recognize it. Script anyway fixes routing table, unless newly introduced "--nofix" switch is set.
- You no longer need to again provide connection details, when using "reconnect" argument, while already connected.
- Several command line arguments and variables are now obsolete or replaced. Consult documentation for more details.
- Setting environment variables, before invoking script, is not anymore encouraged. Instead, they can now be supplied as arguments or within configuration files. Consult documentation for more details.
- Employed a workaround for "gksu" versions which do not respect arguments containing whitespace characters.
- Employed a workaround for modems not properly displaying operator's name. Name is read from operator's database, if an entry exists.
- Improved method of acquiring access to a running X session, when invoked with root privileges.
- Kernel module loading/unloading is now safer and cleaner. Script now attempts to unload module only when it refuses to unbind from device.
- Script should now be able to utilize even more USB modems (and not just option.ko handled ones).
- Modems can now be recognized and setup according to the model name they report, and not by their USB IDs.
- Script can now understand whether pppd or wvdial succeeded, or failed, into getting connected, and success is not determined upon timeouts.
- Improved desktop shortcut creation method.
- Several, less important, modifications.
- New functionality:
- A more sophisticated concept for command line arguments has been introduced for those wishing to max out possibilities.
- Command line arguments, environment variables and user input are now sanitized before being used. This should reduce risk of a malicious user passing specially crafted values.
- Several new configuration variables are now introduced, allowing better overall control over performed actions.
- Connection information is now available, while connection is still running.
- Configurations file(s) are now possible. Consult documentation for more information.
- Script can now discover available/best fitted kernel module(s) for a USB modem.
- Script can now create character device nodes, within /dev directory, when system did not already.
- Script now takes care of not becoming "stalled" when a broken USB device blocks access to USB bus.
- Script now exclusively locks "org.freedesktop.Hal.Device.Storage" before switching a device, unless "--nohal" switch is set. This improves stability by reducing simultaneous operations to storage and modem interfaces of a USB device.
- Script now utilizes "avoid_reset_quirk" available in recent kernels.
- Script now checks for mandatory dependencies being present in PATH, before proceeding with execution.
- Script now instructs pppd to use file /etc/ppp/peers/sakis3g, if file exists and pppd is used for connection.
- Script now offers a UI for selecting and setting up nearby Bluetooth devices, to be used as modems.
- When operator is not found within embedded operators' database, script attempts to fetch last APN, modem was used with, by querying modem.
- Subscribers to virtual operators are now presented their operator's name instead of network's name. This is possible by reading service provider's name from SIM card, if modem permits it.
- Script can now use "zenity", for becoming a "background process" reachable through an icon in notification area, when "helper" command line argument is used.
- It is now possible to keep "secret" a modem from HAL by using "--nohalinform" switch.
- It is now possible to request for storage part of a USB device being "eliminated", using "--nostorage" switch, which might improve stability on some devices.
- It is now possible to construct a binary free version of script, suitable for all architects. However, binary free version depends on a working Usb-ModeSwitch installation, for setting up switchable USB devices.
- It is now possible to disassemble script, back to its ingredients, by using "disassemble" command line argument.
- Script can now switch devices, not found within embedded Usb-ModeSwitch device database, if appropriate file is found within /etc/usb_modeswitch.d directory.
- Script now embeds man pages, accessible using "man" command line argument.
- Script now allows UTF-8 translations, so that localized versions appear in the future. A translation is currently available only for Greek language.
- Several, less important, newly introduced functionality.
- User interface:
- Sakis3G now has its own Tux icon. Icon is used when creating desktop shortcut, unless an operator logo is available and user selects that one instead.
- Script can now use anyone of "kdialog", "zenity", "Xdialog", "9menu", "whiptail" and "dialog" for displaying user interface.
- If none of them is available, script can resemble an elementary text-mode user interface through shell builtin functions, if "--interactive" switch is set.
- Balloon notifications can now appear, when "--balloons" switch is set, using libnotify.
- All options available through user interface, are available as command line arguments as well. The opposite statement is not true.
- Translations are not used when:
- using "Xdialog" or "9menu" as user interface.
- displaying OSD messages.
- Switch "--notranslate" is set.
- Embedded Usb-ModeSwitch:
- Upgraded to version 1.1.2alpha.
- Device database upgraded to 2010-04-18 version.
- It is now possible to compile it for your platform, by using "recompile" command line argument, or by selecting equivalent UI option.
- It is now possible to directly reach embedded Usb-ModeSwitch binary, by using "usb_modeswitch" command line argument.
- Operators' database:
- Entries available in legacy version were migrated to 0.2.0 version.
- You can now connect to any operator, even if not found within operators' database. You just need to know APN details.
- It is not anymore possible/required to add operators by modifying script.
- Modified following networks:
- 20201: Cosmote (Greece): Included an extra APN.
- 20209: Wind (Greece): Added "Q" APN.
- 20210: Wind (Greece): Added "Q" APN.
- 26202: Vodafone (Germany): Added "1und1" APN.
- 26204: Vodafone (Germany): Added "1und1" APN.
- 26209: Vodafone (Germany): Added "1und1" APN.
- 26801: Vodafone (Portugal): Added "ZON" APN.
- Added the following operators:
- 23430: T-Mobile (United Kingdom)
- 23802: Telenor (Denmark)
- 34001: Orange (French Caraibes)
Sakis3G 0.2.0 closed beta ended
Closed beta phase ends in like two hours. I need to thank people who participated, especially those who slept less because of me.
Version 0.2.0 will be released on 2010-04-27 22:00 GMT Update: I had to postpone until tonight 2010-04-28 21:00 GMT.
I know, it sounds like 2010-04-28, but I got some nice excuses.
Stay tuned for more happy days.
Sakis3G 0.2.0 closed beta initiated
Version 0.2.0 is mostly finished. Critical issues have been corrected and operation is stable. Being a complete re-write, counting 7,6k lines, I hesitate to directly release it to public. For this reason, a closed beta phase initiates today and will hopefully end by 2010-04-26.
People, eligible to participate in closed beta, will soon (if not having already) receive their invitation letter.
If you feel like participating, apply by making a comment on this post and I will contact you back through email.
Scheduled release date of 0.2.0 version of Sakis3G script is 2010-04-27, unless a release critical issue has shown up.
Sakis3G timeline
It will be no further updates to the 0.1.3 series of Sakis3G. Instead, version 0.2.0 will be released in something more than two weeks. Version 0.2.0 is a complete re-write (under development since Mid-February) with major changes including but not limited to:
- Different workflow which allows more stable operation for several devices/kernels/environments.
- Allows even more USB modems to work (and not only "option.ko" driven).
- Permanently drops dependency to sharutils/uudecode.
- More GUI options. Better appearance. 9menu is not anymore embedded in script, still can be used if found within path.
- Allows UTF-8 translations so that localized versions appear in the future.
- Will not exceed 200 KB (currently compiles to 160KB) + any added size from translations.
- Comes bundled with latest Usb-ModeSwitch version. More than that, it now includes source and can compile it itself (if not in a 386 platform).
- Includes even more "magic" of your already favorite flavor. It is still one "magic" file doing all, touching nothing, no-installation required.
You should not expect 0.2.0 to come before April 14th (still many things to do, large part of documentation needs to be rewritten).
- Connection information through Zenity
- Connection information when using terminal
- Main menu when using Zenity
- MORE menu when using 9menu
- MORE menu when using dialog
- MORE menu when using interactive terminal
- MORE menu when using kdialog
- MORE menu when using whiptail
- MORE menu when using Xdialog
Using your bluetooth enabled phone with Sakis3G
| Notice: This post provides links and instructions referring to an old version of Sakis3G script. Page is still available only for historical reasons. Please visit www.sakis3g.org for latest Sakis3G script version. |
Αυτό το άρθρο υπάρχει και στα Ελληνικά.
Sakis3G script is actually able to use any 3G modem, and not just USB ones. Good. Many of our bluetooth enabled cellular phones also offer their modem capabilities over bluetooth. It would be nice providing 3G internet on your laptop on the go, while keeping your phone hidden on your pocket.
Check video below (see it on YouTube) to motivate yourself going through this guide.
Sakis3G: 0.1.3 Released
Version 0.1.3 of Sakis3G script is released prior to what was scheduled as an "emergency update", to 0.1.2, which introduced severe regression issues. While expected version number would be 0.1.2b or something, 0.1.3 was chosen as it also includes many changes not visible to bare eye.
Along with this announcement comes a notice: no new features or functionality will be implemented until 0.1.3 has become stable enough. Upcoming releases will only include fixes, operator/modem additions, timeout tweaks and maybe UI improvement. Therefore, next releases will be following 0.1.3x versioning schema, where "x" will be "a", "b", "c" and so on. Enthusiasm should step aside for a while, until usability grows enough.
Sakis3G: Unknown operator XXXXX
| Notice: This post provides links and instructions referring to an old version of Sakis3G script. Page is still available only for historical reasons. Please visit www.sakis3g.org for latest Sakis3G script version. |
You downloaded Sakis3G script but it now stops with error "Unknown operator XXXXX". This means that Sakis3G script is not aware of your operator. At first, let me apologize: this script is in early steps and embedding all operators' details is (a) hard work and (b) I do not know how to find all required information. This is why, if you succeed implementing instructions below, you should send me feedback. By doing so, people that use the same operator with you, will not have to repeat instructions.
Sakis3G: 0.1.1 Released
Version 0.1.1 of Sakis3G script is released, in accordance with 1.1.0 update of Usb-ModeSwitch. Script now waits for network logon even when SIM card does not require PIN number. Progress bar indication, if xosd (osd_cat) is installed, is now turned off by default. Added support for Italian, Portugish, Hondurian and more German operators.
Read change log.









Dodging Wordpress comment spammers
I admit: Allowing anyone to post comments is bad practice. Though, I've got my reasons to stand my ground. I've many times read something on a blog and to some of them I even had something to add. Could potentially help blog's author or future visitors by sharing my own experience, or request a solution to one of my problems by posting a question. Guess what? I am so lazy that I rarely go through registration procedure, just to enable me posting a comment.