<div dir="ltr">Thanks for prompt response,<div>I used att information to make a bearer, I get ppp but I dont see any IP in ifconfig, neither the PPP network interface comes as ppp0, which normally comes in wvdial. </div><div>So I am stuck there.</div><div><br></div><div><br></div><div><div>mmcli -m 0 --create-bearer="apn=wap.cingular,user=<a href="mailto:wap@cingulargprs.com">wap@cingulargprs.com</a>,password=CINGULAR1,number=*99***1#"</div></div><div><div>Successfully created new bearer in modem:</div><div><span class="" style="white-space:pre"> </span>/org/freedesktop/ModemManager1/Bearer/0</div><div>priyank@priyank-desktop:/opt/crossbar/site-packages$ mmcli -b 0</div><div>Bearer '/org/freedesktop/ModemManager1/Bearer/0'</div><div><br></div><div><div>priyank@priyank-desktop:/opt/crossbar/site-packages$ mmcli -m 0 -c -b /org/freedesktop/ModemManager1/Bearer/0</div><div>successfully connected the bearer</div><div>priyank@priyank-desktop:/opt/crossbar/site-packages$ mmcli -b 0</div><div>Bearer '/org/freedesktop/ModemManager1/Bearer/0'</div><div> -------------------------</div><div> Status | connected: 'yes'</div><div> | suspended: 'no'</div><div> | interface: 'ttyUSB0'</div><div> | IP timeout: '20'</div><div> -------------------------</div><div> Properties | apn: 'wap.cingular'</div><div> | roaming: 'allowed'</div><div> | IP type: 'none'</div><div> | user: '<a href="mailto:wap@cingulargprs.com">wap@cingulargprs.com</a>'</div><div> | password: 'CINGULAR1'</div><div> | number: '*99***1#'</div><div> | Rm protocol: 'unknown'</div><div> -------------------------</div><div> IPv4 configuration | method: 'ppp'</div><div> -------------------------</div><div> IPv6 configuration | method: 'unknown'</div></div><div><br></div><div> </div></div><div><br></div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Sep 23, 2015 at 1:16 AM, Aleksander Morgado <span dir="ltr"><<a href="mailto:aleksander@aleksander.es" target="_blank">aleksander@aleksander.es</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Wed, Sep 23, 2015 at 9:17 AM, Priyank Kumar <<a href="mailto:priyank.guddu@gmail.com">priyank.guddu@gmail.com</a>> wrote:<br>
> I am trying to connect a modem on Ubuntu 14.04.<br>
> Everything works fine, i.e modem is enabled, I can send and receive SMS<br>
> through mmcli.<br>
> The problem I am facing is that once a bearer is created with right APN and<br>
> username and password, I can connect to modem but dont get any IP.<br>
><br>
> How to get the network interface, couldnt find anything on documentation.<br>
> Also I see enum to see like PPP/STATIC/DHCP etc, but dont know where to feed<br>
> that field.<br>
><br>
> It would be really useful if one example is given on mmcli or dbus API how<br>
> to do the connect and disconnect to packet service.<br>
> When to know which port data packet get through (QMI/AT or other) ?<br>
> Also is there a dbus API to send AT command, i see mmcli has some commands.?<br>
> Also do we have dbus api for libqmi and libqcdm?<br>
><br>
> Thanks.<br>
><br>
><br>
> mmcli -m 1<br>
><br>
><br>
><br>
> -------------------------<br>
> Hardware | manufacturer: 'QUALCOMM INCORPORATED'<br>
> | model: 'HSUPA'<br>
> | revision: 'WUP_1.10.037'<br>
> | supported: 'gsm-umts'<br>
> | current: 'gsm-umts'<br>
> | equipment id: '359769022304908'<br>
> -------------------------<br>
> System | device:<br>
> '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2.4/1-2.4.3'<br>
> | drivers: 'option1'<br>
> | plugin: 'Generic'<br>
> | primary port: 'ttyUSB0'<br>
> | ports: 'ttyUSB0 (at), ttyUSB1 (qcdm), ttyUSB2 (at)'<br>
> -------------------------<br>
> Numbers | own : '185824xxxx'<br>
> -------------------------<br>
> Status | lock: 'none'<br>
> | unlock retries: 'unknown'<br>
> | state: 'connected'<br>
> | power state: 'on'<br>
> | access tech: 'gprs'<br>
> | signal quality: '20' (recent)<br>
> -------------------------<br>
> Modes | supported: 'allowed: 2g, 3g; preferred: none'<br>
> | current: 'allowed: 2g, 3g; preferred: none'<br>
> -------------------------<br>
> Bands | supported: 'unknown'<br>
> | current: 'unknown'<br>
> -------------------------<br>
> IP | supported: 'ipv4, ipv6'<br>
> -------------------------<br>
> 3GPP | imei: '359769022304908'<br>
> | enabled locks: 'none'<br>
> | operator id: '310410'<br>
> | operator name: 'AT&T'<br>
> | registration: 'home'<br>
> -------------------------<br>
> SIM | path: '/org/freedesktop/ModemManager1/SIM/1'<br>
><br>
> Syslog:<br>
> ModemManager[701]: message repeated 6 times: [ <info> Modem<br>
> /org/freedesktop/ModemManager1/Modem/1: signal quality updated (20)]<br>
> Sep 23 00:05:42 priyank-desktop ModemManager[701]: <info> Modem<br>
> /org/freedesktop/ModemManager1/Modem/1: state changed (registered -><br>
> connecting)<br>
> Sep 23 00:05:42 priyank-desktop NetworkManager[803]: <info> (ttyUSB0) modem<br>
> state changed, 'registered' --> 'connecting' (reason: user-requested)<br>
> Sep 23 00:05:42 priyank-desktop ModemManager[701]: <info> Modem<br>
> /org/freedesktop/ModemManager1/Modem/1: state changed (connecting -><br>
> connected)<br>
> Sep 23 00:05:42 priyank-desktop NetworkManager[803]: <info> (ttyUSB0) modem<br>
> state changed, 'connecting' --> 'connected' (reason: user-requested)<br>
> Sep 23 00:06:10 priyank-desktop ModemManager[701]: <info> Modem<br>
> /org/freedesktop/ModemManager1/Modem/1: signal quality updated (20)<br>
<br>
<br>
</div></div>You need to check the *bearer* object in DBus to know the connection<br>
details, once connected.<br>
<br>
You can check the list of available bearers with:<br>
$ mmcli --list-bearers<br>
<br>
And once you know which one to check, you can query its info, e.g.:<br>
$ mmcli -b 0<br>
<br>
That will tell you which IP method to use (ppp, dhcp, static) and all<br>
the other info.<br>
<br>
Also, when you run --simple-connect you should get as output which of<br>
the bearers just got connected.<br>
<span class="HOEnZb"><font color="#888888"><br>
<br>
--<br>
Aleksander<br>
<a href="https://aleksander.es" rel="noreferrer" target="_blank">https://aleksander.es</a><br>
</font></span></blockquote></div><br></div>