Automatic Activation, Hotplug and UDEV, Configuration
Post Reply
shley
Posts: 2
Joined: 15 Mar 2013, 15:12

Huawei E3231 - ttyUSB created, but sakis hangs

Post by shley » 15 Mar 2013, 15:28

Although I am in a similar position to another poster http://www.draisberghof.de/usb_modeswit ... f=4&t=1226, I'm experiencing different problems so am creating a new topic.

Initially I had no ttyUSB entry in /sys/bus/usb/devices/1-1/1-1\:1.*:

Code: Select all

lsusb -v -d  12d1:14db:
Bus 001 Device 010: ID 12d1:14db Huawei Technologies Co., Ltd. 
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            2 Communications
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  idVendor           0x12d1 Huawei Technologies Co., Ltd.
  idProduct          0x14db 
  bcdDevice            1.02
  iManufacturer           2 HUAWEI Technology
  iProduct                1 HUAWEI Mobile
  iSerial                 0 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           71
    bNumInterfaces          2
    bConfigurationValue     1
    iConfiguration          3 Huawei Configuration
    bmAttributes         0x80
      (Bus Powered)
    MaxPower              500mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           1
      bInterfaceClass         2 Communications
      bInterfaceSubClass      6 Ethernet Networking
      bInterfaceProtocol      0 
      iInterface              0 
      CDC Header:
        bcdCDC               1.10
      CDC Ethernet:
        iMacAddress                      4 582C80139263
        bmEthernetStatistics    0x00000005
        wMaxSegmentSize               1514
        wNumberMCFilters            0x0003
        bNumberPowerFilters              1
      CDC Union:
        bMasterInterface        0
        bSlaveInterface         1 
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               5
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        1
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass        10 CDC Data
      bInterfaceSubClass      6 
      bInterfaceProtocol      0 
      iInterface              0 
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval              32
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval              32
Device Qualifier (for other device speed):
  bLength                10
  bDescriptorType         6
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  bNumConfigurations      1
Device Status:     0x0000
  (Bus Powered)

Code: Select all

/var/log/syslog:
Mar 15 00:43:48 kernel: [    4.709082] usb 1-1: new high-speed USB device number 5 using ehci_hcd
Mar 15 00:43:48 kernel: [    4.824534] usb 1-1: New USB device found, idVendor=12d1, idProduct=1f01
Mar 15 00:43:48 kernel: [    4.824541] usb 1-1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
Mar 15 00:43:48 kernel: [    4.824545] usb 1-1: Product: HUAWEI Mobile
Mar 15 00:43:48 kernel: [    4.824548] usb 1-1: Manufacturer: HUAWEI Technology

Mar 15 00:43:48 kernel: [   14.657651] usb 1-1: USB disconnect, device number 5
Mar 15 00:43:48 kernel: [   14.988076] usb 1-1: new high-speed USB device number 6 using ehci_hcd
Mar 15 00:43:48 kernel: [   15.103114] usb 1-1: New USB device found, idVendor=12d1, idProduct=14db
Mar 15 00:43:48 kernel: [   15.103122] usb 1-1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
Mar 15 00:43:48 kernel: [   15.103126] usb 1-1: Product: HUAWEI Mobile
Mar 15 00:43:48 kernel: [   15.103129] usb 1-1: Manufacturer: HUAWEI Technology
Mar 15 00:43:48 kernel: [   15.491901] cdc_ether 1-1:1.0: eth1: register 'cdc_ether' at usb-0000:00:03.3-1, CDC Ethernet 
Device, 58:2c:80:13:92:63
Mar 15 00:43:48 kernel: [   15.492218] usbcore: registered new interface driver cdc_ether
I followed the instructions in the linked thread and others, such as running the commands:

Code: Select all

modprobe option
echo 12d1 14db  >/sys/bus/usb-serial/drivers/option1/new_id
Still no ttyUSB, so, I then ran sakis with the command line argument:

Code: Select all

USBDRIVER="option"
This succeeded in creating a ttyUSB entry:

Code: Select all

ls -l /sys/bus/usb/devices/1-1/1-1\:1.*
/sys/bus/usb/devices/1-1/1-1:1.1:
total 0
-rw-r--r-- 1 root root 4.0K Mar 15 00:45 uevent
lrwxrwxrwx 1 root root    0 Mar 15 00:45 subsystem -> ../../../../../../bus/usb
drwxr-xr-x 2 root root    0 Mar 15 00:45 power
-r--r--r-- 1 root root 4.0K Mar 15 00:45 supports_autosuspend
-r--r--r-- 1 root root 4.0K Mar 15 00:45 modalias
drwxr-xr-x 3 root root    0 Mar 15 00:45 ep_82
drwxr-xr-x 3 root root    0 Mar 15 00:45 ep_01
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bNumEndpoints
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bInterfaceSubClass
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bInterfaceProtocol
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bInterfaceClass
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bInterfaceNumber
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bAlternateSetting
drwxr-xr-x 4 root root    0 Mar 15 00:57 ttyUSB1
lrwxrwxrwx 1 root root    0 Mar 15 00:57 driver -> ../../../../../../bus/usb/drivers/option

/sys/bus/usb/devices/1-1/1-1:1.0:
total 0
-rw-r--r-- 1 root root 4.0K Mar 15 00:45 uevent
lrwxrwxrwx 1 root root    0 Mar 15 00:45 subsystem -> ../../../../../../bus/usb
drwxr-xr-x 2 root root    0 Mar 15 00:45 power
-r--r--r-- 1 root root 4.0K Mar 15 00:45 supports_autosuspend
-r--r--r-- 1 root root 4.0K Mar 15 00:45 modalias
drwxr-xr-x 3 root root    0 Mar 15 00:45 ep_81
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bNumEndpoints
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bInterfaceSubClass
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bInterfaceProtocol
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bInterfaceNumber
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bInterfaceClass
-r--r--r-- 1 root root 4.0K Mar 15 00:45 bAlternateSetting
drwxr-xr-x 4 root root    0 Mar 15 00:57 ttyUSB0
lrwxrwxrwx 1 root root    0 Mar 15 00:57 driver -> ../../../../../../bus/usb/drivers/option

Code: Select all

syslog:
Mar 15 00:57:08 kernel: [  836.201074] USB Serial deregistering driver GSM modem (1-port)
Mar 15 00:57:08 kernel: [  836.201622] usbcore: deregistering interface driver option
Mar 15 00:57:08 kernel: [  836.204216] USB Serial deregistering driver generic
Mar 15 00:57:08 kernel: [  836.204651] usbcore: deregistering interface driver usbserial_generic
Mar 15 00:57:08 kernel: [  836.206582] usbcore: deregistering interface driver usbserial
Mar 15 00:57:08 kernel: [  836.631769] usbcore: registered new interface driver usbserial
Mar 15 00:57:08 kernel: [  836.632817] usbcore: registered new interface driver usbserial_generic
Mar 15 00:57:08 kernel: [  836.633878] USB Serial support registered for generic
Mar 15 00:57:08 kernel: [  836.633897] usbserial: USB Serial Driver core
Mar 15 00:57:08 kernel: [  836.638193] usbcore: registered new interface driver option
Mar 15 00:57:08 kernel: [  836.638682] USB Serial support registered for GSM modem (1-port)
Mar 15 00:57:48 kernel: [  876.316959] cdc_ether 1-1:1.0: eth1: unregister 'cdc_ether' usb-0000:00:03.3-1, CDC Ethernet Device
Mar 15 00:57:48 kernel: [  876.945117] usbcore: deregistering interface driver cdc_ether
Mar 15 00:57:49 kernel: [  877.711481] option 1-1:1.0: GSM modem (1-port) converter detected
Mar 15 00:57:49 kernel: [  877.720086] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB0
Mar 15 00:57:49 kernel: [  877.720190] option 1-1:1.1: GSM modem (1-port) converter detected
Mar 15 00:57:49 kernel: [  877.720335] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB1
But, the problem is that sakis hangs at the preparation stage:

Code: Select all

[19852] [00:57:48] [module_loaded       ] Checking if module "cdc_ether" is currently loaded.
[19852] [00:57:48] [module_loaded       ] Module "cdc_ether" is not currently loaded.
[19852] [00:57:49] [verbose             ] Verbosing: 21% Loading driver option
[19852] [00:57:49] [module_loaded       ] Checking if module "option" is currently loaded.
[19852] [00:57:49] [module_loaded       ] Module "option" is currently loaded and occupied.
[19852] [00:57:49] [usb_sysfsdir        ] Device 12d1:14db sysfs dir found: /sys/bus/usb/devices/usb1/1-1
[19852] [00:57:49] [module_bind         ] Module "option" not yet attached to "12d1:14db".
[19852] [00:57:49] [module_bind         ] Sent "12d1 14db" to "/sys/module/option/drivers/usb-serial:option1/new_id".
[19852] [00:57:49] [usb_sysfsdir        ] Device 12d1:14db sysfs dir found: /sys/bus/usb/devices/usb1/1-1
[19852] [00:57:49] [usb_sysfsdir        ] Device 12d1:14db sysfs dir found: /sys/bus/usb/devices/usb1/1-1
[19852] [00:57:50] [module_bind         ] Module "option" attached to device "12d1:14db".
[19852] [00:57:50] [modem_usb_fix_driver] Driver "option" loaded for interface #0 of device "12d1:14db".
[19852] [00:57:50] [verbose             ] Verbosing: 28% Locating tty
[19852] [00:57:50] [usb_sysfsdir        ] Device 12d1:14db sysfs dir found: /sys/bus/usb/devices/usb1/1-1
[19852] [00:57:50] [usb_sysfsdir_int    ] Interface #0 sysfs dir is: /sys/bus/usb/devices/usb1/1-1/1-1:1.0
[19852] [00:57:50] [usb_sysfs_locate_tty] @@@@@@ sysfsintloc=ttyUSB0/tty/ttyUSB0/dev:188:0, [19852] [00:57:50] [usb_sysfs_locate_tty] Interface #0 tty string is: ttyUSB0/tty/ttyUSB0/dev:188:0
[19852] [00:57:50] [usb_sysfs_locate_tty] Will check if "/dev/ttyUSB0" exists, or will create it with major 188 and minor 0.
[19852] [00:57:50] [dev_create_node     ] Device node "/dev/ttyUSB0" already exists.
[19852] [00:57:50] [usb_sysfs_locate_tty] Found tty device node of interface #0 from device "12d1:14db": /dev/ttyUSB0
[19852] [00:57:50] [modem_usb           ] Nothing more to do for setting it up device "12d1:14db".
[19852] [00:57:50] [flow_setup          ] Modem is now setup and resides on /dev/ttyUSB0.
[19852] [00:57:50] [find_binary         ] Unable to locate "wvdial" within PATH.
[19852] [00:57:50] [find_binary         ] Located "pppd" within PATH (/usr/sbin/pppd).
[19852] [00:57:50] [need_arg            ] Loaded default value for PPPD_PEERS: /etc/ppp/peers
[19852] [00:57:50] [find_binary         ] Located "chat" within PATH (/usr/sbin/chat).
[19852] [00:57:51] [verbose             ] Verbosing: 35% Preparing modem
[19852] [00:57:51] [need_arg            ] Loaded default value for CHAT_ABORT_STRINGS: ABORT BUSY ABORT ERROR ABORT BLOCKED ABORT NOCARRIER
[19852] [00:57:51] [at_default_commands ] Unknown command "STAGE0".
[19852] [00:57:51] [at_default_commands ] Command "PROBEGSM" refers to AT commands: ATI OK 'AT+GCAP' OK 'AT+CGSN' OK
[19852] [00:57:51] [tty_send_command    ] Will send PROBEGSM commands to tty /dev/ttyUSB0: "" '\pAT' OK ATI OK 'AT+GCAP' OK 'AT+CGSN' OK '\pAT' OK
[19852] [00:57:51] [we_are_root         ] We are root already. Proceeding.
[19852] [00:57:51] [tty_not_busy        ] Device /dev/ttyUSB0 is not busy.
After killing sakis, I found that two /usr/sbin/chat processes are hanging:

Code: Select all

30239 ?        SN     0:00 sh -c /usr/sbin/chat -t 2 -e ABORT BUSY ABORT ERROR ABORT BLOCKED ABORT NOCARRIER "" '\pAT' OK ATI OK 'AT+GCAP' OK 'AT+CGSN' OK '\pAT' OK >> /dev/ttyUSB0 <
30240 ?        SN     0:00 /usr/sbin/chat -t 2 -e ABORT BUSY ABORT ERROR ABORT BLOCKED ABORT NOCARRIER  \pAT OK ATI OK AT+GCAP OK AT+CGSN OK \pAT OK
What should I try to do now?

LOM
Posts: 1404
Joined: 11 Jul 2012, 15:14
Location: Koh Samui, TH

Re: Huawei E3231 - ttyUSB created, but sakis hangs

Post by LOM » 15 Mar 2013, 15:59

E3231 with the id 12d1:14db is not a serial ppp modem, its interfaces need the usbnet + cdc_ether drivers which will create an ethernet port ( /dev/wwan0 ) in your system.
The option driver is a serial driver and can't use those interfaces and I also doubt that Sakis3G can handle ethernet 3G sticks,
Linux Network Manager can.

shley
Posts: 2
Joined: 15 Mar 2013, 15:12

Re: Huawei E3231 - ttyUSB created, but sakis hangs

Post by shley » 15 Mar 2013, 21:03

I tried installing network-manager, but there are just too many unmet dependencies:

Code: Select all

dpkg-buildpackage: source package network-manager
dpkg-buildpackage: source version 0.9.4.0-10
dpkg-buildpackage: source changed by Michael Biebl <biebl@debian.org>
dpkg-buildpackage: host architecture i386
 dpkg-source --before-build network-manager
dpkg-checkbuilddeps: Unmet build dependencies: intltool libdbus-glib-1-dev (>=0.75)    libdbus-1-dev (>= 1.1) libiw-dev (>=27+28pre9) libglib2.0-dev (>= 2.22) libnl-3-dev libnl-route-3-dev libnl-genl-3-dev ppp-dev (>= 2.4.5) libpolkit-gobject-1-dev libgnutls-dev uuid-dev libudev-dev (>= 147) libgudev-1.0-dev libgirepository1.0-dev (>= 0.10.7-1~) gobject-introspection (>=0.9.12-4~) gtk-doc-tools libglib2.0-doc
dpkg-buildpackage: warning: build dependencies/conflicts unsatisfied; aborting
dpkg-buildpackage: warning: (Use -d flag to override.)
Tried to install it manually using configure;make;make install, got dependency errors there too:

Code: Select all

checking for intltool >= 0.40.0...  found
configure: error: Your intltool is too old.  You need intltool 0.40.0 or later.
Can't use apt-get as I'm not able to connect to the internet on linux yet.

Is there some other software I can use, perhaps something simpler?

hebemiley
Posts: 1
Joined: 06 May 2024, 04:54

Re: Huawei E3231 - ttyUSB created, but sakis hangs

Post by hebemiley » 06 May 2024, 04:57

With Build Now GG , every round is unpredictable and exciting, thanks to the balanced resource allocation.

Post Reply