Automatic Activation, Hotplug and UDEV, Configuration
Post Reply
sph
Posts: 2
Joined: 01 Jan 2020, 19:14

Switch to modem and connect to the Internet at boot time?

Post by sph » 01 Jan 2020, 19:56

I have the following set-up:
  • Raspberry Pi 1 Model B
  • Raspbian 8 (Flavour Volumio)
  • Huawei E8372h LTE dongle
  • USB hub with external power supply for the E8372h (needed, because the E8372h draws too much power for the RPi)
What is working:
  1. LTE dongle powered up and connected to mobile network, before I power up the RPi.
  2. RPi up and running and I plug in the dongle.
In both cases USB_ModeSwitch switches from mass storage device to modem and networking.service is able to connect via ethx.

What is not working:

I power up the RPi and the dongle at the same time. This leaves me with the dongle switched to modem mode (and it itself connected to the mobile internet), but the RPi is not connected to the Internet.

To get the RPi to connect to the Internet, the solution is either to
  • Unplug the dongle and plug it in again.
  • Log into the console and run "systemctl reload networking.service".
I assume, this is a timing issue between USB_ModeSwitch and systemd's networking.service, but I don't know. I don't even know if this is the right place to ask or I must head to the systemd forum. But I have to start somewhere, don't I?

Does anybody here know how I can get the RPi to boot at the same time as the E8372h and connect to the Internet without resorting to manually logging in or power cycle the dongle?

I attach the boot logs for
  1. boot.log
    Boot log when the dongle is switched on before the RPi.
    (6.23 KiB) Downloaded 477 times
    booting with the dongle already up and running
  2. boot1.log
    Boot log when the dongle and the RPi are powered on at the same time.
    (12.32 KiB) Downloaded 484 times
    booting with the dongle powered on at the same time as the RPi
I also can also supply the output of the dmesg command if required.

Thanks.

LOM
Posts: 1404
Joined: 11 Jul 2012, 15:14
Location: Koh Samui, TH

Re: Switch to modem and connect to the Internet at boot time?

Post by LOM » 02 Jan 2020, 04:22

This is not likely to be a usb_modeswitch problem if you can solve it by reloading networking services.
I guess you are running ancient linux kernel version and modemmanager/networkmanager versions, update first before taking your problem to systemd or networkmanager mailing lists.

sph
Posts: 2
Joined: 01 Jan 2020, 19:14

Re: Switch to modem and connect to the Internet at boot time?

Post by sph » 19 Jan 2020, 23:25

Since this is Volumio (http://volumio.org), it is not easy to update without side effects. But I compiled and installed the latest USB_ModeSwitch, but it did not get better. In the meanwhile I switched to moOdeaudio (https://moodeaudio.org/) and there everything works fine.

kane_C
Posts: 1
Joined: 26 Feb 2024, 08:52

Re: Switch to modem and connect to the Internet at boot time?

Post by kane_C » 26 Feb 2024, 08:56

Some things you can try:

Check if it can be configured to work automatically when both the Raspberry Pi and the dongle are turned on at the same time. You may need to adjust the boot order of your devices to ensure they start at the same time.

Consider tweaking the startup times of services like USB_ModeSwitch and networking.service to ensure they operate properly and in sync.

If the problem is time related, you can use a time calculator such as time calculator to determine the time gap between events and adjust the start time.

Post Reply