Usb-modeswitch makes easier to use USB modem. But looks like it works for any USB device, including my mobile so that I can't access the memory card because it's changed to serial device by usb-modeswitch.
When using Debian without usb-modeswitch package installed, the memory card can be accessed as storage.
So, I wonder if there's any kind of "exception" for usb-modeswitch so it doesn't turn my mobile to serial device.
Thanks for help.
-
- Posts: 3
- Joined: 26 May 2019, 08:02
Re: Exception for usb-modeswitch
If you can find out with lsusb which device it is, maybe it should be removed from so to modeswitch it, USB_ModeSwitch would have to be invoked manually and it does not get modeswitched automatically. (The clean way would be to edit the package manager package to change this file, otherwise changes will be overwritten when updating.) Maybe it should then be removed upstream’s udev file as well (then the package would not need changing).
(I am no USB_ModeSwitch developer.)
Code: Select all
/usr/lib/udev/rules.d/40-usb_modeswitch.rules
(I am no USB_ModeSwitch developer.)
Re: Exception for usb-modeswitch
There are several ways to do that.tutu10 wrote:I wonder if there's any kind of "exception" for usb-modeswitch so it doesn't turn my mobile to serial device.
Thanks for help.
1. The global approach - affects all USB modems etc.:
Edit "/etc/usb_modeswitch.conf" and change
Code: Select all
DisableSwitching=0
Code: Select all
DisableSwitching=1
2. The 'smart' approach - affects only your phone:
Create a file in "/etc/usb_modeswitch.d" named after the USB ID of your phone (before the mode switch), for instance "12d1:3c4d". Edit the file and put in this:
Code: Select all
# Hands off my phone! Do nothing for ID 12d1:3c4d
Configuration=0
To determine the USB ID of the phone in un-switched mode, disable mode-switching globally (termporarily) as described in 1., then plug in your phone, then run the command "lsusb" in a terminal window. It's likely that you will discover your phone in the result list, along with its ID.
If you have trouble with that, post the result list here.
-
- Posts: 1
- Joined: 06 Nov 2023, 05:10
Re: Exception for usb-modeswitch
USB_ModeSwitch is a utility primarily designed to enable USB modems and other data devices to switch from storage mode to modem mode automatically. It's intended to improve the functionality of these devices when they are recognized as USB storage devices before switching to the modem mode. However, it can also affect other USB devices, including mobile phones, when they share a similar hardware signature heardle
-
- Posts: 5
- Joined: 16 Nov 2023, 04:52
Re: Exception for usb-modeswitch
Yes, USB_ModeSwitch is primarily designed to handle USB modems by switching them from storage mode to modem mode so they can be used for data connections. However, it can sometimes interfere with other USB devices, such as smartphones, by incorrectly identifying them as modems and switching their modes.
Spend Elon Musk Money
Spend Elon Musk Money