USB mobile broadband

Hello, would it be possible for My OSMC/Network-section to have an option to set up and configure 3G/4G USB mobile broadband for internet connection?

In the future, we could explore offering this solution from My OSMC. I don’t know if anyone on the team has a 3G dongle, but I will enquire.

For now, it would be good to explore the possibility of setting it up via the command line (connmanctl), so we can work out how much work (and what) needs to be done.

I would start with installing a couple of necessary packages:

sudo apt-get install ofono usb-modeswitch

Now, you can run

sudo connmanctl

If your modem is picked up by the kernel, you should see

connmanctl technologies

list 3G as an option, in which case you should be able to enable it with

connmanctl enable 3g

And then you’re on your own, because I don’t have a dongle at hand.

Sam

Hello Sam
Any changes in this item?
After
connmanctl technologies
I received
Error getting VPN connections: The name net.connman.vpn was not provided by any
connmanctl>
After lsusb I saw:
Bus 001 Device 005: ID 12d1:1446 Huawei Technologies Co., Ltd. E1552/E1800/E173 (HSPA modem)
What can I try next?
I have Huawei E1750 modem, RPi3 and last version of OSMC.
Can I try this SW?
http://www.sakis3g.com/

Thanks for your help
Jan

Did you try my suggestions above?

I’ll see if I can get hold of a USB modem and add support in a new version of My OSMC. You should also check (ifconfig) to verify that your USB modem has a driver for it.

Sam

Yes.
I already install ofono usb-modeswitch before sudo connmanctl
Instead some list with connmanctl technologies I recieved error message

osmc@osmc:~$ sudo connmanctl technologies

/net/connman/technology/bluetooth
Name = Bluetooth
Type = bluetooth
Powered = False
Connected = False
Tethering = False
/net/connman/technology/ethernet
Name = Wired
Type = ethernet
Powered = True
Connected = True
Tethering = False
/net/connman/technology/wifi
Name = WiFi
Type = wifi
Powered = False
Connected = False
Tethering = False
osmc@osmc:~$

sudo ifconfig
eth0 Link encap:Ethernet HWaddr b8:27:eb:c5:f0:bb
inet addr:192.168.100.16 Bcast:192.168.100.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST DYNAMIC MTU:1500 Metric:1
RX packets:8713 errors:0 dropped:0 overruns:0 frame:0
TX packets:6790 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:5736837 (5.4 MiB) TX bytes:942193 (920.1 KiB)

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:65536 Metric:1
RX packets:166 errors:0 dropped:0 overruns:0 frame:0
TX packets:166 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1
RX bytes:56544 (55.2 KiB) TX bytes:56544 (55.2 KiB)

I have just had a long play with an old dongle (ZTE MF627) on both a PC (Linux Mint) and OSMC on RPi. The procedures are similar except with OSMC you need to install package ppp and, I think, hal-info (which is not in the repo but is just a bunch of files which I copied across from the PC). I can get the dongle to connect with terminal commands and if I disconnect the WiFi, System info → Network reports the IP of the mobile broadband connection. It comes up in ifconfig as ppp0 but it doesn’t show up in MyOSMC as a wired connection and can’t be selected for tethering.

I know it’s on-line because I can ping 8.8.8.8 through it but I can’t ping www.google.com ie it doesn’t seem to know a DNS. So I haven’t got it streaming on-line content yet. On the PC it works fine. The steps are:

  1. Make sure dongle is recognised (ie has a driver) by looking at dmesg
  2. Install hal-info or at least make sure you’ve got
    /usr/share/hal/fdi/information/10freedesktop/10-modem.fdi
  3. Install usb-modeswitch
  4. Download http://www.draisberghof.de/usb_modeswitch/device_reference.txt and
    copy the bit of that which refers to your dongle into
    /etc/usb_modeswitch.conf, which should have been created when you
    installed the package.
  5. if you installed ofono, uninstall it and re-boot
  6. run sudo usb_modeswitch -c /etc/usb_modeswitch.conf and check lsusb to see if it’s done it’s stuff (product ID and description should change)
  7. Install ppp
  8. Download and unzip sakis3g
  9. Run sudo sakis3g --interactive “connect” and follow the prompts

I’m not saying that’s the only/best way to do it, but it works up to a point. Main references:

https://www.thefanclub.co.za/how-to/how-setup-usb-3g-modem-raspberry-pi-using-usbmodeswitch-and-wvdial

Sakis3g is better than using pon or wvdial as it gives you better feedback and is cleverer (eg it found that my modem was on /dev/ttyUSB2, not the other two ports)