I'm a bit curious on automating this. Should I just put a roughly 5-7 second sleep in my shellscript before I make it run usb_modeswitch again (making sure it has a bit of time to load drivers and whatnot) or can I just call them twice in rapid succession?
To avoid the modem switching back that is, I didn't see information on this under the guide for automation.
I could trial and error but I'm also quite curious on how this actually works.
To avoid the modem switching back that is, I didn't see information on this under the guide for automation.
I could trial and error but I'm also quite curious on how this actually works.
-
- Posts: 4
- Joined: 05 Jun 2009, 02:01
Josh: When you tested MD400, which kernel module did you use ? I have been able to get the switch to work fine but no driver is ever loaded. I use Gentoo so I compile my kernel from source. I use gentoo-sources and it does not contain Carl's patch for mbm driver.
jbn: The output from your dmesg or /var/log/messages after the switch to modem configuration might help me find out the right module, especially if you posted the output of your lsmod too
// Fredrik
jbn: The output from your dmesg or /var/log/messages after the switch to modem configuration might help me find out the right module, especially if you posted the output of your lsmod too
// Fredrik
Hello!
Recently received a MD400 that I try to use with Ubuntu 9.04. I have installed usb_modeswitch 1.0.0 (Version printed out is wrong BTW).
When calling usb_modeswitch one time I get:
Should I issue a new call to usb_command withing 10 seconds before the modem is recognized as a mass storage again?
I have also tried:
After that I see the network manager trying endlessly to connect without success.
Please let me know if I should provide further information. Any help would be appreciated!
Best regards,
Peter Carlsson
Recently received a MD400 that I try to use with Ubuntu 9.04. I have installed usb_modeswitch 1.0.0 (Version printed out is wrong BTW).
When calling usb_modeswitch one time I get:
Code: Select all
sudo /home/peter/Eget/usb_modeswitch/usb_modeswitch
[sudo] password for peter:
* usb_modeswitch: tool for controlling "flip flop" mode USB devices
* Version 0.9.8 (C) Josua Dietze 2009
* Works with libusb 0.1.12 and probably other versions
Looking for default devices ...
Found default devices (1)
Accessing device 002 on bus 001 ...
Using endpoints 0x01 (out) and 0x81 (in)
Inquiring device details; driver will be detached ...
Looking for active driver ...
OK, driver found ("usb-storage")
OK, driver "usb-storage" detached
Received inquiry data (detailed identification)
-------------------------
Vendor String: SEMC
Product String: MMC Flash Card
Revision String: 0
-------------------------
Looking for active driver ...
OK, driver found ("usbfs")
OK, driver "usbfs" detached
Trying to send Sony control message
OK, control message sent, waiting for device to return ...
######################
After 22 seconds: device came back, proceeding
Sending Sony control message again ...
OK, control message sent
Note: ignoring MessageContent. Can't combine with special mode
-> device should be stable now. Bye.
Code: Select all
[ 160.268405] usb 1-1: usbfs: process 3112 (usb_modeswitch) did not claim interface 0 before use
[ 160.289523] usb 1-1: usbfs: process 3112 (usb_modeswitch) did not claim interface 0 before use
[ 161.848087] usb 1-1: USB disconnect, address 2
[ 181.852044] usb 1-1: new full speed USB device using uhci_hcd and address 3
[ 182.027791] usb 1-1: configuration #2 chosen from 1 choice
[ 182.063196] scsi3 : SCSI emulation for USB Mass Storage devices
[ 182.063773] usb-storage: device found at 3
[ 182.063780] usb-storage: waiting for device to settle before scanning
[ 182.236243] cdc_acm 1-1:2.1: ttyACM0: USB ACM device
[ 182.239093] cdc_acm 1-1:2.3: ttyACM1: USB ACM device
[ 182.244661] usbcore: registered new interface driver cdc_acm
[ 182.244675] cdc_acm: v0.26:USB Abstract Control Model driver for USB modems and ISDN adapters
[ 182.469696] cdc_wdm 1-1:2.5: cdc-wdm0: USB WDM device
[ 182.469767] cdc_wdm 1-1:2.6: cdc-wdm1: USB WDM device
[ 182.469802] usbcore: registered new interface driver cdc_wdm
[ 182.692317] usbcore: registered new interface driver cdc_ether
[ 182.700611] usb 1-1: unsupported MDLM descriptors
[ 182.700658] usbcore: registered new interface driver zaurus
[ 187.061423] usb-storage: device scan complete
[ 187.064993] scsi 3:0:0:0: Direct-Access SEMC MMC Flash Card 0 PQ: 0 ANSI: 0
[ 187.067350] scsi 3:0:0:1: Direct-Access SEMC MMC Flash Card 0 PQ: 0 ANSI: 0
[ 187.131584] sd 3:0:0:0: [sdb] 348261 512-byte hardware sectors: (178 MB/170 MiB)
[ 187.145434] sd 3:0:0:0: [sdb] Test WP failed, assume Write Enabled
[ 187.145448] sd 3:0:0:0: [sdb] Assuming drive cache: write through
[ 187.157423] sd 3:0:0:0: [sdb] 348261 512-byte hardware sectors: (178 MB/170 MiB)
[ 187.164601] sd 3:0:0:0: [sdb] Test WP failed, assume Write Enabled
[ 187.164614] sd 3:0:0:0: [sdb] Assuming drive cache: write through
[ 187.164636] sdb: sdb1
[ 187.172838] sd 3:0:0:0: [sdb] Attached SCSI removable disk
[ 187.173043] sd 3:0:0:0: Attached scsi generic sg2 type 0
[ 187.179438] sd 3:0:0:1: [sdc] 1967104 512-byte hardware sectors: (1.00 GB/960 MiB)
[ 187.186644] sd 3:0:0:1: [sdc] Test WP failed, assume Write Enabled
[ 187.186658] sd 3:0:0:1: [sdc] Assuming drive cache: write through
[ 187.198448] sd 3:0:0:1: [sdc] 1967104 512-byte hardware sectors: (1.00 GB/960 MiB)
[ 187.205421] sd 3:0:0:1: [sdc] Test WP failed, assume Write Enabled
[ 187.205436] sd 3:0:0:1: [sdc] Assuming drive cache: write through
[ 187.205454] sdc: sdc1
[ 187.213832] sd 3:0:0:1: [sdc] Attached SCSI removable disk
[ 187.214023] sd 3:0:0:1: Attached scsi generic sg3 type 0
Code: Select all
[ 161.848087] usb 1-1: USB disconnect, address 2
[ 181.852044] usb 1-1: new full speed USB device using uhci_hcd and
Code: Select all
sudo ./usb_modeswitch && sleep 7 && ./usb_modeswitch
Please let me know if I should provide further information. Any help would be appreciated!
Best regards,
Peter Carlsson
Your configuration is fine. You need to call USB_ModeSwitch only once. As soon as the ttyACM devices pop up, you are in modem mode. Don't do anything else.
The other posts in this topic were about debugging with a previous version.
There was a missing comment sign in the config file; it's fixed now so you don't get the "ignoring MessageContent" line anymore.
Use the latest version.
The other posts in this topic were about debugging with a previous version.
There was a missing comment sign in the config file; it's fixed now so you don't get the "ignoring MessageContent" line anymore.
Use the latest version.
I googled for you ...
... and found a good overview (as far as my guessing of Sverige tells me) here:
http://wiki.linuxportalen.se/index.php/Mobilt_bredband
There is probably nothing about Bredbandsbolaget access but my guess is all you need for that is the correct Access Point (APN) and your SIM card.
... and found a good overview (as far as my guessing of Sverige tells me) here:
http://wiki.linuxportalen.se/index.php/Mobilt_bredband
There is probably nothing about Bredbandsbolaget access but my guess is all you need for that is the correct Access Point (APN) and your SIM card.
ThanksJosh wrote:I googled for you ...
... and found a good overview (as far as my guessing of Sverige tells me) here:
http://wiki.linuxportalen.se/index.php/Mobilt_bredband
There is probably nothing about Bredbandsbolaget access but my guess is all you need for that is the correct Access Point (APN) and your SIM card.
I have really used Google but this URL was new to me and it seems that the (default) APN I had is wrong. I am at work right now but will try as soon as I get home.
Thanks for the great help!
Best regards,
Peter Carlsson
Home from work!
Noticed that if I call usb_modeswitch (version 1.0.0) one time it seems like the modem switches back to USB storage again after a few seconds. This is in Ubuntu 9.04 and I also see that two file windows (one for each USB partition) are opened. Maybe this has something to do with Ubuntu automounter, but why is my modem switching back?
Below is the log from where I issue the usb_modeswitch command:
Am I doing something wrong?
Noticed that if I call usb_modeswitch (version 1.0.0) one time it seems like the modem switches back to USB storage again after a few seconds. This is in Ubuntu 9.04 and I also see that two file windows (one for each USB partition) are opened. Maybe this has something to do with Ubuntu automounter, but why is my modem switching back?
Below is the log from where I issue the usb_modeswitch command:
Code: Select all
[ 153.531207] usb 1-1: usbfs: process 3191 (usb_modeswitch) did not claim interface 0 before use
[ 153.537971] usb 1-1: usbfs: process 3191 (usb_modeswitch) did not claim interface 0 before use
[ 154.904072] usb 1-1: USB disconnect, address 2
[ 174.668038] usb 1-1: new full speed USB device using uhci_hcd and address 3
[ 174.841321] usb 1-1: configuration #2 chosen from 1 choice
[ 174.876711] scsi3 : SCSI emulation for USB Mass Storage devices
[ 174.877311] usb-storage: device found at 3
[ 174.877318] usb-storage: waiting for device to settle before scanning
[ 175.056831] cdc_acm 1-1:2.1: ttyACM0: USB ACM device
[ 175.060929] cdc_acm 1-1:2.3: ttyACM1: USB ACM device
[ 175.072356] usbcore: registered new interface driver cdc_acm
[ 175.072370] cdc_acm: v0.26:USB Abstract Control Model driver for USB modems and ISDN adapters
[ 175.230111] cdc_wdm 1-1:2.5: cdc-wdm0: USB WDM device
[ 175.230184] cdc_wdm 1-1:2.6: cdc-wdm1: USB WDM device
[ 175.230219] usbcore: registered new interface driver cdc_wdm
[ 175.391658] usbcore: registered new interface driver cdc_ether
[ 175.397180] usb 1-1: unsupported MDLM descriptors
[ 175.397230] usbcore: registered new interface driver zaurus
[ 179.877411] usb-storage: device scan complete
[ 179.880696] scsi 3:0:0:0: Direct-Access SEMC MMC Flash Card 0 PQ: 0 ANSI: 0
[ 179.883331] scsi 3:0:0:1: Direct-Access SEMC MMC Flash Card 0 PQ: 0 ANSI: 0
[ 179.948494] sd 3:0:0:0: [sdb] 348261 512-byte hardware sectors: (178 MB/170 MiB)
[ 179.958931] sd 3:0:0:0: [sdb] Test WP failed, assume Write Enabled
[ 179.958945] sd 3:0:0:0: [sdb] Assuming drive cache: write through
[ 179.970376] sd 3:0:0:0: [sdb] 348261 512-byte hardware sectors: (178 MB/170 MiB)
[ 179.977696] sd 3:0:0:0: [sdb] Test WP failed, assume Write Enabled
[ 179.977710] sd 3:0:0:0: [sdb] Assuming drive cache: write through
[ 179.977732] sdb: sdb1
[ 179.985762] sd 3:0:0:0: [sdb] Attached SCSI removable disk
[ 179.985964] sd 3:0:0:0: Attached scsi generic sg2 type 0
[ 179.990388] sd 3:0:0:1: [sdc] 1967104 512-byte hardware sectors: (1.00 GB/960 MiB)
[ 179.997370] sd 3:0:0:1: [sdc] Test WP failed, assume Write Enabled
[ 179.997384] sd 3:0:0:1: [sdc] Assuming drive cache: write through
[ 180.009378] sd 3:0:0:1: [sdc] 1967104 512-byte hardware sectors: (1.00 GB/960 MiB)
[ 180.016366] sd 3:0:0:1: [sdc] Test WP failed, assume Write Enabled
[ 180.016379] sd 3:0:0:1: [sdc] Assuming drive cache: write through
[ 180.016396] sdc: sdc1
[ 180.024733] sd 3:0:0:1: [sdc] Attached SCSI removable disk
[ 180.024917] sd 3:0:0:1: Attached scsi generic sg3 type 0
[ 483.000131] e100: eth0: e100_watchdog: link up, 100Mbps, full-duplex
[ 483.000730] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[ 493.396031] eth0: no IPv6 routers present
I have now disabled automount in Ubuntu 9.04 and now the USB storage drives does no longer show up.Josh wrote:I can see nothing switching back ...
The ttyACM0/1 devices are not removed. What you get are NEW storage devices after switching (card reader and probably the "driver disk" again
Actually, I think the switching is successful and the NetworkManager is trying to connect on /dev/ttyACM0 and /dev/ttyACM1 without success. The log file (not available at the moment) says something about:
Code: Select all
(dev/ttyACM0) GSM puk secret required
This has nothing to do with USB_ModeSwitch, but someone on this forum might have an answer.
Best regards,
Peter Carlsson