xnux.eu - site map - news

Wireless Modem internet on PinePhone

The kernel needs to be configured with CONFIG_USB_NET_QMI_WWAN and qmi_wwan module needs to be loaded first.

To enable data connection you can use qmicli tool from libqmi package.

Enable modem power

echo 1 > /sys/class/modem-power/modem-power/device/powered

Configure APN

Connect to the modem once it's powered up via:

screen /dev/ttyUSB2 115200

Run the command to configure APN (may vary by operator):


Disconnect by CTRL+a k.

Start the network

qmicli -d /dev/cdc-wdm0 --wds-start-network=apn=internet --client-no-release-cid

Configure IP addresses:

qmicli -d /dev/cdc-wdm0 --wds-get-current-settings
[/dev/cdc-wdm0] Current settings retrieved:
           IP Family: IPv4
        IPv4 address:
    IPv4 subnet mask:
IPv4 gateway address:
    IPv4 primary DNS:
  IPv4 secondary DNS:
                 MTU: 1500
             Domains: none
ip a add dev wwan0
ip r add default via

And if you want the mobile operator's DNS servers, add them to resolv.conf.