QMICLI

Marco Salatin marco.salatin at gmail.com
Thu Oct 8 09:56:06 UTC 2020


ok
i write to share where i'm arrived.

internetConnection():
     if thereAreInternetConnection (use what you want (PING, SOCKET, HTTP
Request, i use PING because use less data)
          return true.
    else
         return false

while:
     if internetConnection():
        print(you are connect)
     else:
        close old connection if exist an old connection (qmicli -d
/dev/cdc-wdm0 -p --wds-stop-network="YOURPDH" --client-cid="YOURCID")

       open new connection:
             qmicli -d /dev/cdc-wdm0 -p --nas-force-network-search
             qmicli -d /dev/cdc-wdm0 -p
--device-open-"net=net-raw-ip|net-no-qos-header" --wds-start-network="apn=
apn.fastweb.it,ip-type=4" --client-no-release-cid
             ip link set dev wwan0 down
             echo 'Y' | sudo tee /sys/class/net/wwan0/qmi/raw_ip
             ip link set dev wwan0 up








Il giorno gio 8 ott 2020 alle ore 11:38 Aleksander Morgado <
aleksander at aleksander.es> ha scritto:

> Hey,
>
> > also have this problem:
> > qmicli -d /dev/cdc-wdm0 -p --nas-get-signal-strength
> > error: couldn't create client for the 'nas' service: QMI protocol error
> (5): 'ClientIdsExhausted'
> >
>
> That looks like you're running qmicli commands with
> --client-no-release-cid and so the client ids end up exhausted. You
> should reuse the QMI clients properly.
>
> It really looks like you should spend some time investigating and
> understanding how all this works. Don't ask a question for every
> problem you have, try to look for the answer yourself and only if you
> don't find it, come back asking in the mailing list ;)
>
> --
> Aleksander
> https://aleksander.es
>


-- 


*Marco Salatin*T. +39 388 1947558

skype: marco.salatin

marco.salatin at gmail.com
Sito web: www.salatin.eu

Ai sensi del D.Lgs. 196/2003 si precisa che le informazioni contenute in
questo messaggio sono riservate ed a uso esclusivo del destinatario.
Qualora il messaggio in parola Le fosse pervenuto per errore, La invito ad
eliminarlo senza copiarlo e a non inoltrarlo a terzi, dandomene gentilmente
comunicazione. Grazie.
Pursuant to Legislative Decree No. 196/2003, you are hereby informed that
this message contains confidential information intended only for the use of
the addressee. If you are not the addressee, and have received this message
by mistake, please delete it and immediately notify us. You may not copy or
disseminate this message to anyone. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libqmi-devel/attachments/20201008/f597c85b/attachment.htm>


More information about the libqmi-devel mailing list