ModemManager-1.6.2: does not work with Huawei E3372h-153

Aleksander Morgado aleksander at aleksander.es
Thu Jan 12 15:25:33 UTC 2017


On Thu, Jan 12, 2017 at 3:49 PM, Martin MOKREJŠ <mmokrejs at gmail.com> wrote:
> # mmcli  --connect -m /org/freedesktop/ModemManager1/Modem/0
> error: no bearer was specified

--connect is a bearer action, you need to pass a bearer object path,
not a modem object path.

> # mmcli  --list-bearers -m /org/freedesktop/ModemManager1/Modem/0
>
> No bearers were found

Ok, so you would first need to create a bearer with
--create-bearer="key=value,..." in one of the modems.

E.g.

mmcli -m 0 --create-bearer="apn=internet"

See:
https://www.freedesktop.org/software/ModemManager/api/latest/gdbus-org.freedesktop.ModemManager1.Modem.html#gdbus-method-org-freedesktop-ModemManager1-Modem.CreateBearer

> # mmcli  --bearer -m /org/freedesktop/ModemManager1/Modem/0
> error: invalid path or index string specified: '-m'

--bearer expects a bearer path or index (help says "--bearer=[PATH|INDEX]")

> # mmcli  --bearer
> error: no actions specified

Same thing, --bearer expects a bearer path or index (help says
"--bearer=[PATH|INDEX]")

> # mmcli  -b
> error: no actions specified

Same thing, --bearer expects a bearer path or index (help says
"--bearer=[PATH|INDEX]")

> # mmcli  -b -m /org/freedesktop/ModemManager1/Modem/0
> error: invalid path or index string specified: '-m'

Same thing, --bearer expects a bearer path or index (help says
"--bearer=[PATH|INDEX]")

>
>
> # mmcli  --set-power-state-on -m /org/freedesktop/ModemManager1/Modem/0
> error: couldn't set new power state in the modem: 'GDBus.Error:org.freedesktop.ModemManager1.Error.Core.WrongState: Cannot set power state: not in disabled state'

Your modem is already registered, so it is already in "on" power state.

>
> The mmcli --help-all are too cryptic to me. I failed to find a way to really get the device connected. There should be some typical examples at the end of --help-all output. Even figuring out I need to specify "-m /org/freedesktop/ModemManager1/Modem/0" took me a long while. Why sometimes it is rejected as a wrong argument I do not know (shown above).

For launching a connection you can use the "manual" way of creating
the bearer object and then --connect; OR, easier, just
"--simple-connect" in the modem object. E.g.:

mmcli -m 0 --simple-connect="apn=internet"

See https://www.freedesktop.org/software/ModemManager/api/latest/gdbus-org.freedesktop.ModemManager1.Modem.Simple.html#gdbus-method-org-freedesktop-ModemManager1-Modem-Simple.Connect

Cheers!

-- 
Aleksander
https://aleksander.es


More information about the ModemManager-devel mailing list