Page 7 of 8 FirstFirst ... 5678 LastLast
Results 61 to 70 of 80

Thread: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

  1. #61
    Join Date
    Oct 2009
    Location
    A world without windows
    Beans
    Hidden!

    Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    The script With reference to post: oPost #2

    Requires package TCL

    The tcl package is not part of Ubuntu 11.10 . What can you do Look here #30 .. may be wise to keep a copy on usb stick

    script name eject.tcl or what ever you want to call it. after saving the file in /home/file set the Execute bit in the properties
    use from the terminal
    ./scriptname argv

    Remember the eject command is useless if the device is configured use the argv "tty" to find device details

    there are no traps in some parts of the script so ensure run from the terminal , it will just but out if error , but do not try to modify the script unless you know
    how to catch errors

    Usage: to find ejectable usb modem

    suggest: "eject rule" or usb_modeswitch rule
    eject: "device" will list new ids if found "only if the SR changes to SD ; hint on this one if the device switches and the device has both SD* and SR* and is unstable
    can try and safely remove the SR bit check with the Disk Utility

    check: "tty* exits" in dev/serial/by-id + list all possible udev rules

    list: the usb_modeswitch device database

    connect the device and only 1 device , wait a few moments to all the system to settle

    follow these commands , Remember to change the "./script" to your script name

    List the device ; the script may crash at this point if already switched , or if the system not settled , have kept the script short as possible by ommitting traps
    Code:
    ./script eject sr
    List possible eject rule and usb_modeswitch rule > Please refer the usb_modswitch forum if device not switching or read Posts #60 and #59
    Code:
    ./script eject sr 1
    Try to eject the device and search for any changes in the SD* ID's if found just look at the list if happy
    try to list the device tty*
    Code:
    ./script eject sr 2
    search /dev/serial/by-id/*
    Check the tty status and AT command response + list the rules available to udev , may help to write your own rules
    Code:
    ./script tty
    the tty command is usefull if find the likes of wvdial and ppp gammu cant find the port ,,IE the device may show different tty* make your own rules to suit , RE: post Post #2

    List usb_modeswitch database on 11.04 and possible 11.10
    Code:
    ./script database
    if the device is in the database and not switching see post #60

    After running the argv tty, take time to look through all the data of udev and also note the modem status and the response to AT command: it may help to find what a particular port is for.

    ADDED: TIP: look at
    Code:
     ATTRS{bNumEndpoints}=="*"
      ATTRS{bInterfaceClass}=="*"
      ATTRS{bInterfaceSubClass}=="*"
      ATTRS{bInterfaceProtocol}=="*"
    Code:
    #!/bin/sh
    # the next line restarts using tclsh \
    exec tclsh "$0" "$@"
    ##################################################
    # Some of vars are not what they seem esp $tty.
    
    proc udevadm-tty {bit} {
        if { [catch {set udevadm_tty [exec udevadm info -a path -n /dev/$bit]} fid] } {
            puts $fid
            return
        } else {
            puts "$udevadm_tty\n"
            }
            unset udevadm_tty
        return
    }
    ###########################################################################
    proc ttys {} {
    set dolist 1
        if { [catch {set List [exec ls -l /dev/serial/by-id]} fid] } {
            puts "$fid\n"
            return
        } else {
            puts "/dev/serial/by-id:\n\n$List\n"
            }
        #########################
        # parse device : ttys
        if {$dolist == 1} {
            set len [llength $List]
        foreach bit $List {
            set usb [string first {usb} $bit]
                if {$usb > -1} {
                    puts "--------- Udevadm device info-------\n\n"
                    puts "--$bit: "
                }
    
            set tty [string first {tty} $bit]
                if {$tty > -1} {
                set bit [string range $bit $tty end]
                set udevtty "/dev/$bit"
                #puts "$udevtty\n"
    #TODO  get the serial info here
        tty_status $udevtty
    ##########################
                udevadm-tty $bit
    
                }
        }
     }
    }
    ###########################
     proc tty_status {tty} {
        set tty [string trim $tty]
        set isdev [string first /dev/tty $tty]
            if {$isdev  > -1} {set tty $tty}
            if {$isdev == -1} {set tty "/dev/$tty"}    
        if { [catch {set serial [open $tty RDWR]} fid] } {
               puts  "\n$tty : $fid \n"
            return
        } else {
        ##################################################
        # set the port to stnd 115200 buffering DTR 1
        ##################################################
        fconfigure $serial -mode "115200,n,8,1"
        fconfigure $serial -blocking 0 -buffering full -ttycontrol {RTS 0 DTR 1}
        after 500
        set data [fconfigure $serial -ttystatus]
        puts "$tty : Status : $data"
            puts $serial "AT"
            after 100
            flush $serial
            after 100
            set data6 [read $serial]
            puts "AT$data6"
        
        close $serial}
    return
    }
    #################################################
    proc udevadm-sr {bit  bNumInterfaces ejects} {
    set bit "/dev/$bit"  
        if { [catch {set udevadm_sr [exec udevadm info -a path -n $bit]} fid] } {
            puts $fid
            return
        } else {
            set idvendor "ATTRS{idVendor}=="
            set idproduct "ATTRS{idProduct}=="
            set manufacturer "ATTRS{manufacturer}=="
            set cmds [split $udevadm_sr "\n"]
            foreach cmd $cmds {
                set cmd [string trim $cmd]
    ######################################################
            set check [string first $manufacturer $cmd]
                if {$check > -1} {
                 set global manufacturers
                    set manufacturers $cmd
                   puts $manufacturers
                    puts ""
                global usb_ids
                set usb_ids $usb_id
        
                return $usb_ids
                }
    ######################################################
            set vendor [string first $idvendor $cmd]
                if {$vendor > -1} {
                 set global vendors
                    set vendors $cmd
                    set cut {"}
                    set idvend [split $vendors $cut]
                        set idvend [lindex $idvend 1]
                }
    #####################################################
            set product [string first $idproduct $cmd]
                if {$product > -1} {
                 set global products
                    set global usbid
                    set products $cmd
                    set cut {"}
                    set idprod [split $products $cut]
                    set idprod [lindex $idprod 1]
                    #puts $idprod
    ##################################################SET THE REAL USB ID
                    set global usb_id
                    set usb_id "$idvend:$idprod"
                    puts $usb_id                
    ##################################################
                    set usbid "$vendors,$products"
                    puts "Device: $usb_id"
                    if {$ejects == 1} {
                    puts "Trap2 $usb_id"
                    lsusb_driver $usb_id
                    set ejectrule  {RUN+="/usr/bin/eject %k", OPTIONS+="last_rule"}
                    set ejectrule "$usbid,$ejectrule"
                    puts "eject rule :"
                    puts "$ejectrule\n"
    #TODO  SORT THE VARS IE MODESWITCH RULE ETC THESE ARE HASHED OUT
                    set global modeswitchrule
                    set modeswitchrule {RUN+="usb_modeswitch '%b/%k'"}
                    set modeswitchrule "$usbid,$modeswitchrule"
                    puts "usb_modeswitch.d rule :" 
                    puts "$modeswitchrule\n"
    #TODO NOTE this should be in latest version of usb_modeswith
    #set optiondriverbind {ATTR{bInterfaceClass}=="ff", ATTR{bInterfaceNumber}=="00", ATTRS{bNumConfigurations}=="*", RUN+="usb_modeswitch --driver-bind %p %s{idVendor} %s{idProduct} %E{PRODUCT}"}
                    }
                }
    ####################################################
                set ejectmsg "not ejectable"
                if {$bNumInterfaces == $cmd} {
                    puts "ejectable or remove device $bit"
                    if {$ejects == 1} {
                    }
    
                    if {$ejects == 2} {
    
                    set eject [exec udisks --eject $bit]
                    puts "device $bit ejected"
                    }
                   # This function disabled but can use the Disk Utility to safely unmount  part of a unstable device 
                   # if {$ejects == 3} {
    
                   # set eject [exec udisks --unmount $bit]
                   # puts "unmount: $bit "
                   # }
    ################ now check for the device ID  change and changes in configs could be sd* *=alphabetical
                }                
            }
    
            }
            unset udevadm_sr
        return
    }
    proc eject_sr { find ejects } {
    # set all the rules to look for
    #TODO not all is used in this version
    set bNumInterfaces "ATTRS{bNumInterfaces}=="
    set idvendor "ATTRS{idVendor}=="
    set idproduct "ATTRS{idProduct}=="
    set bnum {" 1"}
    set bNumInterfaces "$bNumInterfaces$bnum"
    set dolist 1
        if { [catch {set List [exec ls -l /dev/disk/by-id]} fid] } {
            puts "$fid\n"
            return
        } else {
            }
        #########################
        # parse device : sr* or sd*
        if {$dolist == 1} {
            set len [llength $List]
        foreach bit $List {
            set usb [string first {usb} $bit]
                if {$usb > -1} {
                }
    ################## need argv at first line #################### sr* or sd*
            set srbit [string first $find $bit]
                if {$srbit > -1} {
                set bit [string range $bit $srbit end]
                set udevsrbit "/dev/$bit"
                udevadm-sr $bit $bNumInterfaces $ejects
                }
        }
      }
    }
    #################################################
    
    proc lsusb_driver {usb_ids} {
      if { [catch {set List [exec lsusb -t -d $usb_ids ]} fid] } {
            puts "Device: $usb_ids :ERR :Driver missing\n"
            set List $fid
            set t 0
            set found 0
            foreach inlist $List {
                incr t
               set check [string first "If" $inlist]
                if {$check > -1} {
                set inlist [string trim $inlist ","]
                set found 1
                }
                if {$found == 1} {
                set check [string first "Driver" $inlist]
                if {$check > -1} {
                set inlist [string trim $inlist ","]
                if {$inlist == "Driver="} {
                    puts "$inlist None"
                    } else {
                        puts $inlist
                        }
                }
               }
             }
    
            return
        } else {
            set t 0
            set found 0
            foreach inlist $List {
                incr t
               set check [string first "If" $inlist]
                if {$check > -1} {
                set inlist [string trim $inlist ","]
                set found 1
                }
                if {$found == 1} {
    
               set check [string first "Driver" $inlist]
                if {$check > -1} {
                set inlist [string trim $inlist ","]
                puts $inlist
                }
                }
            }
            }
    return
    }
    proc database {} {
    set List [exec tar ft /usr/share/usb_modeswitch/configPack.tar.gz]
    puts $List
    }
    ####################################################
    #MAIN
    ###################################################
    set buff [lindex $argv 0]
    if {$buff == "eject"} {
            set find [lindex $argv 1]
            set ejects [lindex $argv 2]
           # puts $ejects
            eject_sr  $find $ejects
            puts $usb_ids
            if {$ejects == 2} {
                set ejects ""
                set find "sd"
                after 10000
                eject_sr  $find $ejects
                puts "Wait"
                after 3000
                lsusb_driver $usb_ids
            }
        }
    
    if {$buff == "database"} {
            database        
        }
    if {$buff == "tty"} {
            ttys    
        }
    #END
    The device Not Switching from The eject command ,+ device not in the Usb_Modeswitch data base , Obvious , Visit USB MODESWITCH FORUM

    If have a device with Net interface IE ;
    The driver shows up as something like cdc-ether then can use a rule to bring up the interface , find by looking through the data of the argv "tty" ; remember to change the ***** for your device id's
    look at posts #59 and #60 then come back + Continue Reading the rest of this thead ,
    Yes I know this Thread is Long , But EACH device is different


    Code:
    ACTION=="add", SUBSYSTEM=="net", ATTRS{idVendor}=="****", ATTRS{idProduct}=="****", RUN="/sbin/ifconfig %k -arp"
    Example:
    ACTION=="add", SUBSYSTEM=="net", ATTRS{idVendor}=="19d2", ATTRS{idProduct}=="1003", RUN="/sbin/ifconfig %k -arp"
    Here is a link to Linux Cross Reference : it will take to usb net drivers . its worth looking at ; Notice the Kernel version :
    http://lxr.linux.no/#linux+v2.6.38/drivers/net/usb

    for other drivers
    serial
    class

    need to know kernel version can look in the outputs of the "./script tty"
    or
    Code:
    uname -a
    ADDED FOR FUN:

    if wondering why your at this POST

    these devices are http://www.thefreedictionary.com/ad+infinitum

    best do that link with Ubuntu or ANY other Linux Distro
    Last edited by alexfish; April 26th, 2012 at 12:18 PM. Reason: need new keyboard , going back to my xwing these new one don't last
    Two tin cans are better than an iphone

    http://www.ehow.co.uk/how_2067160_ma...hone.html?cr=1

  2. #62
    Join Date
    Oct 2009
    Location
    A world without windows
    Beans
    Hidden!

    Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    MM-Dbus-Test:

    A bash script using the dbus-send to communicate with modem-manager
    similar to the mm-test.py (yes I know python is easier) who said that

    What is different about this script :
    if 3g device, mayshould show MCC and MNC codes , (read through post #1) , if CDMA may reveal SID ,
    so can look up the serviceproviders data base (read through post #1)

    should also show which method is used to connect IE: (PPP , DHCP , Static )

    Dependencies :"dbus-send" : "modem-manager" , check to see if on system but should work with latest Ubuntu supported distro's.

    ADDED: if have configuration problems, : IE the modem-manager hanging onto the device or device hanging after a disconnection, initially this script tests for a device enabled status at start ,
    when a status of device enabled = true , the script will request a disable false ; then request enable true ; result = enabled , end of script does enabled false, the device should then connect with NM.
    The script will also indicate if enable flag {fail}: This is shown sequentially at the beginning of the outputs , and at the end of the outputs.
    If modem-manager is failing to detect the device or can't do the enable flag , test the device with the script given at post #61, using the arg TTY, if detected . report bugs to launch pad.

    Where is the best place for the script
    Suggest home directory
    Save the file as "mm-dbus-test" or other.
    Once Saved.
    Right click on the file and check the Properties , Permissions , and check the Execute.
    Call from the terminal
    Code:
    ./mm-dbus-test
    Code:
    #!/bin/bash
    
    ########################################################################
    # This program is free software; you can redistribute it and/or modify
    # it under the terms of the GNU General Public License as published by 
    # the Free Software Foundation; either version 2 of the License, or   
    # (at your option) any later version.                                  
    #                                                                      
    # This program is distributed in the hope that it will be useful,      
    # but WITHOUT ANY WARRANTY; without even the implied warranty of      
    # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        
    # GNU General Public License for more details:                        
    ########################################################################
    # cisabfone-MM-Dbus-Test (0.1.b)                                      
    #  (0.1.b) added CDMA support (untested)                                  
    # Copywrite (C) cisabfone@gmail.com                                       
    # BUGS and ALL : ah.cisab@gmail.com                                       
    ########################################################################
    
    INTERFACE_PROPERTIES="org.freedesktop.DBus.Properties"
    MM_DBUS_SERVICE="org.freedesktop.ModemManager"
    DBUS_PATH="/org/freedesktop/ModemManager"
    DBUS_INTERFACE="org.freedesktop.ModemManager"
    MODEM="org.freedesktop.ModemManager.Modem"
    MODEM_CDMA="org.freedesktop.ModemManager.Modem.Cdma"
    GSM_CARD="org.freedesktop.ModemManager.Modem.Gsm.Card"
    GSM_NETWORK="org.freedesktop.ModemManager.Modem.Gsm.Network"
    MODEM_SIMPLE="org.freedesktop.ModemManager.Modem.Simple"
    MM="org.freedesktop.ModemManager"
    GET_INFO="org.freedesktop.ModemManager.Modem.GetInfo"
    GSM_NETWORK_SCAN="org.freedesktop.ModemManager.Modem.Gsm.Network.Scan" 
    GSM_NETWORK_REG_INFO="org.freedesktop.ModemManager.Modem.Gsm.Network.GetRegistrationInfo"
    MODEM_ENABLE="org.freedesktop.ModemManager.Modem.Enable"
    Get_Esn="org.freedesktop.ModemManager.Modem.Cdma.GetEsn"
    Get_Serving_System="org.freedesktop.ModemManager.Modem.Cdma.GetServingSystem"
    Get_Registration_State="org.freedesktop.ModemManager.Modem.Cdma.GetRegistrationState"
    ###############################################################
    
    ################################################################
    MM_ENUM=$(dbus-send --print-reply --system --dest=$MM \
        $DBUS_PATH $MM.EnumerateDevices |grep org | cut -c19-)
    #################################################################
    #***************** MAIN_LOOP_START + SET COUNTER  0 *************
    #################################################################
    COUNT=0
    for DEV in $MM_ENUM
    do
        COUNT=`expr $COUNT + 1`
        DEV=$(echo $DEV |sed s:\"::g)
        MM_DEVICE_INFO=$(dbus-send --print-reply --system --dest=$MM $DEV $GET_INFO |grep string | cut -c14-)
        MM_DEVICE_INFO=$(echo $MM_DEVICE_INFO |sed s:\"::g)
        MM_DEVICE_TYPE=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"Type" |tail -n1|cut -c25-)
        MM_DEVICE_DRIVER=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"Driver" |tail -n1|cut -c25-)
        MM_DEVICE_DRIVER=$(echo $MM_DEVICE_DRIVER |sed s:\"::g)
        MM_DEVICE_MASTER=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"MasterDevice" |tail -n1|cut -c25-)
        MM_DEVICE_MASTER=$(echo $MM_DEVICE_MASTER |sed s:\"::g)
        MM_DATA_DEVICE=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"Device" |tail -n1|cut -c25-)
        MM_DATA_DEVICE=$(echo $MM_DATA_DEVICE |sed s:\"::g)
        MM_DATA_DEVICE_PIN_STAT=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"UnlockRequired" |tail -n1|cut -c25-)
        MM_DATA_DEVICE_IP=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"IpMethod" |tail -n1|cut -c25-)
        MM_DATA_DEVICE_ENABLED=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"Enabled" |tail -n1|cut -c25-)
    #########################################################################
    # Need to see if device Enabled from MM_DATA_DEVICE_ENABLED true or false
    # if false enable the device : else network info not available : WARNING :If connect by Network-Manager this will drop the connection
    #########################################################################
        echo
        echo " ----*-----* MM-TEST DEVICE_ENABLE_DISABLE *-----*----"
        echo
        if [ $MM_DATA_DEVICE_ENABLED = "true" ]
        then
        echo " DEVICE ENABLED : true"
        echo " ACTION :disconnect"
        MM_DEVICE_ENABLE=$(dbus-send --print-reply --system --dest=$MM $DEV $MODEM_ENABLE boolean:false)
        MM_DATA_DEVICE_ENABLED=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"Enabled" |tail -n1|cut -c25-)
        fi
    ################################################
        if [ $MM_DATA_DEVICE_ENABLED = "false" ]
        then
        echo " DEVICE ENABLED : false"
        echo " ACTION :enable"
        true = "(True)"
        MM_DEVICE_ENABLE=$(dbus-send --print-reply --system --dest=$MM $DEV $MODEM_ENABLE boolean:true)
        MM_DATA_DEVICE_ENABLED=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"Enabled" |tail -n1|cut -c25-)
        echo " DEVICE ENABLE :$MM_DATA_DEVICE_ENABLED"
        fi
        if [ $MM_DATA_DEVICE_ENABLED = "false" ]
        then
        echo " SETTING ENABLE_DEVICE : fail"
        fi
    ###################################################
        echo
        echo " ----*-----* MM-TEST DEVICE_INFO *-----*----"
        echo
        echo " DEVICE :$COUNT"
        echo " MASTER_DEVICE :$MM_DEVICE_MASTER"
        echo " ENUMERATED DEVICE TYPE :$MM_DEVICE_TYPE"
        echo " DEVICE INFO :$MM_DEVICE_INFO"
    ##################################################
        if [ $MM_DEVICE_TYPE -eq 1 ]    
        then
        MODEM_TYPE="GSM"
        echo " MODEM TYPE :$MODEM_TYPE"
        dial="*99#"
        echo " DIAL COMMAND :$dial"
        MM_GSM_NETWORK_INFO=$(dbus-send --print-reply --system --dest=$MM $DEV $GSM_NETWORK_REG_INFO |grep string | cut -c14-)
        MM_GSM_NETWORK_INFO=$(echo $MM_GSM_NETWORK_INFO |sed s:\"::g)
        data=0
        for INFO in $MM_GSM_NETWORK_INFO
            do
                if [ $data -eq 0 ]
                    then
                    MCC=$(echo $INFO | cut -c -3)
                    MNC=$(echo $INFO | cut -c 4-)
                    echo " NETWORK MCC :$MCC"
                    echo " NETWORK MNC :$MNC"
                fi
    ##########################################
                if [ $data -eq 1 ]
                    then
                    echo " PROVIDER   :$INFO"
                fi
    ##########################################
                if [ $data -eq 2 ]
                    then
                    echo " REGISTERED :$INFO"
                fi
    ##########################################
            data=`expr $data + 1`
            done
            echo
        fi
    ##################################################
        if [ $MM_DEVICE_TYPE -eq 2 ]
            then
            MODEM_TYPE="CDMA"
    ######### UNTESTED ##############################################
            echo " MODEM TYPE :$MODEM_TYPE"
            dial="#777"
            echo " DIAL COMMAND :$dial"
            MM_DEVICE_ESN=$(dbus-send --print-reply --system --dest=$MM $DEV $Get_Esn)
            echo $MM_DEVICE_ESN
            MM_DEVICE_SERVING_SYSTEM=$(dbus-send --print-reply --system --dest=$MM $DEV $Get_Serving_System |grep uint | cut -c14-) # 
            for INFO in $MM_DEVICE_SERVING_SYSTEM
                do
                echo $INFO
            done
    
            echo
        fi
    ##################################################
        echo " ----*-----* MM-TEST MM-INFO *-----*-----"
        echo
        echo " DRIVER :$MM_DEVICE_DRIVER"
        echo " DEVICE :/dev/$MM_DATA_DEVICE"
        echo " PIN STATUS :$MM_DATA_DEVICE_PIN_STAT"
    ##################################################
        if [ $MM_DATA_DEVICE_IP -eq 0 ]
            then
            echo " ENUMERATED IP METHOD :Use PPP to get the address."
        fi
    ##################################################
        if [ $MM_DATA_DEVICE_IP -eq 1 ]
            then
            echo " ENUMERATED IP METHOD :Static configuration, the modem will provide IP information."
        fi
    ##################################################
        if [ $MM_DATA_DEVICE_IP -eq 2 ]
            then
            echo " ENUMERATED IP METHOD :Use DHCP."
        fi
    ############## END OF UNTESTED ######################### show true then set false
        echo " DEVICE ENABLED :$MM_DATA_DEVICE_ENABLED"
        echo " ACTION :disconnect"
        MM_DEVICE_ENABLE=$(dbus-send --print-reply --system --dest=$MM $DEV $MODEM_ENABLE boolean:false)
        MM_DATA_DEVICE_ENABLED=$(dbus-send --print-reply --system --dest=$MM $DEV $INTERFACE_PROPERTIES.Get string:$MODEM string:"Enabled" |tail -n1|cut -c25-)
        echo " DEVICE ENABLE :$MM_DATA_DEVICE_ENABLED"
    ###################################################
        echo
        echo
    done
    #***************** MAIN_LOOP_END ************************
    Last edited by alexfish; March 18th, 2012 at 08:07 PM. Reason: Typo in code
    Two tin cans are better than an iphone

    http://www.ehow.co.uk/how_2067160_ma...hone.html?cr=1

  3. #63
    Join Date
    Jan 2012
    Beans
    1

    Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    Hi all. I decided to try ubuntu and following the instructions downloaded 11.10, created a USB pen and booted my hp laptop from there. When I tried my ZTE K3765-Z vodafone broadband pen to connect to the internet, ubuntu recognized the device, installed drivers, asked for the ZTE PIN and the pen changed the led color to intermittent dark blue, which is the normal behavior. The problem is that the final step, which is closing the connection doesn't happen. Any suggestions or recommendations? Thanks

    SOLVED
    I had just to do some configuration using the networking window
    Last edited by rmmb; January 5th, 2012 at 11:11 PM.

  4. #64
    Join Date
    Oct 2009
    Location
    A world without windows
    Beans
    Hidden!

    Question Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    This is for Huawei Devices , Next generation

    If only want to install drivers Look Here Post #75

    it will also depend on your kernel version , this Ubuntu 10.10

    Here the device has switched (using ealier versions of usb modeswitch ) outputs from the usb-devices command notice the Cls, Sub and prot / normal 3g these would be ff, ff, ff

    Switched from 1446 to
    Code:
    P:  Vendor=12d1 ProdID=1506 Rev=00.00
    S:  Manufacturer=Huawei Technologies
    S:  Product=HUAWEI Mobile
    C:  #Ifs= 7 Cfg#= 1 Atr=c0 MxPwr=500mA
    I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
    I:  If#= 1 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=01 Prot=09 Driver=(none)
    I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=08 Driver=(none)
    I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=03 Driver=(none)
    I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=02 Driver=(none)
    I:  If#= 5 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
    I:  If#= 6 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
    normal user would not think of using the option module
    when in this state try and use Sakis3g to configure the modem,
    Below are the Results
    Code:
    I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=option
    I:  If#= 1 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=01 Prot=09 Driver=option
    I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=08 Driver=option
    I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=03 Driver=option
    I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=02 Driver=option
    I:  If#= 5 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
    I:  If#= 6 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
    the device now recognised in Network Manager

    in Ubuntu 11.04 you may only see One part of the device with the Option Driver
    Here again try setting up the device with Sakis3g. if NM will not connect

    Can see if these drivers are on the system cdc_wdm and qmi_wwan , they may also work also keep a watch here http://www.draisberghof.de/usb_modeswitch/bb/
    Have checked in Ubuntu 11.04 cdc_wdm does exist , ensure your system is up to date...Updating Post # 60 accordingly

    if have Drivers installed from Huawei links , then the device will configure as close as the device needs to be IE , if the device has 3 modes then you will see three modes ,
    if it has two modes you will see two modes , But the device may not be recognised by modem-manager , hence Network manager will not see the device. here again you can
    use Sakis3g to get connected

    here are the results of Ubuntu 11.04 with thr Huawei drivers
    Code:
    P:  Vendor=12d1 ProdID=1506 Rev=00.00
    S:  Manufacturer=Huawei Technologies
    S:  Product=HUAWEI Mobile
    C:  #Ifs= 7 Cfg#= 1 Atr=c0 MxPwr=500mA
    I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=option
    I:  If#= 1 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=01 Prot=09 Driver=huawei_ether
    I:  If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=08 Driver=huawei_ether
    I:  If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=03 Driver=option
    I:  If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=02 Driver=option
    I:  If#= 5 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
    I:  If#= 6 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
    here ar the results of nm-tool
    Code:
    - Device: eth1 -----------------------------------------------------------------
      Type:              Wired
      Driver:            huawei_ether
      State:             unavailable
      Default:           no
      HW Address:        00:1E:10:1F:00:01
    
      Capabilities:
        Carrier Detect:  yes
    
      Wired Properties
        Carrier:         off
    as you can see the 3g device is not seen, so if the ether interface is not configured you can't connect
    if the device has WiFi then it may connect. As for getting 3g connection , suggest using Sakis3g for ease of use , or ppp
    have posted plenty on this thread , on different methods of getting connect.

    Also note you can install the Huawei driver to allow third party access to the device + Switch logging Off , if Logging Stuck in Loop ,read the info and files ,supplied.
    The modinfo
    Code:
    ~$ modinfo hw_cdc_driver
    filename:       /lib/modules/2.6.38-13-generic/kernel/drivers/net/usb/hw_cdc_driver.ko
    license:        GPL
    version:        v2.07.00.00
    description:    Huawei ether driver for 3G data card ether device
    author:         Franko Fang <huananhu@huawei.com>
    srcversion:     866E62C8BF6445AE87CF101
    alias:          usb:v12D1p*d*dc*dsc*dp*ic02isc0Dip00*
    alias:          usb:v12D1p*d*dc*dsc*dp*ic02isc0DipFF*
    alias:          usb:v12D1p*d*dc*dsc*dp*icFFisc02ip46*
    alias:          usb:v12D1p*d*dc*dsc*dp*icFFisc02ip16*
    alias:          usb:v12D1p*d*dc*dsc*dp*icFFisc02ip37*
    alias:          usb:v12D1p*d*dc*dsc*dp*icFFisc02ip07*
    alias:          usb:v12D1p*d*dc*dsc*dp*icFFisc01ip39*
    alias:          usb:v12D1p*d*dc*dsc*dp*icFFisc01ip09*
    alias:          usb:v12D1p*d*dc*dsc*dp*ic02isc06ipFF*
    alias:          usb:v12D1p*d*dc*dsc*dp*ic02isc06ip00*
    depends:        
    vermagic:       2.6.38-13-generic SMP mod_unload modversions 686 
    parm:           msg_level:Override default message level (int)
    parm:           ncm_prefer_32:bool
    parm:           ncm_prefer_crc:bool
    parm:           ncm_tx_timeout:ulong
    parm:           ncm_read_buf_count:uint
    parm:           ncm_read_size_in1k:short
    parm:           rt_debug:bool
    from the
    Code:
    ls -al /dev/serial/by-id
    Code:
    lrwxrwxrwx 1 root root  23 2012-02-22 22:35 usb-Huawei_Technologies_HUAWEI_Mobile-if00-port0 -> ../../ttyUSB_utps_modem < as it say's the modem do not connect both 3g and DHCP
    lrwxrwxrwx 1 root root  22 2012-02-22 22:35 usb-Huawei_Technologies_HUAWEI_Mobile-if03-port0 -> ../../ttyUSB_utps_diag  < this is the control port for the  commands IE  for setting device and getting other data while connected ??
    lrwxrwxrwx 1 root root  22 2012-02-22 22:35 usb-Huawei_Technologies_HUAWEI_Mobile-if04-port0 -> ../../ttyUSB_utps_pcui[ < this port continually returns the data from the device + commands sent to the ttyUSB_utps_diag
    May find /dev/ttyUSB0 block by permissions / sakis3g can get around this
    if have used the eject script in the previous post with the arg tty then the udev shows ttyUSB0 = ttyUSB_utps_modem / and proves the above, so if the device is showing the ether interface without the Huawei Drivers Then Possibly Try the /devttyUSB0 or what ever shows to be the modem port,
    One sure way to Connect to the Correct Port all the time , Go back to POST #2. If have Huawie Drivers then No Need to do this , all the info is in the rules, it note if the usb_modeswiitch rules Exist , Check the logging During Install, Its There To Help.
    looks like the command to connect on ether interface is
    AT^NDISDUP=1,1,<my apn> and the port is ttyUSB_utps_modem
    to disconect
    Code:
    AT^NDISDUP=1,0
    Leave the Network Manager Ether interface setting to Manual
    Once connected Then Click on NM Ether* interface and device should Connect or track the above link where it say's
    Can see if these drivers are on the system cdc_wdm and qmi_wwa
    As Already Mentioned There are Plenty of ways To send commands to the ports .

    Also Note ,
    The eject script , This Can Be adapted for these Devices Please Read the Script
    It will help with these sort of devices if Adapted Correctly, from seeing what it is , to getting Connected, and More
    Its All there.
    But Leave The Original As is : IE Make A COPY

    Say where line
    "proc tty_status {tty} {
    Add arg :
    proc tty_status {tty AT} {
    AND LINE : puts $serial "AT"
    USE puts $serial $AT

    the parse lines EG
    Code:
    if {$buff == "send"} {
    set tty [lindex $argv 1]
    set AT [[lindex $argv 2]
             tty_status $tty $AT
    
    and the command
    ./eject send <tty> <your AT command>
    Tip ADD another ARG tty2 to read the data and add a second serial port in the same Proc
    Also remember the same port is used to connect 3g in the traditional manner should 4g not be available or the device can't work through the Ether Interface.

    Please Do read all From Post #59 , even if Your device not From Huawei , more so ,if the ether interface
    shows from the usb-devices command

    If get the Timings correct on the streaming port , you can then sort the data
    a lot of the command are ^ orientated but some at standard

    EG:
    ^CPIN
    ^SYSINFO
    AT+CSQ
    ^OPL
    AT^PNN ,

    Have Fun ,, tell you what this this is fun // if have mobile partner can look in the "log/mobilePartnerAT.txt"

    if only using the driver then Ensure Correct data, can get most of this from seviceproviders data-base on the system , standard AT commands are used for this Re First Post.

    Just a note, if using Latest Version of Bam , if Have Unity then do not minimise the BAM , use in another workspace , reason , it needs to be in the notification area
    also read doc online help from the menus RE STK Functions <some of which are> provided by NSP

    For Now link to drivers: for the HMP try googling best source / re your provider may have released both
    http://www.huaweidevice.com/tcpsdown...oadID=NDAzMjM=

    Relevance:" If I can get the dongle to be recognised, would it then be possible to run the included software (on the dongle) using either wine or Windows XP in parallel to connect to the internet?" POST #1

    For mobile partner latest version try googling Mobile Partner 21 , make sure its, Linux version , re when on the site , it will indicate Linux , if not indicating Linux then avoid , have tested some of these sites , BAH , See Screen Shots , 3 is the drivers 4 is the inside of the Linux Mobile Partner tar file
    to install just use unzip at the location , the use terminal > cd to where the files reside then ./install .
    follow prompts .

    problem find official huawei driver/Mobile Partner : can try looking here : Use at Own Risk , Did an install of this , no Problems as of yet
    http://bloglinux-patenpisan.blogspot...003280003.html

    Sakis3g: THINK THIS IS A MUST DO IF CONNECTION IS APN , sometimes HMP shows connected but no response from the lte-server
    http://www.sakis3g.org/

    Tip if you want to monitor the stream use FOFF and connect to the LOG FILE

    If everything is configured correctly then this is what you will see with ifconfig
    Code:
    eth0      Link encap:Ethernet  HWaddr 00:14:2a:86:a5:2c  
              UP BROADCAST MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
              Interrupt:23 Base address:0xe000 
    
    eth1      Link encap:Ethernet  HWaddr 00:1e:10:1f:00:01  < This is the device
              inet addr:10.68.47.85  Bcast:10.68.47.87  Mask:255.255.255.252
              inet6 addr: fe80::21e:10ff:fe1f:1/64 Scope:Link
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:322 errors:0 dropped:0 overruns:0 frame:0
              TX packets:392 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:209162 (209.1 KB)  TX bytes:62750 (62.7 KB)
    
    lo        Link encap:Local Loopback  
              inet addr:127.0.0.1  Mask:255.0.0.0
              inet6 addr: ::1/128 Scope:Host
              UP LOOPBACK RUNNING  MTU:16436  Metric:1
              RX packets:16 errors:0 dropped:0 overruns:0 frame:0
              TX packets:16 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:0 
              RX bytes:960 (960.0 B)  TX bytes:960 (960.0 B)
    Network Manager , not connected and connected RE nm-tool
    Code:
    - 
     Device: eth1 -----------------------------------------------------------------
      Type:              Wired
      Driver:            huawei_ether
      State:             disconnected
      Default:           no
      HW Address:        00:1E:10:1F:00:01
    
      Capabilities:
        Carrier Detect:  yes
    
      Wired Properties
        Carrier:         on
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Device: eth0 -----------------------------------------------------------------
      Type:              Wired
      Driver:            forcedeth
      State:             unavailable
      Default:           no
      HW Address:        00:14:2A:86:A5:2C
    
      Capabilities:
        Carrier Detect:  yes
    
      Wired Properties
        Carrier:         off
    
    
    - Device: eth1  [Auto eth1] ----------------------------------------------------
      Type:              Wired
      Driver:            huawei_ether
      State:             connected
      Default:           yes
      HW Address:        00:1E:10:1F:00:01
    
      Capabilities:
        Carrier Detect:  yes
    
      Wired Properties
        Carrier:         on
    
      IPv4 Settings:
        Address:         10.68.47.85
        Prefix:          30 (255.255.255.252)
        Gateway:         10.68.47.86
    
        DNS:             172.30.139.17
    Here is a screen shot using Huawei Mobile Partner, Re SMS text message
    second screen shot , shows request to purchase SMS text , so simple , just click on the url and browser fires up auto connects to where you need to be . it Don't get easier than that.

    For Developers the easiest route to "c" programming the serial ports for these devices is to use cssl and use the call back function


    using cssl

    can be downloaded from

    http://sourceforge.net/projects/cssl/

    to make a lib.so

    Code:
    gcc -o libcssl.so cssl.c -shared -D_GNU_SOURCE -fPIC
    for other Read the Readme

    to find what is in the lib try these commands

    Code:
    nm -D libcssl.so
    
    nm --dynamic libcssl.so
    if looking to embed usb_modeswitch can apply same method , download the source files then
    Code:
    gcc -o libmodeswitch.so usb_modeswitch.c -shared -D_GNU_SOURCE -fPIC
    using this route can save having to use wader
    Attached Images Attached Images
    Last edited by alexfish; April 27th, 2012 at 07:15 PM. Reason: programming in c
    Two tin cans are better than an iphone

    http://www.ehow.co.uk/how_2067160_ma...hone.html?cr=1

  5. #65
    Join Date
    Feb 2012
    Beans
    1

    Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    I've been through all of this stuff. Spent three days trying to get my Huawei E173 working. Support from Huawei is non-existent - I couldn't register on their site because they wouldn't accept my - valid - email address.

    Anyway, after trying almost everything I tried installing Zorin - and amazingly it works. Even with an off the shelf Orange dongle, locked, and with the installation files visible. Just tested an O2 Dongle E1752 unlocked with the Orange SIM in and that works too. It must be that Zorin has all the drivers for the latest hardware. But no-one else seems to.

  6. #66
    Join Date
    Oct 2009
    Location
    A world without windows
    Beans
    Hidden!

    Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    Quote Originally Posted by JimA52 View Post
    I've been through all of this stuff. Spent three days trying to get my Huawei E173 working. Support from Huawei is non-existent - I couldn't register on their site because they wouldn't accept my - valid - email address.

    Anyway, after trying almost everything I tried installing Zorin - and amazingly it works. Even with an off the shelf Orange dongle, locked, and with the installation files visible. Just tested an O2 Dongle E1752 unlocked with the Orange SIM in and that works too. It must be that Zorin has all the drivers for the latest hardware. But no-one else seems to.
    You so Right

    But There Again >http://zorin-os.com/tour.html > http://developer.ubuntu.com/
    Two tin cans are better than an iphone

    http://www.ehow.co.uk/how_2067160_ma...hone.html?cr=1

  7. #67
    Join Date
    Oct 2009
    Location
    A world without windows
    Beans
    Hidden!

    Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    Quote Originally Posted by JimA52 View Post
    I've been through all of this stuff. Spent three days trying to get my Huawei E173 working. Support from Huawei is non-existent - I couldn't register on their site because they wouldn't accept my - valid - email address.

    Anyway, after trying almost everything I tried installing Zorin - and amazingly it works. Even with an off the shelf Orange dongle, locked, and with the installation files visible. Just tested an O2 Dongle E1752 unlocked with the Orange SIM in and that works too. It must be that Zorin has all the drivers for the latest hardware. But no-one else seems to.
    Had to Take the Tour

    Zorin is based on Ubuntu

    If Your From a windows background and New to Linux . This could be the Place to Start

    Zorin + Huawie Mobile Partner (thats if have a Huawie device) , got to be good.

    So What do we have , Me thinks "Windows Ubuntu (2012)" ... http://zorin-os.com/index.html

    Have fun

    Alexfish
    Last edited by alexfish; March 8th, 2012 at 08:55 AM.
    Two tin cans are better than an iphone

    http://www.ehow.co.uk/how_2067160_ma...hone.html?cr=1

  8. #68
    Join Date
    Mar 2012
    Beans
    1

    Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    I have been using olive wme102 modem using qualcomm driver the device id is 22f4:0021 which is is being detected by

    lsusb
    showing
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
    Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
    Bus 001 Device 003: ID 04f2:b1e5 Chicony Electronics Co., Ltd
    Bus 001 Device 004: ID 0b05:1788 ASUSTek Computer, Inc.
    Bus 002 Device 009: ID 22f4:0021


    following your posts #59 and #60
    i tried to configure the new data card provided by TATA Photon + with device id 2244:0021

    root@neogy-K52F:~# lsusb -t -d 22f4:0021
    1-1.5:1.2: No such file or directory
    1-1.5:1.3: No such file or directory
    /: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=ehci_hcd/2p, 480M
    |__ Port 1: Dev 2, If 0, Class=hub, Driver=hub/8p, 480M
    |__ Port 1: Dev 11, If 0, Class=HID, Driver=usbhid, 1.5M
    |__ Port 3: Dev 9, If 0, Class=stor., Driver=usb-storage, 12M
    /: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=ehci_hcd/2p, 480M
    |__ Port 1: Dev 2, If 0, Class=hub, Driver=hub/6p, 480M
    |__ Port 2: Dev 3, If 0, Class='bInterfaceClass 0x0e not yet handled', Driver=uvcvideo, 480M
    |__ Port 2: Dev 3, If 1, Class='bInterfaceClass 0x0e not yet handled', Driver=uvcvideo, 480M
    |__ Port 5: Dev 4, If 0, Class='bInterfaceClass 0xe0 not yet handled', Driver=btusb, 12M
    |__ Port 5: Dev 4, If 1, Class='bInterfaceClass 0xe0 not yet handled', Driver=btusb, 12M
    |__ Port 5: Dev 4, If 2, Class=vend., Driver=, 12M
    |__ Port 5: Dev 4, If 3, Class=app., Driver=, 12M


    root@neogy-K52F:~# ls -al /dev/serial/by-id/*
    ls: cannot access /dev/serial/by-id/*: No such file or directory
    root@neogy-K52F:~# tar tf /usr/share/usb_modeswitch/configPack.tar.gz
    03f0:002a
    0421:060c
    0421:0610
    0421:0622
    0421:0627
    0471:1210:uMa=Philips
    0471:1210:uMa=Wisue
    0471:1237
    0482:024d
    04e8:689a
    04e8:f000
    057c:84ff
    05c6:1000:sVe=GT
    05c6:1000:sVe=Option
    05c6:1000:uMa=AnyDATA
    05c6:1000:uMa=Option
    05c6:1000:uMa=SAMSUNG
    05c6:1000:uMa=SSE
    05c6:1000:uMa=Vertex
    05c6:2000
    05c6:2001
    05c6:f000
    05c7:1000
    072f:100d
    07d1:a800
    07d1:a804
    0930:0d46
    0ace:2011
    0ace:20ff
    0af0:6711
    0af0:6731
    0af0:6751
    0af0:6771
    0af0:6791
    0af0:6811
    0af0:6911
    0af0:6951
    0af0:6971
    0af0:7011
    0af0:7031
    0af0:7051
    0af0:7071
    0af0:7111
    0af0:7211
    0af0:7251
    0af0:7271
    0af0:7301
    0af0:7311
    0af0:7361
    0af0:7381
    0af0:7401
    0af0:7501
    0af0:7601
    0af0:7701
    0af0:7801
    0af0:7901
    0af0:7a01
    0af0:7a05
    0af0:8200
    0af0:8201
    0af0:8300
    0af0:8302
    0af0:8304
    0af0:8400
    0af0:8600
    0af0:8800
    0af0:8900
    0af0:9000
    0af0:c031
    0af0:c100
    0af0:d013
    0af0:d031
    0af0:d033
    0af0:d035
    0af0:d055
    0af0:d057
    0af0:d058
    0af0:d155
    0af0:d157
    0af0:d255
    0af0:d257
    0af0:d357
    0b3c:c700
    0b3c:f000
    0cf3:20ff
    0d46:45a1
    0d46:45a5
    0df7:0800
    0e8d:7109
    0fce:d0cf
    0fce:d0e1
    0fce:d103
    0fd1:1000
    1004:1000
    1004:607f
    1004:613a
    1004:613f
    1004:6190
    1033:0035
    106c:3b03
    106c:3b05
    106c:3b06
    1076:7f40
    1199:0fff
    1266:1000
    12d1:1001
    12d1:1003
    12d1:1009
    12d1:101e
    12d1:1030
    12d1:1031
    12d1:1414
    12d1:1446
    12d1:1449
    12d1:14ad
    12d1:14b5
    12d1:14b7
    12d1:14c1
    12d1:14c4
    12d1:14c5
    12d1:14d1
    12d1:14fe
    12d1:1505
    12d1:1520
    12d1:1521
    12d1:1523
    12d1:1553
    12d1:1557
    12d1:1c0b
    12d1:1da1
    12d1:380b
    1307:1169
    1410:5010
    1410:5020
    1410:5030
    1410:5031
    1410:5041
    148e:a000
    148f:2578
    16d8:6281
    16d8:6803
    16d8:700a
    16d8:700b
    16d8:f000
    198a:0003
    198f:bccd
    19d2:0003
    19d2:0013
    19d2:0026
    19d2:0040
    19d2:0053
    19d2:0083
    19d2:0101
    19d2:0103
    19d2:0110
    19d2:0115
    19d2:0149
    19d2:1001
    19d2:1007
    19d2:1009
    19d2:1013
    19d2:1171
    19d2:1175
    19d2:1179
    19d2:1201
    19d2:1216
    19d2:1224
    19d2:2000
    19d2:bccd
    19d2:ffe6
    19d2:fff5
    19d2:fff6
    1a8d:1000
    1ab7:5700
    1b7d:0700
    1bbb:f000
    1c9e:1001
    1c9e:6061
    1c9e:9200
    1c9e:9800
    1c9e:9e00
    1c9e:f000
    1dd6:1000
    1e0e:f000
    1edf:6003
    1ee8:0009
    1ee8:0013
    1ee8:0040
    1f28:0021
    1fac:0032
    1fac:0130
    201e:2009
    2020:f00e
    230d:0001
    230d:0007
    8888:6500
    The device is not listed in the list

    root@neogy-K52F:~# cd /etc/usb_modeswitch.d
    root@neogy-K52F:/etc/usb_modeswitch.d# tar -x 22f4:0021 -f /usr/share/usb_modeswitch/configPack.tar.gz
    tar: 22f4\:0021: Not found in archive
    tar: Exiting with failure status due to previous errors

    root@neogy-K52F:/etc/usb_modeswitch.d# usb_modeswitch -W -c /etc/usb_modeswitch.d/22f4:0021

    Reading config file: /etc/usb_modeswitch.d/22f4:0021

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

    ! PLEASE REPORT NEW CONFIGURATIONS !

    DefaultVendor= 0x224f
    DefaultProduct= 0x0021
    TargetVendor= not set
    TargetProduct= not set
    TargetClass= 0xff
    TargetProductList=""

    DetachStorageOnly=0
    HuaweiMode=0
    SierraMode=0
    SonyMode=0
    GCTMode=0
    KobilMode=0
    SequansMode=0
    MobileActionMode=0
    CiscoMode=0
    MessageEndpoint= not set
    MessageContent="5553424312345678000000000000061e00 0000000000000000000000000000"
    MessageContent2="5553424312345679000000000000061b0 00000020000000000000000000000"
    NeedResponse=1
    ResponseEndpoint= not set
    Interface=0x00

    InquireDevice enabled (default)
    Success check enabled, max. wait time 10 seconds
    System integration mode disabled

    usb_set_debug: Setting debugging level to 15 (on)
    usb_os_find_busses: Found 002
    usb_os_find_busses: Found 001
    usb_os_find_devices: Found 011 on 002
    skipped 1 class/vendor specific interface descriptors
    usb_os_find_devices: Found 009 on 002
    usb_os_find_devices: Found 002 on 002
    usb_os_find_devices: Found 001 on 002
    error obtaining child information: Inappropriate ioctl for device
    error obtaining child information: Inappropriate ioctl for device
    usb_os_find_devices: Found 004 on 001
    skipped 1 class/vendor specific interface descriptors
    usb_os_find_devices: Found 003 on 001
    skipping descriptor 0xB
    skipped 1 class/vendor specific endpoint descriptors
    skipped 6 class/vendor specific interface descriptors
    skipping descriptor 0x25
    skipped 1 class/vendor specific endpoint descriptors
    skipped 9 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

    Looking for target devices ...
    No devices in target mode or class found
    Looking for default devices ...
    searching devices, found USB ID 046d:c016
    searching devices, found USB ID 22f4:0021
    searching devices, found USB ID 8087:0020
    searching devices, found USB ID 1d6b:0002
    searching devices, found USB ID 0b05:1788
    searching devices, found USB ID 04f2:b1e5
    searching devices, found USB ID 8087:0020
    searching devices, found USB ID 1d6b:0002
    No devices in default mode found. Nothing to do. Bye.

    root@neogy-K52F:/etc/usb_modeswitch.d# grep -i v22f4p0021 /lib/modules/`uname -r`/modules.alias
    root@neogy-K52F:/etc/usb_modeswitch.d# grep -i v22f4p0021 /lib/modules/*/modules.alias
    root@neogy-K52F:/etc/usb_modeswitch.d#

    returns nothing means not found in kernel
    (following post #60)

    root@neogy-K52F:/etc/usb_modeswitch.d# grep usb /sys/bus/usb/devices/*/modalias
    /sys/bus/usb/devices/1-0:1.0/modalias:usb:v1D6Bp0002d0300dc09dsc00dp00ic09isc00 ip00
    /sys/bus/usb/devices/1-1:1.0/modalias:usb:v8087p0020d0000dc09dsc00dp01ic09isc00 ip00
    /sys/bus/usb/devices/1-1.2:1.0/modalias:usb:v04F2pB1E5d2069dcEFdsc02dp01ic0Eisc01 ip00
    /sys/bus/usb/devices/1-1.2:1.1/modalias:usb:v04F2pB1E5d2069dcEFdsc02dp01ic0Eisc02 ip00
    /sys/bus/usb/devices/1-1.5:1.0/modalias:usb:v0B05p1788d0449dcE0dsc01dp01icE0isc01 ip01
    /sys/bus/usb/devices/1-1.5:1.1/modalias:usb:v0B05p1788d0449dcE0dsc01dp01icE0isc01 ip01
    /sys/bus/usb/devices/1-1.5:1.2/modalias:usb:v0B05p1788d0449dcE0dsc01dp01icFFiscFF ipFF
    /sys/bus/usb/devices/1-1.5:1.3/modalias:usb:v0B05p1788d0449dcE0dsc01dp01icFEisc01 ip01
    /sys/bus/usb/devices/2-0:1.0/modalias:usb:v1D6Bp0002d0300dc09dsc00dp00ic09isc00 ip00
    /sys/bus/usb/devices/2-1:1.0/modalias:usb:v8087p0020d0000dc09dsc00dp01ic09isc00 ip00
    /sys/bus/usb/devices/2-1.1:1.0/modalias:usb:v046DpC016d0340dc00dsc00dp00ic03isc01 ip02
    /sys/bus/usb/devices/2-1.3:1.0/modalias:usb:v22F4p0021d0000dc00dsc00dp00ic08isc06 ip50

    using ip50

    grep -i ip50 /lib/modules/`uname -r`/modules.alias
    alias usb:v*p*d*dc*dsc*dp*ic08isc06ip50* uas
    alias usb:v*p*d*dc*dsc*dp*ic08isc06ip50* usb_storage
    alias usb:v*p*d*dc*dsc*dp*ic08isc05ip50* usb_storage
    alias usb:v*p*d*dc*dsc*dp*ic08isc04ip50* usb_storage
    alias usb:v*p*d*dc*dsc*dp*ic08isc03ip50* usb_storage
    alias usb:v*p*d*dc*dsc*dp*ic08isc02ip50* usb_storage
    alias usb:v*p*d*dc*dsc*dp*ic08isc01ip50* usb_storage
    root@neogy-K52F:/etc/usb_modeswitch.d#


    which means the device is not getting detected as modem Please put some light!!!
    root@neogy-K52F:/etc/usb_modeswitch.d# usb-devices

    T: Bus=02 Lev=02 Prnt=02 Port=02 Cnt=02 Dev#= 9 Spd=12 MxCh= 0
    D: Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1
    P: Vendor=22f4 ProdID=0021 Rev=00.00
    S: Manufacturer=Qualcomm, Incorporated
    S: Product=USB MMC Storage
    S: SerialNumber=00100_DATACAR
    C: #Ifs= 1 Cfg#= 1 Atr=c0 MxPwr=100mA
    I: If#= 0 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
    root@neogy-K52F:/etc/usb_modeswitch.d#
    Please put some light!!!

  9. #69
    Join Date
    Oct 2009
    Location
    A world without windows
    Beans
    Hidden!

    Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    Hi @ neogy

    can see from private message , have configured Huawei device using info in the HOW TO:

    OK:

    Each device is different:

    First step is to see what mode the device is in : all info indicates = unswitched

    Un_switched devices Need to be switched to Modem Mode , this can be done in Two ways , eject(cd part of the device) or send message to the device (message mode switching) , this is what usb_modeswitch does , usb_modeswitch can do both

    usb_modeswitch needs to know what the device is , hence the data base

    From the end user aspect you have to "decide" which method will switch the device

    For this first step I have written a script which may help , see post #61

    it does most of what has been done manually by yourself.

    read the post carefully , the script will give the info necessary for the decision making process:

    1. will the device switch with the eject command "finding the eject bit" , or does it require "mode switch message"
    Also note from "first post" foot of page screen shot , finding an eject-able device,

    2. Device not switching with eject Command and not in data base , refer to mode_switch forum
    even if the device switches with the eject command please inform the forum of the finding.

    3. the script will detect if the drivers are loading after switching , if not loading then will run through the next stage

    See what happens, for help on the script can send private message.
    Also noted
    Bus 002 Device 009: ID 22f4:0021





    following your posts #59 and #60
    i tried to configure the new data card provided by TATA Photon + with device id 2244:0021

    root@neogy-K52F:~# lsusb -t -d 22f4:0021
    1-1.5:1.2: No such file or directory
    1-1.5:1.3: No such file or directory
    /: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=ehci_hcd/2p, 480M
    |__ Port 1: Dev 2, If 0, Class=hub, Driver=hub/8p, 480M
    |__ Port 1: Dev 11, If 0, Class=HID, Driver=usbhid, 1.5M
    |__ Port 3: Dev 9, If 0, Class=stor., Driver=usb-storage, 12M <<< This is your Device
    Ref ::lsub = Bus 002 Device 009: ID 22f4:0021
    Also worth looking up
    http://comments.gmane.org/gmane.linux.usb.general/34876
    Have Done link to PDF doc RE: 12M at post #60

    alexfish
    Last edited by alexfish; March 24th, 2012 at 02:15 PM. Reason: 12M
    Two tin cans are better than an iphone

    http://www.ehow.co.uk/how_2067160_ma...hone.html?cr=1

  10. #70
    Join Date
    Apr 2012
    Beans
    1

    Angry Re: How To : Mobile Broadband Connections [ Ubuntu 11.04 : 10.10 : 10.04 : 9.10]

    I must be stupid as i dont get how to install my e353 dongle on 11.04 at all could do with SIMPLE instructions i tried for 6hrs and all i got was drunk with frustration not being a computer programer i had no chance guidance would be very helpfull.

Page 7 of 8 FirstFirst ... 5678 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •