Automatic Activation, Hotplug and UDEV, Configuration
Post Reply
timtailor
Posts: 4
Joined: 04 Apr 2019, 21:06

E3531 with RPI Zero W and getting the signal strength

Post by timtailor » 04 Apr 2019, 21:16

Hi,

i need to know when my E3531 is ready so that I can start uploading my files. Also I need to know if there is a proper signal so that my raspberry can shut down after a couply of false tries so that the battery dont get wasted.

How can I check if there is a connection and also if the signal is ok or not?

Josh
Site Admin
Posts: 6570
Joined: 03 Nov 2007, 00:30

Re: E3531 with RPI Zero W and getting the signal strength

Post by Josh » 16 Apr 2019, 22:01

Usually, this is done with AT commands at a serial port.

There is often a diagnostic port which can be controlled with AT commands but not connected through. In most setups, you get unsolicited diag info (AT replies that come without being requested).

If you don't get these, you can actively query the state of the connection (on the cell level) and the signal quality.

Example reference (not all commands may be implemented in your modem):
http://download-c.huawei.com/download/d ... adId=51047

Query commands for Huawei are AT^SYSINFO or AT^SYSINFOEX.
AT+CSQ shows the basic signal quality for virtually all modems.

Try talking to a ttyUSB port with "minicom" or annother terminal program.

timtailor
Posts: 4
Joined: 04 Apr 2019, 21:06

Re: E3531 with RPI Zero W and getting the signal strength

Post by timtailor » 28 Apr 2019, 01:11

Thanks,

I couldnt found ttyUSB. Do I need to modify the standard modeswitch procedure? Right now my stick is working after booting up and I can upload and download stuff with it. Do I need to switch to a different mode when using those AT commands?

Josh
Site Admin
Posts: 6570
Joined: 03 Nov 2007, 00:30

Re: E3531 with RPI Zero W and getting the signal strength

Post by Josh » 29 Apr 2019, 19:19

We need to look at the modem configuration after the mode switch.

If you can, post the output of "sudo lsusb -v -d 12d1:" here.
To retain the formatting, post it between "code" tags (see buttons above the posting editor).

timtailor
Posts: 4
Joined: 04 Apr 2019, 21:06

Re: E3531 with RPI Zero W and getting the signal strength

Post by timtailor » 29 Jun 2019, 18:35

Hi Josh,

I unfortunatly missed your reply and got back now on that issue..

Below is the output:

Code: Select all

 sudo lsusb -v -d 12d1:

Bus 001 Device 003: ID 12d1:14dc 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          0x14dc 
  bcdDevice            1.02
  iManufacturer           1 HUAWEI
  iProduct                2 HUAWEI Mobile
  iSerial                 0 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           94
    bNumInterfaces          3
    bConfigurationValue     1
    iConfiguration          0 
    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             10 CDC Ethernet Control Model (ECM)
      CDC Header:
        bcdCDC               1.10
      CDC Union:
        bMasterInterface        0
        bSlaveInterface         1 
      CDC Ethernet:
        iMacAddress                     12 001e101f0000
        bmEthernetStatistics    0x00000000
        wMaxSegmentSize               1514
        wNumberMCFilters            0x0000
        bNumberPowerFilters              0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0010  1x 16 bytes
        bInterval             128
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        1
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass        10 CDC Data
      bInterfaceSubClass      6 
      bInterfaceProtocol      0 
      iInterface             11 CDC Ethernet Data
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x02  EP 2 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               0
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        2
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass         8 Mass Storage
      bInterfaceSubClass      6 SCSI
      bInterfaceProtocol     80 Bulk-Only
      iInterface              4 Mass Storage
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x84  EP 4 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x03  EP 3 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               0
Device Qualifier (for other device speed):
  bLength                10
  bDescriptorType         6
  bcdUSB               2.00
  bDeviceClass            2 Communications
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  bNumConfigurations      1
Device Status:     0x0001
  Self Powered

Josh
Site Admin
Posts: 6570
Joined: 03 Nov 2007, 00:30

Re: E3531 with RPI Zero W and getting the signal strength

Post by Josh » 10 Nov 2019, 15:13

In that mode, there is no serial port available.

You can try the alternative Huawei mode. It's easiest if you edit /etc/usb_modeswitch.conf and add the line:

Code: Select all

HuaweiAltModeGlobal=1

timtailor
Posts: 4
Joined: 04 Apr 2019, 21:06

Re: E3531 with RPI Zero W and getting the signal strength

Post by timtailor » 10 Nov 2019, 15:17

Thanks for your reply! I will try it soon

Post Reply