Sierra EM/MC7455 get current connection state?
Sebastian Sjoholm
sebastian.sjoholm at gmail.com
Thu Jan 12 17:27:21 UTC 2017
> On Jan 12, 2017, at 18:15 , Aleksander Morgado <aleksander at aleksander.es> wrote:
>
> On Thu, Jan 12, 2017 at 6:00 PM, Fabian Schörghofer
> <fabian.schoergi at gmail.com> wrote:
>> is it possible to query the current state of the connection?
>> Some background info: My ISP disconnects the modem every 24 hours. The
>> interface on the host will still use the old IP and won't get any info
>> that a disconnect has happened.
>>
>> Is there some AT/QMI command that will show the current status of the
>> connection? Without ICMP or other IP related stuff?
>>
>> My previous device (E3372 with huawei_ether) had this functionality,
>> although on a driver level. If a 24hrs disconnected happened, the
>> interface on the host "lost" the IP address.
>
> Does qmicli -d /dev/cdc-wdmX --wds-get-packet-service-status help?
>
>
I have been using the “wds-get-packet-service-status” for this, and it has been working well. I guess the “wds-get-current-settings” could work as well. (below from EM7455)
Connected:
# qmicli -d /dev/cdc-wdm0 --wds-get-current-settings
[/dev/cdc-wdm0] Current settings retrieved:
IP Family: IPv4
IPv4 address: 10.39.9.18
IPv4 subnet mask: 255.255.255.252
IPv4 gateway address: 10.39.9.17
IPv4 primary DNS: 172.32.55.20
IPv4 secondary DNS: 172.32.55.21
MTU: 1500
Domains: none
# qmicli -d /dev/cdc-wdm0 --wds-get-packet-service-status
[/dev/cdc-wdm0] Connection status: 'connected’
#
Disconnected:
# qmicli -d /dev/cdc-wdm0 --wds-get-current-settings
error: couldn't get current settings: QMI protocol error (15): 'OutOfCall'
# qmicli -d /dev/cdc-wdm0 --wds-get-packet-service-status
[/dev/cdc-wdm0] Connection status: 'disconnected’
#
-Sebastian
More information about the libqmi-devel
mailing list