Yun, 3G dongle and yun_3g library

Hi!
I'm trying to use a USB 3G dongle to be able to connect Yun to the Internet
where there's no other kind of connection.
The primary aim is to complete a DIY anemometer, but any kind of sensor colud be used:
so wherever you are, whatever you what to measure
you could do it!

Well, Yun is great to do this!
Thinking of this project I found a nice repository on GitHub: GitHub - pictux/Yun_3g: Sketch, package, other stuff for UMTS/3G connection with Yun
so that every thing seems to be done, yet!
But there are some problems I report below, taken from LuCI's SystemLog:

Apr 24 00:55:34 supermarioyun daemon.info avahi-daemon[1289]: avahi-daemon 0.6.31 starting up.
Apr 24 00:55:34 supermarioyun daemon.warn avahi-daemon[1289]: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Apr 24 00:55:34 supermarioyun daemon.info avahi-daemon[1289]: Loading service file /etc/avahi/services/arduino.service.
Apr 24 00:55:34 supermarioyun daemon.info avahi-daemon[1289]: Loading service file /etc/avahi/services/ssh.service.
Apr 24 00:55:34 supermarioyun daemon.info avahi-daemon[1289]: Joining mDNS multicast group on interface wlan0.IPv4 with address 192.168.0.29.
Apr 24 00:55:34 supermarioyun daemon.info avahi-daemon[1289]: New relevant interface wlan0.IPv4 for mDNS.
Apr 24 00:55:34 supermarioyun daemon.info avahi-daemon[1289]: Network interface enumeration completed.
Apr 24 00:55:34 supermarioyun daemon.info avahi-daemon[1289]: Registering new address record for 192.168.0.29 on wlan0.IPv4.
Apr 24 00:55:34 supermarioyun daemon.info avahi-daemon[1289]: Registering HINFO record with values 'MIPS'/'LINUX'.
Apr 24 00:55:35 supermarioyun daemon.info avahi-daemon[1289]: Server startup complete. Host name is supermarioyun.local. Local service cookie is 1199464232.
Apr 24 00:55:35 supermarioyun user.info sysinit: Start uSDaemon
Apr 24 00:55:36 supermarioyun daemon.info avahi-daemon[1289]: Service "Secure Shell on supermarioyun" (/etc/avahi/services/ssh.service) successfully established.
Apr 24 00:55:36 supermarioyun daemon.info avahi-daemon[1289]: Service "supermarioyun" (/etc/avahi/services/arduino.service) successfully established.
Apr 24 00:55:44 supermarioyun user.notice usb-modeswitch: 1-1.4:1.0: Manufacturer=Generic Product=Mass_Storage_Device Serial=058F0O1111B1
Apr 24 00:55:44 supermarioyun user.notice usb-modeswitch: 1-0:1.0: Manufacturer=Linux_3.8.3_ehci_hcd Product=EHCI_Host_Controller Serial=ehci-platform
Apr 24 00:55:44 supermarioyun user.notice usb-modeswitch: 1-1:1.0: Manufacturer=? Product=USB2.0Hub Serial=?
Apr 24 00:55:54 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
Apr 24 00:55:55 supermarioyun user.notice usb-modeswitch: 1-1.1:1.1: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
Apr 24 00:55:55 supermarioyun user.notice usb-modeswitch: 1-1.1:1.2: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
Apr 24 00:55:58 supermarioyun daemon.notice pppd[2013]: pppd 2.4.5 started by root, uid 0
Apr 24 00:55:59 supermarioyun local2.info chat[2027]: abort on (BUSY)
Apr 24 00:55:59 supermarioyun local2.info chat[2027]: abort on (NO CARRIER)
Apr 24 00:55:59 supermarioyun local2.info chat[2027]: abort on (ERROR)
Apr 24 00:55:59 supermarioyun local2.info chat[2027]: report (CONNECT)
Apr 24 00:55:59 supermarioyun local2.info chat[2027]: timeout set to 10 seconds
Apr 24 00:55:59 supermarioyun local2.info chat[2027]: send (AT&F^M)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: expect (OK)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: +ZDONR: "Not Found"^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: +ZPASR: "No Service"^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: +ZDONR: "Not Found"^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: +ZPASR: "Limited Service"^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: AT&F^M^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: OK
Apr 24 00:56:00 supermarioyun local2.info chat[2027]:  -- got it
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: send (ATE1^M)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: expect (OK)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ATE1^M^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: OK
Apr 24 00:56:00 supermarioyun local2.info chat[2027]:  -- got it
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: send (AT+CGDCONT=1,"IP","tre.it"^M)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: send (AT+SYSCFG=2,2,3FFFFFFF,1,4^M)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: timeout set to 30 seconds
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: expect (OK)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: AT+CGDCONT=1,"IP","tre.it"^M^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: OK
Apr 24 00:56:00 supermarioyun local2.info chat[2027]:  -- got it
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: send (ATD*99#^M)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: expect (CONNECT)
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: AT+SYSCFG=2,2,3FFFFFFF,1,4^M^M
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: ERROR
Apr 24 00:56:00 supermarioyun local2.info chat[2027]:  -- failed
Apr 24 00:56:00 supermarioyun local2.info chat[2027]: Failed (ERROR)
Apr 24 00:56:00 supermarioyun daemon.err pppd[2013]: Connect script failed
Apr 24 00:56:01 supermarioyun cron.info crond[1233]: crond: USER root pid 2038 cmd /root//root/check3g.sh
Apr 24 00:56:01 supermarioyun cron.info crond[1233]: crond: USER root pid 2039 cmd /root//root/check3g.sh
Apr 24 10:58:40 supermarioyun cron.err crond[1233]: time disparity of 602 minutes detected
Apr 24 10:58:40 supermarioyun daemon.info pppd[2013]: Exit.
Apr 24 10:58:40 supermarioyun daemon.notice netifd: Interface 'wan2' is now down
Apr 24 11:00:01 supermarioyun cron.info crond[1233]: crond: USER root pid 2498 cmd /root//root/check3g.sh
Apr 24 11:00:01 supermarioyun cron.info crond[1233]: crond: USER root pid 2499 cmd /root//root/check3g.sh
Apr 24 11:02:01 supermarioyun cron.info crond[1233]: crond: USER root pid 3096 cmd /root//root/check3g.sh

Here is a second report with a different power supply:

Apr 24 01:05:05 supermarioyun user.notice usb-modeswitch: 1-1.1:1.2: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
Apr 24 01:06:01 supermarioyun cron.info crond[1237]: crond: USER root pid 5846 cmd /root//root/check3g.sh
Apr 24 01:06:01 supermarioyun cron.info crond[1237]: crond: USER root pid 5847 cmd /root//root/check3g.sh
Apr 24 01:06:30 supermarioyun kern.info kernel: [  724.260000] usb 1-1.1: USB disconnect, device number 15
Apr 24 01:06:30 supermarioyun kern.info kernel: [  724.260000] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
Apr 24 01:06:30 supermarioyun kern.info kernel: [  724.260000] option 1-1.1:1.0: device disconnected
Apr 24 01:06:30 supermarioyun kern.err kernel: [  724.270000] option1 ttyUSB1: option_instat_callback: error -71
Apr 24 01:06:30 supermarioyun kern.info kernel: [  724.280000] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
Apr 24 01:06:30 supermarioyun kern.info kernel: [  724.280000] option 1-1.1:1.2: device disconnected
Apr 24 01:06:34 supermarioyun kern.info kernel: [  728.850000] usb 1-1.1: new high-speed USB device number 16 using ehci-platform
Apr 24 01:06:34 supermarioyun kern.info kernel: [  728.990000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=2000
Apr 24 01:06:34 supermarioyun kern.info kernel: [  728.990000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3
Apr 24 01:06:34 supermarioyun kern.info kernel: [  728.990000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
Apr 24 01:06:34 supermarioyun kern.info kernel: [  729.000000] usb 1-1.1: Manufacturer: ZTE,Incorporated
Apr 24 01:06:34 supermarioyun kern.info kernel: [  729.000000] usb 1-1.1: SerialNumber: 3AUP673A4CDROMMS
Apr 24 01:06:34 supermarioyun kern.info kernel: [  729.020000] scsi13 : usb-storage 1-1.1:1.0
Apr 24 01:06:35 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=3AUP673A4CDROMMS
Apr 24 01:06:35 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Selecting /etc/usb_modeswitch.d/19d2:2000 for mode switching
Apr 24 01:06:35 supermarioyun syslog.notice usb_modeswitch: switching device 19d2:2000 on 001/016
Apr 24 01:06:40 supermarioyun kern.info kernel: [  734.750000] usb 1-1.1: USB disconnect, device number 16
Apr 24 01:06:45 supermarioyun kern.info kernel: [  739.860000] usb 1-1.1: new high-speed USB device number 17 using ehci-platform
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.000000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=0064
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.000000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.000000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.000000] usb 1-1.1: Manufacturer: ZTE,Incorporated
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.010000] option 1-1.1:1.0: GSM modem (1-port) converter detected
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.010000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB0
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.020000] scsi14 : usb-storage 1-1.1:1.1
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.020000] option 1-1.1:1.2: GSM modem (1-port) converter detected
Apr 24 01:06:45 supermarioyun kern.info kernel: [  740.020000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB1
Apr 24 01:06:46 supermarioyun kern.notice kernel: [  741.020000] scsi 14:0:0:0: Direct-Access     ZTE      MMC Storage      2.31 PQ: 0 ANSI: 2
Apr 24 01:06:46 supermarioyun kern.notice kernel: [  741.040000] sd 14:0:0:0: [sdb] Attached SCSI removable disk
Apr 24 01:07:06 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
Apr 24 01:07:06 supermarioyun user.notice usb-modeswitch: 1-1.1:1.1: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
Apr 24 01:07:06 supermarioyun user.notice usb-modeswitch: 1-1.1:1.2: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
Apr 24 01:08:01 supermarioyun cron.info crond[1237]: crond: USER root pid 6588 cmd /root//root/check3g.sh
Apr 24 01:08:01 supermarioyun cron.info crond[1237]: crond: USER root pid 6589 cmd /root//root/check3g.sh
Apr 24 01:10:01 supermarioyun cron.info crond[1237]: crond: USER root pid 7170 cmd /root//root/check3g.sh
Apr 24 01:10:01 supermarioyun cron.info crond[1237]: crond: USER root pid 7171 cmd /root//root/check3g.sh
Apr 24 01:12:01 supermarioyun cron.info crond[1237]: crond: USER root pid 7762 cmd /root//root/check3g.sh
Apr 24 01:12:01 supermarioyun cron.info crond[1237]: crond: USER root pid 7763 cmd /root//root/check3g.sh

I thought it could be a problem with power supply:
the first report refers to a 5V,600mA power supply, the second to a 5V,1A one.
In the first the system seems unable to determine the Serial
in the second sometimes it does but it seems unable to maintain...

So: any suggestion?

Here is a KernelLog:

[    0.000000] Linux version 3.8.3 (federico@smilzo) (gcc version 4.6.4 20121210 (prerelease) (Linaro GCC 4.6-2012.12) ) #8 Mon Aug 19 16:22:39 CEST 2013
[    0.000000] bootconsole [early0] enabled

...bla bla bla...

[ 1146.900000] usb 1-1.1: new high-speed USB device number 18 using ehci-platform
[ 1147.040000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=2000
[ 1147.040000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3
[ 1147.040000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[ 1147.050000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[ 1147.050000] usb 1-1.1: SerialNumber: 3AUP673A4CDROMMS
[ 1147.070000] scsi15 : usb-storage 1-1.1:1.0
[ 1152.550000] usb 1-1.1: USB disconnect, device number 18
[ 1157.910000] usb 1-1.1: new high-speed USB device number 19 using ehci-platform
[ 1158.050000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=0064
[ 1158.050000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[ 1158.050000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[ 1158.050000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[ 1158.060000] option 1-1.1:1.0: GSM modem (1-port) converter detected
[ 1158.060000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB0
[ 1158.070000] scsi16 : usb-storage 1-1.1:1.1
[ 1158.070000] option 1-1.1:1.2: GSM modem (1-port) converter detected
[ 1158.070000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB1
[ 1159.070000] scsi 16:0:0:0: Direct-Access     ZTE      MMC Storage      2.31 PQ: 0 ANSI: 2
[ 1159.090000] sd 16:0:0:0: [sdb] Attached SCSI removable disk
[ 1640.540000] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
[ 1640.550000] option 1-1.1:1.0: device disconnected
[ 1640.550000] option1 ttyUSB1: option_instat_callback: error -143
[ 1640.570000] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
[ 1640.570000] option 1-1.1:1.2: device disconnected
[ 1640.570000] hub 1-1:1.0: cannot reset port 1 (err = -71)
[ 1640.800000] usb 1-1.1: USB disconnect, device number 19
[ 1640.810000] scsi 16:0:0:0: rejecting I/O to offline device
[ 1640.810000] scsi 16:0:0:0: killing request
[ 1645.840000] usb 1-1.1: new high-speed USB device number 20 using ehci-platform
[ 1645.980000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=2000
[ 1645.980000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3
[ 1645.980000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[ 1645.990000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[ 1645.990000] usb 1-1.1: SerialNumber: 3AUP673A4CDROMMS
[ 1646.000000] scsi17 : usb-storage 1-1.1:1.0
[ 1651.490000] usb 1-1.1: USB disconnect, device number 20
[ 1656.850000] usb 1-1.1: new high-speed USB device number 21 using ehci-platform
[ 1656.990000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=0064
[ 1656.990000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[ 1656.990000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[ 1656.990000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[ 1657.000000] option 1-1.1:1.0: GSM modem (1-port) converter detected
[ 1657.000000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB0
[ 1657.010000] scsi18 : usb-storage 1-1.1:1.1
[ 1657.010000] option 1-1.1:1.2: GSM modem (1-port) converter detected
[ 1657.010000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB1
[ 1658.010000] scsi 18:0:0:0: Direct-Access     ZTE      MMC Storage      2.31 PQ: 0 ANSI: 2
[ 1658.030000] sd 18:0:0:0: [sdb] Attached SCSI removable disk

for admins: I know I'doing some kind of crossposting...sorry!
I think it is better to post in the international forum, so if you prefer please delete my other one (Connessione a internet con 3G shield: dubbi/timori - #3 by supermarioprof - Generale - Arduino Forum)

I'm sorry I don't have any. I would try to contact user pictux by filing an issue at Issues · pictux/Yun_3g · GitHub
Also: /root//root/check3g.sh doesn't look like the right file name

6 minutes to receive an answer! :astonished: :astonished: great!

I will try to contact user pictux on GitHub,
he is an italian user, Mirco Piccin, maybe you know him.

And yes, it seemed weird to me too that /root//root/check3g.sh in SystemLog...
but I thought about power supply firstly, since I'm just a noob in electronics and programming.
So, ok:
I will give a try to change that string in Yun_3g/linino_set3g.sh at master · pictux/Yun_3g · GitHub, line 14
and report what happens!

Hi

Also: /root//root/check3g.sh doesn't look like the right file name

that's the script that checks if the connection is alive, and if not tries to reconnect.
I'll update the script (row 82) in a few hours.

Thanks
M

EDIT: DONE

that's the script that checks if the connection is alive, and if not tries to reconnect.
I'll update the script (row 82) in a few hours.

so..it should be wrong as I stated.
Ok, I will try to modify crontab, waiting for the update.
Thank you so much!

Ok, here I am again after some tests with the new script from PicTux.
I'm not able to connect, unfortunately.
Here is a SystemLog:

...
May  1 08:03:05 supermarioyun kern.info kernel: [  400.930000] usb 1-1.1: USB disconnect, device number 19
May  1 08:03:10 supermarioyun kern.info kernel: [  406.290000] usb 1-1.1: new high-speed USB device number 20 using ehci-platform
May  1 08:03:11 supermarioyun kern.info kernel: [  406.430000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=0064
May  1 08:03:11 supermarioyun kern.info kernel: [  406.430000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
May  1 08:03:11 supermarioyun kern.info kernel: [  406.430000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
May  1 08:03:11 supermarioyun kern.info kernel: [  406.430000] usb 1-1.1: Manufacturer: ZTE,Incorporated
May  1 08:03:11 supermarioyun kern.info kernel: [  406.440000] option 1-1.1:1.0: GSM modem (1-port) converter detected
May  1 08:03:11 supermarioyun kern.info kernel: [  406.440000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB0
May  1 08:03:11 supermarioyun kern.info kernel: [  406.450000] scsi17 : usb-storage 1-1.1:1.1
May  1 08:03:11 supermarioyun kern.info kernel: [  406.450000] option 1-1.1:1.2: GSM modem (1-port) converter detected
May  1 08:03:11 supermarioyun kern.info kernel: [  406.450000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB1
May  1 08:03:12 supermarioyun kern.notice kernel: [  407.450000] scsi 17:0:0:0: Direct-Access     ZTE      MMC Storage      2.31 PQ: 0 ANSI: 2
May  1 08:03:12 supermarioyun kern.notice kernel: [  407.470000] sd 17:0:0:0: [sdb] Attached SCSI removable disk
May  1 08:03:21 supermarioyun kern.err kernel: [  416.820000] hub 1-1:1.0: cannot reset port 4 (err = -71)
May  1 08:03:21 supermarioyun kern.err kernel: [  416.820000] hub 1-1:1.0: cannot reset port 4 (err = -71)
May  1 08:03:21 supermarioyun kern.err kernel: [  416.990000] option1 ttyUSB1: option_instat_callback: error -71
May  1 08:03:21 supermarioyun kern.info kernel: [  417.060000] usb 1-1.1: USB disconnect, device number 20
May  1 08:03:21 supermarioyun kern.info kernel: [  417.060000] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
May  1 08:03:21 supermarioyun kern.info kernel: [  417.060000] option 1-1.1:1.0: device disconnected
May  1 08:03:21 supermarioyun kern.err kernel: [  417.070000] option1 ttyUSB1: option_instat_callback: error -143
May  1 08:03:21 supermarioyun kern.info kernel: [  417.070000] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
May  1 08:03:21 supermarioyun kern.info kernel: [  417.080000] option 1-1.1:1.2: device disconnected
May  1 08:03:21 supermarioyun kern.info kernel: [  417.100000] usb 1-1.4: reset high-speed USB device number 4 using ehci-platform
May  1 08:03:21 supermarioyun kern.err kernel: [  417.210000] usb 1-1.4: device descriptor read/64, error -71
May  1 08:03:23 supermarioyun kern.err kernel: [  418.720000] sd 1:0:0:0: [sda] No Caching mode page present
May  1 08:03:23 supermarioyun kern.err kernel: [  418.720000] sd 1:0:0:0: [sda] Assuming drive cache: write through
May  1 08:03:23 supermarioyun user.info sysinit: cat: can't open '/sys/bus/scsi/drivers/sd/17:0:0:0/block/sdb/size': No such file or directory
May  1 08:03:27 supermarioyun kern.info kernel: [  422.420000] usb 1-1.1: new high-speed USB device number 21 using ehci-platform
May  1 08:03:27 supermarioyun kern.info kernel: [  422.560000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=2000
May  1 08:03:27 supermarioyun kern.info kernel: [  422.560000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3
May  1 08:03:27 supermarioyun kern.info kernel: [  422.560000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
May  1 08:03:27 supermarioyun kern.info kernel: [  422.570000] usb 1-1.1: Manufacturer: ZTE,Incorporated
May  1 08:03:27 supermarioyun kern.info kernel: [  422.570000] usb 1-1.1: SerialNumber: 3AUP673A4CDROMMS
May  1 08:03:27 supermarioyun kern.info kernel: [  422.570000] scsi18 : usb-storage 1-1.1:1.0
May  1 08:03:28 supermarioyun kern.notice kernel: [  423.580000] scsi 18:0:0:0: CD-ROM            ZTE      USB SCSI CD-ROM  2.31 PQ: 0 ANSI: 2
May  1 08:03:30 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:31 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:32 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:33 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:34 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:35 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:37 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:38 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=3AUP673A4CDROMMS
May  1 08:03:38 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Selecting /etc/usb_modeswitch.d/19d2:2000 for mode switching
May  1 08:03:38 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:39 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Switching seemingly failed
May  1 08:03:40 supermarioyun kern.info kernel: [  435.750000] usb 1-1.1: USB disconnect, device number 21
May  1 08:03:40 supermarioyun user.notice usb-modeswitch: 1-1.1:1.1: Manufacturer=? Product=? Serial=?
May  1 08:03:41 supermarioyun user.notice usb-modeswitch: 1-1.1:1.2: Manufacturer=? Product=? Serial=?
May  1 08:03:42 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Manufacturer=? Product=? Serial=?
May  1 08:03:44 supermarioyun kern.info kernel: [  440.340000] usb 1-1.1: new high-speed USB device number 22 using ehci-platform
May  1 08:03:45 supermarioyun kern.info kernel: [  440.480000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=2000
May  1 08:03:45 supermarioyun kern.info kernel: [  440.480000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3
May  1 08:03:45 supermarioyun kern.info kernel: [  440.480000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
May  1 08:03:45 supermarioyun kern.info kernel: [  440.490000] usb 1-1.1: Manufacturer: ZTE,Incorporated
May  1 08:03:45 supermarioyun kern.info kernel: [  440.490000] usb 1-1.1: SerialNumber: 3AUP673A4CDROMMS
May  1 08:03:45 supermarioyun kern.info kernel: [  440.500000] scsi19 : usb-storage 1-1.1:1.0
May  1 08:03:45 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=3AUP673A4CDROMMS
May  1 08:03:45 supermarioyun user.notice usb-modeswitch: 1-1.1:1.0: Selecting /etc/usb_modeswitch.d/19d2:2000 for mode switching
May  1 08:03:45 supermarioyun syslog.notice usb_modeswitch: switching device 19d2:2000 on 001/022
May  1 08:03:50 supermarioyun kern.info kernel: [  445.990000] usb 1-1.1: USB disconnect, device number 22

and here a KernelLog:

...
[  390.430000] usb 1-1.1: USB disconnect, device number 18
[  390.440000] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
[  390.440000] option 1-1.1:1.0: device disconnected
[  390.450000] sd 15:0:0:0: [sdb] Synchronizing SCSI cache
[  390.450000] sd 15:0:0:0: [sdb]  
[  390.450000] Result: hostbyte=0x01 driverbyte=0x00
[  390.460000] option1 ttyUSB1: option_instat_callback: error -143
[  390.460000] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
[  390.460000] option 1-1.1:1.2: device disconnected
[  395.280000] usb 1-1.1: new high-speed USB device number 19 using ehci-platform
[  395.420000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=2000
[  395.420000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3
[  395.420000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[  395.430000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[  395.430000] usb 1-1.1: SerialNumber: 3AUP673A4CDROMMS
[  395.440000] scsi16 : usb-storage 1-1.1:1.0
[  400.930000] usb 1-1.1: USB disconnect, device number 19
[  406.290000] usb 1-1.1: new high-speed USB device number 20 using ehci-platform
[  406.430000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=0064
[  406.430000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[  406.430000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[  406.430000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[  406.440000] option 1-1.1:1.0: GSM modem (1-port) converter detected
[  406.440000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB0
[  406.450000] scsi17 : usb-storage 1-1.1:1.1
[  406.450000] option 1-1.1:1.2: GSM modem (1-port) converter detected
[  406.450000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB1
[  407.450000] scsi 17:0:0:0: Direct-Access     ZTE      MMC Storage      2.31 PQ: 0 ANSI: 2
[  407.470000] sd 17:0:0:0: [sdb] Attached SCSI removable disk
[  416.820000] hub 1-1:1.0: cannot reset port 4 (err = -71)
[  416.820000] hub 1-1:1.0: cannot reset port 4 (err = -71)
[  416.990000] option1 ttyUSB1: option_instat_callback: error -71
[  417.060000] usb 1-1.1: USB disconnect, device number 20
[  417.060000] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
[  417.060000] option 1-1.1:1.0: device disconnected
[  417.070000] option1 ttyUSB1: option_instat_callback: error -143
[  417.070000] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
[  417.080000] option 1-1.1:1.2: device disconnected
[  417.100000] usb 1-1.4: reset high-speed USB device number 4 using ehci-platform
[  417.210000] usb 1-1.4: device descriptor read/64, error -71
[  418.720000] sd 1:0:0:0: [sda] No Caching mode page present
[  418.720000] sd 1:0:0:0: [sda] Assuming drive cache: write through
[  422.420000] usb 1-1.1: new high-speed USB device number 21 using ehci-platform
[  422.560000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=2000
[  422.560000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3
[  422.560000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[  422.570000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[  422.570000] usb 1-1.1: SerialNumber: 3AUP673A4CDROMMS
[  422.570000] scsi18 : usb-storage 1-1.1:1.0
[  423.580000] scsi 18:0:0:0: CD-ROM            ZTE      USB SCSI CD-ROM  2.31 PQ: 0 ANSI: 2
[  435.750000] usb 1-1.1: USB disconnect, device number 21
[  440.340000] usb 1-1.1: new high-speed USB device number 22 using ehci-platform
[  440.480000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=2000
[  440.480000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=3
[  440.480000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[  440.490000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[  440.490000] usb 1-1.1: SerialNumber: 3AUP673A4CDROMMS
[  440.500000] scsi19 : usb-storage 1-1.1:1.0
[  445.990000] usb 1-1.1: USB disconnect, device number 22
[  451.350000] usb 1-1.1: new high-speed USB device number 23 using ehci-platform
[  451.490000] usb 1-1.1: New USB device found, idVendor=19d2, idProduct=0064
[  451.490000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[  451.490000] usb 1-1.1: Product: ZTE CDMA Technologies MSM
[  451.490000] usb 1-1.1: Manufacturer: ZTE,Incorporated
[  451.500000] option 1-1.1:1.0: GSM modem (1-port) converter detected
[  451.500000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB0
[  451.510000] scsi20 : usb-storage 1-1.1:1.1
[  451.510000] option 1-1.1:1.2: GSM modem (1-port) converter detected
[  451.510000] usb 1-1.1: GSM modem (1-port) converter now attached to ttyUSB1
[  452.510000] scsi 20:0:0:0: Direct-Access     ZTE      MMC Storage      2.31 PQ: 0 ANSI: 2
[  452.530000] sd 20:0:0:0: [sdb] Attached SCSI removable disk

just a note: my 3G dongle has an uSD slot, filled with a uSD with some data on.
An ok, there's no way to connect, neither with LuCI/Network/interfaces button.

I verified: this 3G dongle works fine with Ubuntu, but only if plugged before boot.
If plugged in with system on there's no way to turn on
just like with Yun. Myabe this information could help to solve the problem...

I thought it could be a problem with power supply:
the first report refers to a 5V,600mA power supply, the second to a 5V,1A one.
In the first the system seems unable to determine the Serial
in the second sometimes it does but it seems unable to maintain...

Use self power USB hub to power 3G dongle. Yun's USB only feed 4.5V, hardware bug.

http://forum.arduino.cc/index.php?topic=209836.msg1541065#msg1541065

I verified: this 3G dongle works fine with Ubuntu, but only if plugged before boot.
If plugged in with system on there's no way to turn on
just like with Yun. Myabe this information could help to solve the problem...

Use Yun's MCU to control self power USB hub power, only turn it on once CPU is finished boot.

Post at https://forum.openwrt.org/ for help, It has more 3G users.

Thank you everybody for your help!
Now I had some time to have some new tests, and this is what I obtain:

18:45:26 yun kern.info kernel: [   60.220000] usb 1-1.1.2: new high-speed USB device number 6 using ehci-platform
18:45:26 yun user.info sysinit: Generating selfsigned certificate with subject 'C=IT;ST=Turin;L=Turin;CN=Arduino LLC;' and validity 2014-05-03 16:45:25-2038-01-19 03:14:07
18:45:26 yun kern.info kernel: [   60.340000] usb 1-1.1.2: New USB device found, idVendor=19d2, idProduct=0064
18:45:26 yun kern.info kernel: [   60.340000] usb 1-1.1.2: New USB device strings: Mfr=2, Product=1, SerialNumber=0
18:45:26 yun kern.info kernel: [   60.340000] usb 1-1.1.2: Product: ZTE CDMA Technologies MSM
18:45:26 yun kern.info kernel: [   60.350000] usb 1-1.1.2: Manufacturer: ZTE,Incorporated
18:45:26 yun kern.info kernel: [   60.370000] usbserial_generic 1-1.1.2:1.0: GSM modem (1-port) converter detected
18:45:26 yun kern.info kernel: [   60.370000] usb 1-1.1.2: GSM modem (1-port) converter now attached to ttyUSB0
18:45:26 yun kern.info kernel: [   60.380000] scsi2 : usb-storage 1-1.1.2:1.1
18:45:26 yun kern.info kernel: [   60.380000] usbserial_generic 1-1.1.2:1.2: GSM modem (1-port) converter detected
18:45:26 yun kern.info kernel: [   60.380000] usb 1-1.1.2: GSM modem (1-port) converter now attached to ttyUSB1
18:45:27 yun user.notice firewall: Reloading firewall due to ifup of lan (wlan0)
18:45:28 yun kern.notice kernel: [   61.690000] scsi 2:0:0:0: Direct-Access     ZTE      MMC Storage      2.31 PQ: 0 ANSI: 2
18:45:28 yun kern.notice kernel: [   61.930000] sd 2:0:0:0: [sdb] Attached SCSI removable disk
18:45:29 yun user.info sysinit: Unknown group "netdev" in message bus configuration file
18:45:30 yun user.notice dnsmasq: DNS rebinding protection is active, will discard upstream RFC1918 responses!
18:45:30 yun user.notice dnsmasq: Allowing 127.0.0.0/8 responses
18:45:30 yun daemon.info dnsmasq[1190]: started, version 2.66 cachesize 150
18:45:30 yun daemon.info dnsmasq[1190]: compile time options: IPv6 GNU-getopt no-DBus no-i18n no-IDN DHCP no-DHCPv6 no-Lua TFTP no-conntrack no-ipset no-auth
18:45:30 yun daemon.info dnsmasq[1190]: using local addresses only for domain lan
18:45:30 yun daemon.info dnsmasq[1190]: reading /tmp/resolv.conf.auto
18:45:30 yun daemon.info dnsmasq[1190]: using nameserver 88.149.128.12#53
18:45:30 yun daemon.info dnsmasq[1190]: using nameserver 88.149.128.22#53
18:45:30 yun daemon.info dnsmasq[1190]: using local addresses only for domain lan
18:45:30 yun daemon.info dnsmasq[1190]: read /etc/hosts - 1 addresses
18:45:31 yun daemon.info avahi-daemon[1196]: Found user 'nobody' (UID 65534) and group 'nogroup' (GID 65534).
18:45:31 yun daemon.info avahi-daemon[1196]: Successfully dropped root privileges.
18:45:31 yun daemon.info avahi-daemon[1196]: avahi-daemon 0.6.31 starting up.
18:45:31 yun daemon.warn avahi-daemon[1196]: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
18:45:31 yun daemon.info avahi-daemon[1196]: Loading service file /etc/avahi/services/arduino.service.
18:45:31 yun daemon.info avahi-daemon[1196]: Loading service file /etc/avahi/services/ssh.service.
18:45:31 yun daemon.info avahi-daemon[1196]: Joining mDNS multicast group on interface wlan0.IPv4 with address 192.168.0.29.
18:45:31 yun daemon.info avahi-daemon[1196]: New relevant interface wlan0.IPv4 for mDNS.
18:45:31 yun daemon.info avahi-daemon[1196]: Network interface enumeration completed.
18:45:31 yun daemon.info avahi-daemon[1196]: Registering new address record for 192.168.0.29 on wlan0.IPv4.
18:45:31 yun daemon.info avahi-daemon[1196]: Registering HINFO record with values 'MIPS'/'LINUX'.
18:45:32 yun user.info sysinit: Start uSDaemon
18:45:32 yun daemon.info avahi-daemon[1196]: Server startup complete. Host name is yun.local. Local service cookie is 1209727940.
18:45:33 yun daemon.info avahi-daemon[1196]: Service "Secure Shell on yun" (/etc/avahi/services/ssh.service) successfully established.
18:45:33 yun daemon.info avahi-daemon[1196]: Service "yun" (/etc/avahi/services/arduino.service) successfully established.
18:45:40 yun authpriv.info dropbear[1281]: Child connection from 192.168.0.2:37807
19:00:16 yun authpriv.info dropbear[1281]: Exit before auth: Timeout before auth
19:00:20 yun authpriv.info dropbear[1387]: Child connection from 192.168.0.2:37810
19:00:28 yun authpriv.notice dropbear[1387]: Password auth succeeded for 'root' from 192.168.0.2:37810
19:00:29 yun user.notice usb-modeswitch: 1-1.1.2:1.0: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
19:00:29 yun user.notice usb-modeswitch: 1-1.1.2:1.1: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
19:00:29 yun user.notice usb-modeswitch: 1-1.1.2:1.2: Manufacturer=ZTE,Incorporated Product=ZTE_CDMA_Technologies_MSM Serial=?
19:00:30 yun daemon.notice netifd: wan2 (1801): comgt 19:00:30 -> -- Error Report --
19:00:30 yun daemon.notice netifd: wan2 (1801): comgt 19:00:30 -> ---->              ^
19:00:30 yun daemon.notice netifd: wan2 (1801): comgt 19:00:30 -> Error @114, line 9, Could not write to COM device. (1)
19:00:30 yun daemon.notice netifd: wan2 (1801): 
19:00:32 yun daemon.notice netifd: wan2 (1801): Trying to set PIN
19:00:33 yun daemon.notice netifd: wan2 (1801): PIN set successfully
19:00:33 yun daemon.notice pppd[1894]: pppd 2.4.5 started by root, uid 0
19:00:34 yun local2.info chat[1898]: abort on (BUSY)
19:00:34 yun local2.info chat[1898]: abort on (NO CARRIER)
19:00:34 yun local2.info chat[1898]: abort on (ERROR)
19:00:34 yun local2.info chat[1898]: report (CONNECT)
19:00:34 yun local2.info chat[1898]: timeout set to 10 seconds
19:00:34 yun local2.info chat[1898]: send (AT&F^M)
19:00:34 yun local2.info chat[1898]: expect (OK)
19:00:34 yun local2.info chat[1898]: ^M
19:00:34 yun local2.info chat[1898]: +ZDONR: "Not Found"^M
19:00:34 yun local2.info chat[1898]: ^M
19:00:34 yun local2.info chat[1898]: +ZPASR: "No Service"^M
19:00:34 yun local2.info chat[1898]: AT&F^M^M
19:00:34 yun local2.info chat[1898]: OK
19:00:34 yun local2.info chat[1898]:  -- got it
19:00:34 yun local2.info chat[1898]: send (ATE1^M)
19:00:34 yun local2.info chat[1898]: expect (OK)
19:00:34 yun local2.info chat[1898]: ^M
19:00:34 yun local2.info chat[1898]: ATE1^M^M
19:00:34 yun local2.info chat[1898]: OK
19:00:34 yun local2.info chat[1898]:  -- got it
19:00:34 yun local2.info chat[1898]: send (AT+CGDCONT=1,"IP","tre.it"^M)
19:00:34 yun local2.info chat[1898]: send (AT+SYSCFG=2,2,3FFFFFFF,0,4^M)
19:00:35 yun local2.info chat[1898]: timeout set to 30 seconds
19:00:35 yun local2.info chat[1898]: expect (OK)
19:00:35 yun local2.info chat[1898]: ^M
19:00:35 yun local2.info chat[1898]: AT+CGDCONT=1,"IP","tre.it"^M^M
19:00:35 yun local2.info chat[1898]: OK
19:00:35 yun local2.info chat[1898]:  -- got it
19:00:35 yun local2.info chat[1898]: send (ATD*99#^M)
19:00:35 yun local2.info chat[1898]: expect (CONNECT)
19:00:35 yun local2.info chat[1898]: ^M
19:00:35 yun local2.info chat[1898]: AT+SYSCFG=2,2,3FFFFFFF,0,4^M^M
19:00:35 yun local2.info chat[1898]: ERROR
19:00:35 yun local2.info chat[1898]:  -- failed
19:00:35 yun local2.info chat[1898]: Failed (ERROR)
19:00:35 yun daemon.err pppd[1894]: Connect script failed
19:00:46 yun daemon.info pppd[1894]: Exit.
19:00:46 yun daemon.notice netifd: Interface 'wan2' is now down
19:02:24 yun daemon.notice netifd: wan2 (1968): comgt 19:02:24 -> -- Error Report --
19:02:24 yun daemon.notice netifd: wan2 (1968): comgt 19:02:24 -> ---->                   ^
19:02:24 yun daemon.notice netifd: wan2 (1968): comgt 19:02:24 -> Error @152, line 10, Could not write to COM device. (1)
19:02:24 yun daemon.notice netifd: wan2 (1968):

So: it connects, or it seems to do, but it gets an error I can't understand, concerning AT commands and the script generated by linino_set3g.ino from PicTux

/bin/cat <<EOF > $TGCHAT
ABORT BUSY
ABORT 'NO CARRIER'
ABORT ERROR
REPORT CONNECT
TIMEOUT 10
"" "AT&F"
OK "ATE1"
OK 'AT+CGDCONT=1,"IP","\$USE_APN"'
SAY "Calling UMTS/EDGE/GPRS"
TIMEOUT 30
OK "ATD*99#"
CONNECT ''
EOF

I compared PicTux works with some guides I found online, and as far as I understand there aren't significant differences:

and

By now I don't know what to do...please help!

UPDATE: I get the same error either with a powered hub or with direct connection to Yun.

Maybe it is a problem of time...
could it be this?

People from Yun's ODM put How to configure an USB modem (3G) stick on Linino (Yun) boards

http://wiki.linino.org/doku.php?id=wiki:lininousbmodem

Much to my surprise I sought linino.org is based on US. The 3G is phase out a long time ago in US.

Hi,

old post reopened, but i'm struggling to get my Huawei 303 to work on the Yun.

Problem is, that i can't seem to be able to do the modeswitch to set the modem from
mass storage device to modem.
I'm using Putty as SSH but in every folder i try, 'usb-modeswitch' gives me a 'not found'.
aldo the package is said to be 'up to date' when i try to install it. Tried to remove and reinstall
which he does but still i can't use the modeswitch. anyone knowing in what folder this should
be located ?

this is my logread output when plugged in, and dmesg afterwards. There don't seem to be any USB assignment. :~

root@Arduino:~# logread -f
Sep  7 19:34:32 Arduino kern.info kernel: [  289.850000] usb 1-1.1: new high-spe                                                                                
ed USB device number 6 using ehci-platform
Sep  7 19:34:32 Arduino kern.info kernel: [  289.980000] usb 1-1.1: New USB devi                                                                                             
ce found, idVendor=12d1, idProduct=1f01
Sep  7 19:34:32 Arduino kern.info kernel: [  289.980000] usb 1-1.1: New USB devi                                                                                             
ce strings: Mfr=2, Product=1, SerialNumber=0
Sep  7 19:34:32 Arduino kern.info kernel: [  289.980000] usb 1-1.1: Product: HUA                                                                                             
WEI HiLink
Sep  7 19:34:32 Arduino kern.info kernel: [  289.980000] usb 1-1.1: Manufacturer                                                                                             
: HUAWEI
Sep  7 19:34:32 Arduino kern.info kernel: [  290.000000] scsi2 : usb-storage 1-1                                                                                             
.1:1.0
Sep  7 19:34:32 Arduino user.notice usb-modeswitch: 1-1.1:1.0: Manufacturer=HUAW                                                                                     
EI Product=HUAWEI_HiLink Serial=?
Sep  7 19:34:32 Arduino user.notice usb-modeswitch: 1-1.1:1.0: Selecting /etc/us                                                                                             
b_modeswitch.d/12d1:1f01 for mode switching
Sep  7 19:34:32 Arduino syslog.notice usb_modeswitch: switching device 12d1:1f01                                                                                       
on 001/006
Sep  7 19:34:33 Arduino kern.info kernel: [  290.380000] usb 1-1.1: USB disconne                                                                                             
ct, device number 6
Sep  7 19:34:34 Arduino kern.info kernel: [  291.900000] usb 1-1.1: new high-spe                                                                                             
ed USB device number 7 using ehci-platform
Sep  7 19:34:34 Arduino kern.info kernel: [  292.030000] usb 1-1.1: New USB devi                                                                                             
ce found, idVendor=12d1, idProduct=14db
Sep  7 19:34:34 Arduino kern.info kernel: [  292.030000] usb 1-1.1: New USB devi                                                                                             
ce strings: Mfr=2, Product=1, SerialNumber=0
Sep  7 19:34:34 Arduino kern.info kernel: [  292.030000] usb 1-1.1: Product: HUA                                                                                             
WEI HiLink
Sep  7 19:34:34 Arduino kern.info kernel: [  292.030000] usb 1-1.1: Manufacturer
and dmesg :

[    2.850000] ag71xx ag71xx.0: eth1: connected to PHY at ag71xx-mdio.1:04 [uid=004dd041, driver=Generic PHY]

[    2.920000] hub 1-0:1.0: 1 port detected
[    2.930000] Initializing USB Mass Storage driver...
[    2.930000] usbcore: registered new interface driver usb-storage
[    2.930000] USB Mass Storage support registered.
[    2.930000] input: gpio-keys-polled as /devices/platform/gpio-keys-polled/input/input0
[    2.940000] sdhci: Secure Digital Host Controller Interface driver
[    2.940000] sdhci: Copyright(c) Pierre Ossman
[    2.940000] usbcore: registered new interface driver ushc
[    2.940000] TCP cubic registered
[    2.950000] NET: Registered protocol family 17
[    2.950000] Bridge firewalling registered
[    2.950000] 8021q: 802.1Q VLAN Support v1.8
[    2.960000] VFS: Mounted root (squashfs filesystem) readonly on device 31:2.
[    2.960000] Freeing unused kernel memory: 180k freed
[    3.250000] usb 1-1: new high-speed USB device number 2 using ehci-platform
[    3.440000] usb 1-1: New USB device found, idVendor=058f, idProduct=6254
[    3.440000] usb 1-1: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[    3.440000] usb 1-1: Product: USB2.0Hub
[    3.580000] hub 1-1:1.0: USB hub found
[    3.580000] hub 1-1:1.0: 4 ports detected
[    3.990000] usb 1-1.1: new high-speed USB device number 3 using ehci-platform
[    4.220000] usb 1-1.1: New USB device found, idVendor=12d1, idProduct=1f01
[    4.220000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[    4.230000] usb 1-1.1: Product: HUAWEI HiLink
[    4.230000] usb 1-1.1: Manufacturer: HUAWEI
[    4.250000] scsi0 : usb-storage 1-1.1:1.0
[    4.350000] usb 1-1.4: new high-speed USB device number 4 using ehci-platform
[    4.480000] usb 1-1.4: New USB device found, idVendor=058f, idProduct=6366
[    4.480000] usb 1-1.4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    4.480000] usb 1-1.4: Product: Mass Storage Device
[    4.490000] usb 1-1.4: Manufacturer: Generic
[    4.490000] usb 1-1.4: SerialNumber: 058F0O1111B1
[    4.540000] scsi1 : usb-storage 1-1.4:1.0
[    5.070000] Error: Driver 'gpio-keys-polled' is already registered, aborting...
[    5.250000] scsi 0:0:0:0: CD-ROM            HUAWEI   Mass Storage     2.31 PQ: 0 ANSI: 2
[    5.590000] scsi 1:0:0:0: Direct-Access     Multi    Flash Reader     1.00 PQ: 0 ANSI: 0
[    6.290000] Registered led device: ds:green:usb
[    6.290000] Registered led device: ds:green:wlan
[    8.790000] JFFS2 notice: (537) jffs2_build_xattr_subsystem: complete building xattr subsystem, 1 of xdatum (1 unchecked, 0 orphan) and 15 of xref (0 dead, 4 orphan) found.
[    9.960000] sd 1:0:0:0: [sda] Attached SCSI removable disk
[   38.740000] Loading modules backported from Linux version master-2014-01-23-0-g62c147d
[   38.740000] Backport generated by backports.git backports-20140124-0-g1256d3e
[   38.840000] cfg80211: Calling CRDA to update world regulatory domain
[   38.840000] cfg80211: World regulatory domain updated:
[   38.840000] cfg80211:  DFS Master region: unset
[   38.850000] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
[   38.850000] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[   38.850000] cfg80211:   (2457000 KHz - 2482000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[   38.860000] cfg80211:   (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
[   38.860000] cfg80211:   (5170000 KHz - 5250000 KHz @ 80000 KHz), (300 mBi, 2000 mBm)
[   38.860000] cfg80211:   (5735000 KHz - 5835000 KHz @ 80000 KHz), (300 mBi, 2000 mBm)
[   38.870000] cfg80211:   (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm)
[   39.920000] ath: EEPROM regdomain: 0x0
[   39.920000] ath: EEPROM indicates default country code should be used
[   39.920000] ath: doing EEPROM country->regdmn map search
[   39.920000] ath: country maps to regdmn code: 0x3a
[   39.920000] ath: Country alpha2 being used: US
[   39.920000] ath: Regpair used: 0x3a
[   39.930000] ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
[   39.940000] Registered led device: ath9k-phy0
[   39.940000] ieee80211 phy0: Atheros AR9330 Rev:1 mem=0xb8100000, irq=2
[   39.940000] cfg80211: Calling CRDA for country: US
[   39.940000] cfg80211: Regulatory domain changed to country: US
[   39.950000] cfg80211:  DFS Master region: FCC
[   39.950000] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
[   39.950000] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2700 mBm)
[   39.960000] cfg80211:   (5170000 KHz - 5250000 KHz @ 80000 KHz), (300 mBi, 1700 mBm)
[   39.960000] cfg80211:   (5250000 KHz - 5330000 KHz @ 80000 KHz), (300 mBi, 2400 mBm)
[   39.960000] cfg80211:   (5490000 KHz - 5600000 KHz @ 80000 KHz), (300 mBi, 2400 mBm)
[   39.970000] cfg80211:   (5650000 KHz - 5710000 KHz @ 40000 KHz), (300 mBi, 2400 mBm)
[   39.970000] cfg80211:   (5735000 KHz - 5835000 KHz @ 80000 KHz), (300 mBi, 3000 mBm)
[   39.970000] cfg80211:   (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 4000 mBm)
[   40.610000] NTFS driver 2.1.30 [Flags: R/O MODULE].
[   40.680000] Error: Driver 'gpio-keys-polled' is already registered, aborting...
[   40.920000] PPP generic driver version 2.4.2
[   41.010000] ip_tables: (C) 2000-2006 Netfilter Core Team
[   41.250000] NET: Registered protocol family 24
[   41.310000] nf_conntrack version 0.5.0 (954 buckets, 3816 max)
[   41.880000] i2c /dev entries driver
[   41.930000] usbserial: Unknown parameter `maxSize'
[   41.960000] Linux video capture interface: v2.00
[   41.990000] usb_wwan: Unknown symbol usb_serial_port_softint (err 0)
[   42.020000] option: Unknown symbol usb_wwan_write (err 0)
[   42.020000] option: Unknown symbol usb_wwan_close (err 0)
[   42.020000] option: Unknown symbol usb_wwan_release (err 0)
[   42.030000] option: Unknown symbol usb_serial_disconnect (err 0)
[   42.030000] option: Unknown symbol usb_wwan_tiocmget (err 0)
[   42.030000] option: Unknown symbol usb_wwan_chars_in_buffer (err 0)
[   42.030000] option: Unknown symbol usb_wwan_write_room (err 0)
[   42.040000] option: Unknown symbol usb_wwan_disconnect (err 0)
[   42.040000] option: Unknown symbol usb_wwan_startup (err 0)
[   42.040000] option: Unknown symbol usb_wwan_set_termios (err 0)
[   42.040000] option: Unknown symbol usb_wwan_dtr_rts (err 0)
[   42.050000] option: Unknown symbol usb_wwan_open (err 0)
[   42.050000] option: Unknown symbol usb_serial_probe (err 0)
[   42.050000] option: Unknown symbol usb_serial_register (err 0)
[   42.060000] option: Unknown symbol usb_serial_deregister (err 0)
[   42.060000] option: Unknown symbol usb_wwan_ioctl (err 0)
[   42.060000] option: Unknown symbol usb_wwan_tiocmset (err 0)
[   42.160000] fuse init (API version 7.18)
[   47.950000] usb 1-1.1: USB disconnect, device number 3
[   48.190000] usb 1-1.1: new high-speed USB device number 5 using ehci-platform
[   48.320000] usb 1-1.1: New USB device found, idVendor=12d1, idProduct=14db
[   48.320000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[   48.320000] usb 1-1.1: Product: HUAWEI HiLink
[   48.320000] usb 1-1.1: Manufacturer: HUAWEI
[   52.480000] cfg80211: Calling CRDA to update world regulatory domain
[   55.650000] cfg80211: Calling CRDA to update world regulatory domain
[   55.650000] cfg80211: World regulatory domain updated:
[   55.650000] cfg80211:  DFS Master region: unset
[   55.650000] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
[   55.660000] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[   55.660000] cfg80211:   (2457000 KHz - 2482000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[   55.660000] cfg80211:   (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
[   55.670000] cfg80211:   (5170000 KHz - 5250000 KHz @ 80000 KHz), (300 mBi, 2000 mBm)
[   55.670000] cfg80211:   (5735000 KHz - 5835000 KHz @ 80000 KHz), (300 mBi, 2000 mBm)
[   55.670000] cfg80211:   (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm)
[   55.750000] wlan0: authenticate with c4:04:15:05:27:59
[   55.750000] wlan0: send auth to c4:04:15:05:27:59 (try 1/3)
[   55.760000] wlan0: authenticated
[   55.790000] wlan0: associate with c4:04:15:05:27:59 (try 1/3)
[   55.790000] wlan0: RX AssocResp from c4:04:15:05:27:59 (capab=0x411 status=0 aid=3)
[   55.790000] wlan0: associated
[  151.880000] usb 1-1.1: USB disconnect, device number 5
[  289.850000] usb 1-1.1: new high-speed USB device number 6 using ehci-platform
[  289.980000] usb 1-1.1: New USB device found, idVendor=12d1, idProduct=1f01
[  289.980000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[  289.980000] usb 1-1.1: Product: HUAWEI HiLink
[  289.980000] usb 1-1.1: Manufacturer: HUAWEI
[  290.000000] scsi2 : usb-storage 1-1.1:1.0
[  290.380000] usb 1-1.1: USB disconnect, device number 6
[  291.900000] usb 1-1.1: new high-speed USB device number 7 using ehci-platform
[  292.030000] usb 1-1.1: New USB device found, idVendor=12d1, idProduct=14db
[  292.030000] usb 1-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[  292.030000] usb 1-1.1: Product: HUAWEI HiLink
[  292.030000] usb 1-1.1: Manufacturer: HUAWEI

It looks like modeswitch is active
Sep 7 19:34:32 Arduino user.notice usb-modeswitch: 1-1.1:1.0: Selecting /etc/usb_modeswitch.d/12d1:1f01 for mode switching

Indeed, but not able to set it to the correct id for switching

The only way i got it working was to disable the cdrom mode on my windows pc following these instructions :

http://mybroadband.co.za/vb/showthread.php/507680-Huawei-HiLink-modems-(E303-E3131-etc-)?p=10250878&viewfull=1#post10250878

now the device is correctly recognized,

new problem is a faulty 3G.chat script, every AT command works fine, only the last one to connect :

OK "ATD99*1#"
or
OK "ATD
99#"

gives me ERROR.. hmm...

connect script :
ABORT BUSY
ABORT 'NO CARRIER'
ABORT ERROR
REPORT CONNECT
TIMEOUT 10
"" "AT&F"
OK "ATE1"
OK 'AT+CGDCONT=1,"IP","internet.proximus.be"'
SAY "Calling UMTS/EDGE/GPRS"
TIMEOUT 30
OK "ATD99**1#"
CONNECT ''

logread -f :

Sep  8 19:18:32 Arduino daemon.notice netifd: wan2 (25337): Trying to set mode
Sep  8 19:18:33 Arduino daemon.notice pppd[25371]: pppd 2.4.5 started by root, uid 0
Sep  8 19:18:34 Arduino local2.info chat[25375]: abort on (BUSY)
Sep  8 19:18:34 Arduino local2.info chat[25375]: abort on (NO CARRIER)
Sep  8 19:18:34 Arduino local2.info chat[25375]: abort on (ERROR)
Sep  8 19:18:34 Arduino local2.info chat[25375]: report (CONNECT)
Sep  8 19:18:34 Arduino local2.info chat[25375]: timeout set to 10 seconds
Sep  8 19:18:34 Arduino local2.info chat[25375]: send (AT&F^M)
Sep  8 19:18:34 Arduino local2.info chat[25375]: expect (OK)
Sep  8 19:18:34 Arduino local2.info chat[25375]: AT&F^M^M
Sep  8 19:18:34 Arduino local2.info chat[25375]: OK
Sep  8 19:18:34 Arduino local2.info chat[25375]:  -- got it
Sep  8 19:18:34 Arduino local2.info chat[25375]: send (ATE1^M)
Sep  8 19:18:34 Arduino local2.info chat[25375]: expect (OK)
Sep  8 19:18:34 Arduino local2.info chat[25375]: ^M
Sep  8 19:18:34 Arduino local2.info chat[25375]: ATE1^M^M
Sep  8 19:18:34 Arduino local2.info chat[25375]: OK
Sep  8 19:18:34 Arduino local2.info chat[25375]:  -- got it
Sep  8 19:18:34 Arduino local2.info chat[25375]: send (AT+CGDCONT=1,"IP","internet.proximus.be"^M)
Sep  8 19:18:34 Arduino local2.info chat[25375]: timeout set to 30 seconds
Sep  8 19:18:34 Arduino local2.info chat[25375]: expect (OK)
Sep  8 19:18:34 Arduino local2.info chat[25375]: ^M
Sep  8 19:18:34 Arduino local2.info chat[25375]: AT+CGDCONT=1,"IP","internet.proximus.be"^M^M
Sep  8 19:18:34 Arduino local2.info chat[25375]: OK
Sep  8 19:18:34 Arduino local2.info chat[25375]:  -- got it
Sep  8 19:18:34 Arduino local2.info chat[25375]: send (ATD*99***1#^M)
Sep  8 19:18:35 Arduino local2.info chat[25375]: expect (CONNECT)
Sep  8 19:18:35 Arduino local2.info chat[25375]: ^M
Sep  8 19:18:35 Arduino local2.info chat[25375]: ATD*99***1#^M^M
Sep  8 19:18:35 Arduino local2.info chat[25375]: ERROR
Sep  8 19:18:35 Arduino local2.info chat[25375]:  -- failed
Sep  8 19:18:35 Arduino local2.info chat[25375]: Failed (ERROR)
Sep  8 19:18:35 Arduino daemon.err pppd[25371]: Connect script failed
Sep  8 19:18:36 Arduino daemon.info pppd[25371]: Exit.

For everyone who has, like me, been struggling for ages to get the Huawei E303 to work on a
Yun, here's how i got it working : attach the dongle to the yun,

use lsusb to see normally this :

Bus 003 Device 008: ID 12d1:1f01 Huawei Technologies Co., Ltd.

root@Arduino:~# /usr/bin/curl -k https://raw.githubusercontent.com/pictux/Yun_3g/master/linino_set3g.sh -o /tmp/linino_set3g.sh
root@Arduino:~# /bin/chmod +x /tmp/linino_set3g.sh
root@Arduino:~# /tmp/linino_set3g.sh -p -a -d /dev/ttyUSB0

every needed file is installed this way , and the network connection is set up.

Create a file /etc/usb_modeswitch.conf and edit with :

#Huawei E303
DefaultVendor = 0x12d1
DefaultProduct = 0x1f01

Edit the file /etc/usb_modeswitch.d/12d1:1f01 :

#Huawei E303
DefaultVendor= 0x12d1
DefaultProduct= 0x1f01
TargetVendor= 0x12d1
RargetProduct= 0x1f01
MessageEndPoint = "0x01"
MessageContent="55534243000000000000000000000011060000000000000000000000000000"
NoDriverLoading=1

Reboot the system. Check with lusb to see this :

Bus 001 Device 009: ID 12d1:1001 Huawei Technologies Co., Ltd. E169/E620/E800 HSDPA Modem

Your modem should be online if everything is configured ok (APN , PIN if needed etc..)

Hope i could help someone out with this information. I had been searching the net for over a week.