1

I used to force my huawei E3531 modem to stay in serial mode using usb_modeswitch on my linux ubuntu computer. I was running this:

usb_modeswitch -v 12d1 -p 1f01 -M '55534243123456780000000000000011062000000100000000000000000000'

where the 12d1 is the id vendor, and 1f01 is the product vendor. It used to work well, i was then able to send AT commands...

Now I changed my set up for a banana pi, using bananian. And this modeswitch command does not work. Here is what happen

Taking all parameters from the command line


 * usb_modeswitch: handle USB devices with multiple modes  * Version
1.2.3 (C) Josua Dietze 2012  * Based on libusb0 (0.1.12 and above)

 ! PLEASE REPORT NEW CONFIGURATIONS !

DefaultVendor=  0x12d1

DefaultProduct= 0x1f01

TargetVendor=   not set

TargetProduct=  not set

TargetClass=    not set

TargetProductList=""

DetachStorageOnly=0

HuaweiMode=0

SierraMode=0

SonyMode=0

QisdaMode=0

GCTMode=0

KobilMode=0

SequansMode=0

MobileActionMode=0

CiscoMode=0

MessageEndpoint=  not set

MessageContent="55534243123456780000000000000011060000001000000000000000000000"

NeedResponse=0

ResponseEndpoint= not set

InquireDevice disabled

Success check disabled

System integration mode disabled

usb_set_debug: Setting debugging level to 15 (on)

usb_os_find_busses: Found 004

usb_os_find_busses: Found 003

usb_os_find_busses: Found 002

usb_os_find_busses: Found 001

usb_os_find_devices: Found 002 on 004

usb_os_find_devices: Found 001 on 004

error obtaining child information: Inappropriate ioctl for device

usb_os_find_devices: Found 001 on 003

usb_os_find_devices: Found 001 on 002

usb_os_find_devices: Found 018 on 001

skipped 3 class/vendor specific interface descriptors

usb_os_find_devices: Found 004 on 001

skipped 1 class/vendor specific interface descriptors

usb_os_find_devices: Found 003 on 001

skipped 1 class/vendor specific interface descriptors

usb_os_find_devices: Found 002 on 001

usb_os_find_devices: Found 001 on 001

error obtaining child information: Inappropriate ioctl for device

error obtaining child information: Inappropriate ioctl for device

error obtaining child information: Inappropriate ioctl for device

Looking for default devices ...   searching devices, found USB ID
0403:6001

  searching devices, found USB ID 1d6b:0001

  searching devices, found USB ID 1d6b:0002

  searching devices, found USB ID 1d6b:0001

  searching devices, found USB ID 12d1:14dc

  found matching vendor ID

  searching devices, found USB ID 413c:3012

  searching devices, found USB ID 413c:2003

  searching devices, found USB ID 05e3:0608

  searching devices, found USB ID 1d6b:0002

 No devices in default mode found. Nothing to do. Bye.

So doing a lsusb you can see that the device is not 12dc:1f01 but

Bus 001 Device 018: ID 12d1:14dc Huawei Technologies Co., Ltd.

so I did a dmesg to see what happened:

[ 3703.945245] cdc_ether 1-1.1:1.0: usb0: unregister 'cdc_ether'
usb-sw-ehci-1.1,  CDC Ethernet Device

[ 3938.661981] usb 1-1.1: new high-speed USB device number 17 using
sw-ehci

[ 3938.783662] usb 1-1.1: New USB device found, idVendor=12d1,
idProduct=1f01

[ 3938.797418] usb 1-1.1: New USB device strings: Mfr=1, Product=2,
SerialNumber=3

[ 3938.809290] usb 1-1.1: Product: HUAWEI Mobile

[ 3938.816795] usb 1-1.1: Manufacturer: HUAWEI

[ 3938.825604] usb 1-1.1: SerialNumber: FFFFFFFFFFFFFFFF

[ 3938.891911] scsi13 : usb-storage 1-1.1:1.0

[ 3939.706889] usb 1-1.1: USB disconnect, device number 17

[ 3940.202053] usb 1-1.1: new high-speed USB device number 18 using
sw-ehci

[ 3940.323503] usb 1-1.1: New USB device found, idVendor=12d1,
idProduct=14dc

[ 3940.336703] usb 1-1.1: New USB device strings: Mfr=1, Product=2,
SerialNumber=0

[ 3940.347443] usb 1-1.1: Product: HUAWEI Mobile

[ 3940.355089] usb 1-1.1: Manufacturer: HUAWEI

[ 3940.586414] cdc_ether 1-1.1:1.0: usb0: register 'cdc_ether' at
usb-sw- ehci-1.1, CDC Ethernet Device, c2:71:b7:f9:e4:f6

[ 3940.601758] scsi14 : usb-storage 1-1.1:1.2

[ 3941.615040] scsi 14:0:0:0: Direct-Access     HUAWEI   TF CARD
Storage  2.31  PQ: 0 ANSI: 2

[ 3941.632411] sd 14:0:0:0: Attached scsi generic sg0 type 0

[ 3941.642327] sd 14:0:0:0: [sda] Attached SCSI removable disk

So you can see that the modem change its mode (really fast), am I right?

I tried to run the same usb modeswitch command with the other id product and it does not work:

usb_modeswitch -v 12d1 -p 14dc -M '55534243123456780000000000000011062000000100000000000000000000'

So I need you help guys to understand what is happening. I would like to understand better how the usb_modeswitch is working, or maybe find a solution with udev rules.

0

1 Answer 1

0

I found my answer right there:

Huawei E3531: view signal strength?

sorry for the question

Not the answer you're looking for? Browse other questions tagged .