How to set modem device D-Link DWRr600b via usb_modeswitch
Hi,
I would like my usb modem to be detected as modem and not sda. After connecting the device, he gets the following message:
$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 004: ID 2001:a410 D-Link Corp.
Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
$dmesg
[ 7792.326573] usb-storage 1-1.3:1.2: USB Mass Storage device detected
[ 7792.327020] scsi host0: usb-storage 1-1.3:1.2
[ 7793.355229] scsi 0:0:0:0: Direct-Access SD Storage 0000 PQ: 0 ANSI: 2
[ 7793.356033] sd 0:0:0:0: Attached scsi generic sg0 type 0
[ 7793.367636] sd 0:0:0:0: [sda] Unit Not Ready
[ 7793.367665] sd 0:0:0:0: [sda] Sense Key : 0x5 [current]
[ 7793.367687] sd 0:0:0:0: [sda] ASC=0x20 ASCQ=0x0
[ 7793.387431] sd 0:0:0:0: [sda] Read Capacity(10) failed: Result: hostbyte=0x00 driverbyte=0x08
[ 7793.387451] sd 0:0:0:0: [sda] Sense Key : 0x5 [current]
[ 7793.387466] sd 0:0:0:0: [sda] ASC=0x20 ASCQ=0x0
[ 7793.387488] sd 0:0:0:0: [sda] 0 512-byte logical blocks: (0 B/0 B)
[ 7793.387502] sd 0:0:0:0: [sda] 0-byte physical blocks
[ 7793.387878] sd 0:0:0:0: [sda] Write Protect is off
[ 7793.387894] sd 0:0:0:0: [sda] Mode Sense: 0f 00 00 00
[ 7793.388881] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[ 7793.440858] sd 0:0:0:0: [sda] Unit Not Ready
[ 7793.440878] sd 0:0:0:0: [sda] Sense Key : 0x5 [current]
[ 7793.440893] sd 0:0:0:0: [sda] ASC=0x20 ASCQ=0x0
[ 7793.454856] sd 0:0:0:0: [sda] Read Capacity(10) failed: Result: hostbyte=0x00 driverbyte=0x08
[ 7793.454875] sd 0:0:0:0: [sda] Sense Key : 0x5 [current]
[ 7793.454890] sd 0:0:0:0: [sda] ASC=0x20 ASCQ=0x0
[ 7793.456849] sd 0:0:0:0: [sda] Attached SCSI removable disk
so I add lines to /etc/usb_modeswitch.conf:
DefaultVendor=0x2001
DefaultProduct=0xa410
TargetVendor=0x2001
TargetProduct=0x7e19
StandardEject=1
when I run "sudo usb_modeswitch -c /etc/usb_modeswitch.conf" and reboot system, still sees as sda and doesn't show ttyUSB, but I see that numner is changed
$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 005: ID 2001:7e39 D-Link Corp.
Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
What could I do?
Last edited by Creatorczyk; 02-26-2021 at 01:18 AM.
|