[PATCH 2/2] huawei: implement modem reset via +CFUN=16 for MU736
Ben Chan
benchan at chromium.org
Tue Aug 13 00:54:43 PDT 2013
---
plugins/huawei/mm-broadband-modem-huawei.c | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/plugins/huawei/mm-broadband-modem-huawei.c b/plugins/huawei/mm-broadband-modem-huawei.c
index 3cd3201..3d0d807 100644
--- a/plugins/huawei/mm-broadband-modem-huawei.c
+++ b/plugins/huawei/mm-broadband-modem-huawei.c
@@ -439,8 +439,19 @@ reset (MMIfaceModem *self,
GAsyncReadyCallback callback,
gpointer user_data)
{
+ const gchar *command;
+
+ /* Unlike other Huawei modems that support AT^RESET for resetting the modem,
+ * Huawei MU736 supports AT^RESET but does not reset the modem upon receiving
+ * AT^RESET. It does, however, support resetting itself via AT+CFUN=16.
+ */
+ if (g_strcmp0 (MM_BROADBAND_MODEM_HUAWEI (self)->priv->model, "MU736") == 0)
+ command = "+CFUN=16";
+ else
+ command = "^RESET";
+
mm_base_modem_at_command (MM_BASE_MODEM (self),
- "^RESET",
+ command,
3,
FALSE,
callback,
--
1.8.3
More information about the ModemManager-devel
mailing list