wwan0 interface without IP
hi !!
i'm back with my project using ofono/connman/sierra 3G modem...
now my modem work fine with ofono until connection. i can see IP address with ofono in debug mode (response from !SCPADDR command) interface wwan0 is UP... but without IPV4 parameters.. (only MAC address)
i can't go to internet with this.
i have try to put connman in debug mode too, and get an error because IPAddress is not set.
at this time, if i start udhcpc -i wwan0... connection is made and work fine....
few seconds only after a very short time, connman say idle timeout and ofono goes offline.
i mean there is something wrong in ofono... (or connman ? don't know..)
someone can help me ?
thank you so much
Hi Eric,
Quoted 8 lines · Eric BOUXIROT
hi !!
i'm back with my project using ofono/connman/sierra 3G modem...
now my modem work fine with ofono until connection. i can see IP address with ofono in debug mode (response from !SCPADDR command) interface wwan0 is UP... but without IPV4 parameters.. (only MAC address) i can't go to internet with this.
oFono does not assign the IP parameters. ConnMan does that or you need to do this some other way.
Quoted 7 lines
i have try to put connman in debug mode too, and get an error because IPAddress is not set.
at this time, if i start udhcpc -i wwan0... connection is made and work fine....
Quoted 6 lines
few seconds only after a very short time, connman say idle timeout and ofono goes offline.
i mean there is something wrong in ofono... (or connman ? don't know..)
someone can help me ?
Not really enough information. If oFono establishes the connection successfully, then likely you need to look more closely at what is happening with ConnMan.
Regards,
-Denis
Quoted 2 lines
oFono does not assign the IP parameters. ConnMan does that or you need to do this some other way.
i'm right with you but i don't know how ofono deal with connman to trig DHCP.
i know ofono send some parameters (or connman read it on ofono..) like "method" "address" etc..
i know when reading "address" the result is NULL and fail next step in connman du to NULL.
i have made a test patch that put "0.0.0.0" in address in swmodem/gprs_context.c after connect success, but it seem connman always read NULL..
then, i search more what's happend.
I found a solution with connman's ofono plugin that need to be patched.
Now that work great, but i mean there something wrong between ofono/connman altought for this modem.
Hi Eric,
Quoted 10 lines · Eric BOUXIROT
Quoted 2 lines
oFono does not assign the IP parameters. ConnMan does that or you need to do this some other way.
i'm right with you but i don't know how ofono deal with connman to trig DHCP.
i know ofono send some parameters (or connman read it on ofono..) like "method" "address" etc..
i know when reading "address" the result is NULL and fail next step in connman du to NULL.
After activating the context, run test/list-contexts in oFono git. What does it say?
Regards,
-Denis
Quoted 2 lines
After activating the context, run test/list-contexts in oFono git. What does it say?
/usr/lib/ofono/test/list-contexts
[ /sierra_1 ]
[ /sierra_1/context1 ]
Username =
Protocol = ip
Name = Internet
Settings = { Interface=wwan0 Method=dhcp } IPv6.Settings = { }
Active = 1
AccessPointName = objcPpublic Password =
Type = internet
for me it's ok. i have made a test to add a "address" to 0.0.0.0 and get this.
/usr/lib/ofono/test/list-contexts
[ /sierra_1 ]
[ /sierra_1/context1 ]
Username =
Protocol = ip
Name = Internet
Settings = { Interface=wwan0 Method=dhcp Address=0.0.0.0 } IPv6.Settings = { }
Active = 1
AccessPointName = objcPpublic
Password =
Type = internet
but in either cases i got connman getting an address..
Quoted 2 lines
oFono does not assign the IP parameters. ConnMan does that or you need to do this some other way.
forget to tell, i must apply this patch too, because my modem do not reconize the command and ofono fail.
diff -uprN a/drivers/swmodem/gprs-context.c b/drivers/swmodem/gprs-context.c
--- a/drivers/swmodem/gprs-context.c 2012-07-02 09:55:34.000000000
+0200
+++ b/drivers/swmodem/gprs-context.c 2014-03-27 23:08:44.904767915
+0100
@@ -100,9 +100,6 @@ static void at_scact_up_cb(gboolean ok,
snprintf(buf, sizeof(buf), "AT!SCPADDR=%u", gcd->active_context); g_at_chat_send(gcd->chat, buf, none_prefix, NULL, NULL, NULL);
- snprintf(buf, sizeof(buf), "AT+CGCONTRDP=%u", gcd->active_context);
- g_at_chat_send(gcd->chat, buf, none_prefix, NULL, NULL, NULL);
-
modem = ofono_gprs_context_get_modem(gc);
interface = ofono_modem_get_string(modem, "NetworkInterface");