diff options
author | Marcel Holtmann <marcel@holtmann.org> | 2010-04-01 20:06:31 -0700 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2010-04-01 20:06:31 -0700 |
commit | cb791ceb78bbeeb3ae0e504dbed0357a3fd29906 (patch) | |
tree | 5c22e1761e4ffb7b6ad54030ef814b09d06a1375 /gatchat/gsmdial.c | |
parent | 847e7c7f147ae192f544dee82f81137e46ba2d9f (diff) | |
download | ofono-cb791ceb78bbeeb3ae0e504dbed0357a3fd29906.tar.bz2 |
Remove usage of AT+CGACT for now
Diffstat (limited to 'gatchat/gsmdial.c')
-rw-r--r-- | gatchat/gsmdial.c | 27 |
1 files changed, 5 insertions, 22 deletions
diff --git a/gatchat/gsmdial.c b/gatchat/gsmdial.c index 63f1c0f9..0a833c3b 100644 --- a/gatchat/gsmdial.c +++ b/gatchat/gsmdial.c @@ -285,20 +285,6 @@ static void connect_cb(gboolean ok, GAtResult *result, gpointer user_data) g_at_ppp_open(ppp); } -static void at_cgact_up_cb(gboolean ok, GAtResult *result, gpointer user_data) -{ - char buf[64]; - - if (!ok) { - g_print("Error activating context\n"); - exit(1); - } - - sprintf(buf, "AT+CGDATA=\"PPP\",%u", option_cid); - - g_at_chat_send(modem, buf, none_prefix, connect_cb, NULL, NULL); -} - static void at_cgdcont_cb(gboolean ok, GAtResult *result, gpointer user_data) { char buf[64]; @@ -308,15 +294,12 @@ static void at_cgdcont_cb(gboolean ok, GAtResult *result, gpointer user_data) exit(1); } - if (option_legacy == TRUE) { + if (option_legacy == TRUE) sprintf(buf, "ATD*99***%u#", option_cid); - g_at_chat_send(modem, buf, none_prefix, - connect_cb, NULL, NULL); - } else { - sprintf(buf, "AT+CGACT=1,%u", option_cid); - g_at_chat_send(control, buf, none_prefix, - at_cgact_up_cb, NULL, NULL); - } + else + sprintf(buf, "AT+CGDATA=\"PPP\",%u", option_cid); + + g_at_chat_send(modem, buf, none_prefix, connect_cb, NULL, NULL); } static void setup_context(int status) |