# [SOLVED] Help for Sierra Wireless UMTS modem configuration

## pigreco

Hello I am in possession of a Flybook I'm trying to run fully with Gentoo; I still miss webcam, UMTS integrated modem, fingerprint and touch screen calibration.

There are currently grappling with the Sierra UMTS modem, the model is SierraMC8775

The kernel appears to be correct and the device detected as shown by the command lsusb-n:

```

Bus 002 Device 002: ID 1199:6812 Sierra Wireless, Inc. MC8775 Device

Device Descriptor:

  bLength                18

  bDescriptorType         1

  bcdUSB               1.10

  bDeviceClass            0 (Defined at Interface level)

  bDeviceSubClass         0 

  bDeviceProtocol         0 

  bMaxPacketSize0        64

  idVendor           0x1199 Sierra Wireless, Inc.

  idProduct          0x6812 MC8775 Device

  bcdDevice            0.01

  iManufacturer           1 Sierra Wireless, Incorporated

  iProduct                2 Mini Card

  iSerial                 0 

  bNumConfigurations      1

  Configuration Descriptor:

    bLength                 9

    bDescriptorType         2

    wTotalLength           67

    bNumInterfaces          1

    bConfigurationValue     1

    iConfiguration          0 

    bmAttributes         0x80

      (Bus Powered)

    MaxPower              500mA

    Interface Descriptor:

      bLength                 9

      bDescriptorType         4

      bInterfaceNumber        0

      bAlternateSetting       0

      bNumEndpoints           7

      bInterfaceClass       255 Vendor Specific Class

      bInterfaceSubClass    255 Vendor Specific Subclass

      bInterfaceProtocol    255 Vendor Specific Protocol

      iInterface              3 Data Interface

      Endpoint Descriptor:

        bLength                 7

        bDescriptorType         5

        bEndpointAddress     0x81  EP 1 IN

        bmAttributes            3

          Transfer Type            Interrupt

          Synch Type               None

          Usage Type               Data

        wMaxPacketSize     0x0010  1x 16 bytes

        bInterval             128

      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

      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     0x04  EP 4 OUT

        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     0x85  EP 5 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     0x05  EP 5 OUT

        bmAttributes            2

          Transfer Type            Bulk

          Synch Type               None

          Usage Type               Data

        wMaxPacketSize     0x0040  1x 64 bytes

        bInterval               0

Device Status:     0x0000

  (Bus Powered)

```

On the Internet you can find much about it but I just can not run the modem, can anyone suggest which software to use, even for kde.

I'm trying with wvdial, but can neither speak whit the modem and I have not a correct configuration.

Thanks in advance regards,

MaurizioLast edited by pigreco on Sun May 22, 2011 4:53 pm; edited 1 time in total

----------

## NeddySeagoon

pigreco,

This page shows you need

```
 USB Sierra Wireless Driver
```

in your kernel.  Read the kernel help too - you may need another kernel option.

With your device plugged in and the kernel module loaded, you should get a /dev/USB...  which is a fake serial port you use to talk to your modem. Many wireless modems provide two serial ports, one is used to get information from the modem.

Point wvdial at the lowest numbered /dev/USB...  and see what happens.

If wvdial is a step too far you should be able to talk to the modem with AT commands from minicom.

You will need to configure minicom to use the modems /dev/USB serial port.

If you sent it AT, it will respond OK.  The modem understands a lot of AT commands. Google Hayes Command Set for some basics.

ATZ is reset. ATDT<number> is use tone dialing to dial <number> ATH0 is hangup, ATH1 is go off hook.

Thats the basics, if you can get OK back from the modem, your kernel is ok too.

----------

## pigreco

Hello,

So you think that a necessary kernel module is not loaded,

 I have searched long and I only found this option:

```

<*> USB-to-WWAN Driver for Sierra Wireless modems

```

should already be present in the kernel I'm using.

I can not find another

----------

## NeddySeagoon

pigreco,

In menuconfig, press / and enter sierra.  I get 

```
  ┌─────────────────────────────── Search Results ────────────────────────────────┐

  │ Symbol: USB_SERIAL_SIERRAWIRELESS [=n]                                        │  

  │ Type  : tristate                                                              │  

  │ Prompt: USB Sierra Wireless Driver                                            │  

  │   Defined at drivers/usb/serial/Kconfig:547                                   │  

  │   Depends on: USB_SUPPORT [=y] && USB_SERIAL [=m]                             │  

  │   Location:                                                                   │  

  │     -> Device Drivers                                                         │  

  │       -> USB support (USB_SUPPORT [=y])                                       │  

  │         -> USB Serial Converter support (USB_SERIAL [=m])                     │  

  │                                                                               │  

  │                                                                               │  

  │ Symbol: USB_SIERRA_NET [=n]                                                   │  

  │ Type  : tristate                                                              │  

  │ Prompt: USB-to-WWAN Driver for Sierra Wireless modems                         │  

  │   Defined at drivers/net/usb/Kconfig:427                                      │  

  │   Depends on: NETDEVICES [=y] && USB [=y] && NET [=y] && USB_USBNET [=n]      │  

  │   Location:                                                                   │  

  │     -> Device Drivers                                                         │  

  │       -> Network device support (NETDEVICES [=y])                             │  

  │         -> USB Network Adapters                                               │  

  │                                    
```

The driver you have seletced appears to be for a USB network card, not a modem.

The kernel hides options if the things they depend on are not selected. The Location tells where to find the option in the kernel menus.

----------

## pigreco

oh!   :Smile: 

thanks, I found it:

```
[   10.328436] sierra 2-2:1.0: Sierra USB modem converter detected

[   10.329481] usb 2-2: Sierra USB modem converter now attached to ttyUSB0

[   10.329629] usb 2-2: Sierra USB modem converter now attached to ttyUSB1

[   10.329767] usb 2-2: Sierra USB modem converter now attached to ttyUSB2

```

but I can not talk:

```

cat /dev/ttyUSB0

echo "ATi^M" > /dev/ttyUSB0

```

I have no answer also trying other commands, any suggestion?  :Smile: 

regards,

Maurizio

----------

## pigreco

probably not have been good with commands to ttyUSB0 because wdialconfig detects the hardware and writes the configuration file

```

Found a modem on /dev/ttyUSB0.

Modem configuration written to /etc/wvdial.conf.

ttyUSB0<Info>: Speed 9600; init "ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0"

ttyUSB2<Info>: Speed 9600; init "ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0"

```

I do not understand why qtwdialer not work, you know any better application for this?

regards maurizio

----------

## NeddySeagoon

pigreco,

You now need to configure wvdial.

Your modem may have a PIN code set, which you need to tell wvdial to send before anything else.

This is normally done with a [pin] block and a [dial] block in wvdial.

Other settings depend on you r ISP or network provider.  My wvdial.conf contains

```
 [Dialer vodaphone]

Modem = /dev/ttyUSB0

Baud = 115200

Init2 = AT+CGDCONT=1,"IP","internet.tele2.se"

Phone = *99#

Username = *

Password = *

New PPPD = yes

Auto DNS = 1

[Dialer pin]

Modem = /dev/ttyUSB0

Baud = 115200

Init1 = AT+CPIN=1234

```

Oh, you will need PPP support in your kernel.  After your modem has dialed and authenticated, the other end will start a PPP session. You need to be able to cope with that.

To talk to the modem yourself, you need minicom, you cannot use echo as there is no way to receive the modems replies.

----------

## pigreco

I think I have support PPP and I was just trying to configure wvdial, but I did not understand how to configure the pin and your suggestion was excellent, this is my conf:

```

[Dialer 3ita]

Init1 = ATZ

Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0

Init3 = AT+CGDCONT=1,"IP","data.tre.it"

Phone = *99#

Modem Type = Analog Modem

Baud = 9600

Modem = /dev/ttyUSB0

ISDN = 0

Username = 0

Password = 0

; Phone = <Target Phone Number>

Carrier Check = on

; Password = <Your Password>

; Username = <Your Login Name>

#your code

[Dialer pin]

Modem = /dev/ttyUSB0

Baud = 9600

Init1 = AT+CPIN=5199

```

I tried various options but I getting always this error:

```
--> Modem initialized.

--> Sending: ATDT*99#

--> Waiting for carrier.

ERROR

```

Maurizio[/code]

----------

## NeddySeagoon

pigreco,

Is you modem a real analogue modem that attaches to the the telephone system or is it a mibole phone in a USB stick providing a data connection over the mobile phone network?

If its a real analogue modem, you will need a real telephone number to reach your ISP

If it provides a connection over the mobile phone network, you may need to replace *99# with what your carrier expects.

```
--> Waiting for carrier.
```

is a good sign. It appears to have dialed but not got an answer.

Maybe the real modem is in one of the other USB serial ports?

------------ Edit -------------

Google tells me its a GSM modem, which uses the mobile telephone network.  There is also some suggestions that the modem is on /dev/ttyUSB1.

----------

## pigreco

thanks for reply,

my modem is internal module with sim, therefore you consider that it must insert an other number of telephone? , of it I do not find others in network....

My sim card have the active PIN, that I would want to maintain if possible, considers that it can be that the problem? it wouldn't have to supply an other kind of error message?

I have tried to supply also the PIN but I obtain this answer:

```

--> Sending: AT+CPIN="5199"

ERROR

```

it isn't corrected?

----------

## pigreco

I have try with PIN disabled and works:

```

--> WvDial: Internet dialer version 1.61

--> Cannot get information for serial port.

--> Initializing modem.

--> Sending: ATZ

OK

--> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0

OK

--> Sending: AT+CGDCONT=1,"IP","data.tre.it",,0,0

OK

--> Modem initialized.

--> Sending: ATDT*99#

--> Waiting for carrier.

CONNECT

--> Carrier detected.  Starting PPP immediately.

--> Starting pppd at Tue Mar 27 02:02:59 2007

--> Pid of pppd: 5425

--> Using interface ppp0

--> Disconnecting at Tue Mar 27 02:03:01 2007

--> The PPP daemon has died: A modem hung up the phone (exit code = 16)

--> man pppd explains pppd error codes in more detail.

--> Try again and look into /var/log/messages and the wvdial and pppd man pages for more information.

```

dmesg

 *Quote:*   

> 
> 
> Mar 27 02:01:34 COMETA pppd[5419]: pppd 2.4.4 started by root, uid 0
> 
> Mar 27 02:01:34 COMETA pppd[5419]: Using interface ppp0
> ...

 

----------

## NeddySeagoon

pigreco,

That all looks good.  

Your ppp0 should have had an IP address, ppp0 should have appeared in your routing table and /etc/resolv.conf should have had some nameservers for it too.

You need to test will all other networking stopped, as routing will get in a mess if you have more than one default route.

----------- edit ------------

```
Disconnecting at Tue Mar 27 02:03:01 2007
```

You need to fix your clock

----------

## pigreco

yes I have problems with the battery for the clock, thanks,

I have tried pppdconfig, I do not know has been a good choice, I do not know the use of pppd and I do not find the generated configuration file, now wvdial says:

```

--> WvDial: Internet dialer version 1.61

--> Cannot get information for serial port.

--> Initializing modem.

--> Sending: ATZ

OK

--> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0

OK

--> Sending: AT+CGDCONT=1,"IP","data.tre.it",,0,0

OK

--> Modem initialized.

--> Sending: ATDT*99#

--> Waiting for carrier.

CONNECT

--> Carrier detected.  Starting PPP immediately.

--> Starting pppd at Sun May 22 14:40:24 2011

--> Pid of pppd: 7270

--> Using interface ppp0

--> Disconnecting at Sun May 22 14:40:24 2011

--> The PPP daemon has died: A modem hung up the phone (exit code = 16)

--> man pppd explains pppd error codes in more detail.

--> Try again and look into /var/log/messages and the wvdial and pppd man pages for more information.

```

----------

## NeddySeagoon

pigreco,

Use wgetpaste to put your kernel .config file onto a pastebin and post the URL. 

I have never used pppdconfig.  My mobile phone modem just worked once I could get as far as ppp0 starting.

----------

## pigreco

here my .config file:

[url]

http://paste.pocoo.org/show/393112/

[/url]

----------

## NeddySeagoon

pigreco, 

Your PPP setup in the kernel is ok.  You have a few extra options that you won't use but they are all harmless.

Fix your clock - something at the back of my mind says taht IP packets are timestamped. Your mobile phone provider may not like getting 4 year old packets.

For testing, use anther form of networking ans set up ntpd.  The ntp-client part will do.

That sets your time to time from a timeserver on the internet.  Without switching off, put the networking down, then try your modem again.

Time will be good to within a fraction of a second.

----------

## pigreco

thanks for reply, the clock fix don't resolve, I have made some tests and I have however this output;

```
--> Pid of pppd: 25454

--> Using interface ppp0

--> pppd: [10]

--> pppd: [10]

--> pppd: [10]

--> pppd: [10]

--> pppd: [10]

--> pppd: [10]

--> Disconnecting at Sun May 22 18:00:45 2011

--> The PPP daemon has died: A modem hung up the phone (exit code = 16)

--> man pppd explains pppd error codes in more detail.

--> Try again and look into /var/log/messages and the wvdial and pppd man pages for more information.

```

----------

## pigreco

ok!!1 I'am online, the last problem was caused by the APN that is changed  :Smile: 

a last question: do you think possible to use the commando for the PIN?

Thank you very much for all the aid, best regards,

Maurizio

----------

## pigreco

hi again,

still a small problem the file resolv.conf is emptied, is a problem of wvdial or the demon pppd?

regards,

MaurizioLast edited by pigreco on Sun May 22, 2011 5:37 pm; edited 2 times in total

----------

## NeddySeagoon

pigreco,

What do you have in your /etc/conf.d/net file for the ppp0 interface?

Provided you have dhcpcd installed and no exceptions for ppp0 in the net file, when ppp0 starts, dhcpcd will run and populate /etc/resolv.conf

You can use the command for the PIN but I have no idea how you set a PIN in the first place. Maybe put the SIM in a mobile phone?

I don't use a PIN as my USB 3G stick is Pay As You Go. At £15 for 1Gb that never expires.  The most I could lose is £15.

----------

## pigreco

I' have nothing in etc/conf.d/net for ppp0 interface, I have added

```

config_ppp0=( "dhcp" )

```

is it correct?

how used wvdial from user not is root?

```

 wvdial

--> WvDial: Internet dialer version 1.61

--> Cannot open /dev/modem: No such file or directory

--> Cannot open /dev/modem: No such file or directory

--> Cannot open /dev/modem: No such file or directory

```

----------

