base-modem-at: new `mm_base_modem_at_command_raw()'
Equivalent to `mm_base_modem_at_command()', but with a raw setup.
This commit is contained in:
@@ -561,13 +561,14 @@ mm_base_modem_at_command_finish (MMBaseModem *self,
|
|||||||
return mm_base_modem_at_command_full_finish (self, res, error);
|
return mm_base_modem_at_command_full_finish (self, res, error);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
static void
|
||||||
mm_base_modem_at_command (MMBaseModem *self,
|
_at_command (MMBaseModem *self,
|
||||||
const gchar *command,
|
const gchar *command,
|
||||||
guint timeout,
|
guint timeout,
|
||||||
gboolean allow_cached,
|
gboolean allow_cached,
|
||||||
GAsyncReadyCallback callback,
|
gboolean is_raw,
|
||||||
gpointer user_data)
|
GAsyncReadyCallback callback,
|
||||||
|
gpointer user_data)
|
||||||
{
|
{
|
||||||
MMAtSerialPort *port;
|
MMAtSerialPort *port;
|
||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
@@ -588,8 +589,30 @@ mm_base_modem_at_command (MMBaseModem *self,
|
|||||||
command,
|
command,
|
||||||
timeout,
|
timeout,
|
||||||
allow_cached,
|
allow_cached,
|
||||||
FALSE,
|
is_raw,
|
||||||
NULL,
|
NULL,
|
||||||
callback,
|
callback,
|
||||||
user_data);
|
user_data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
mm_base_modem_at_command (MMBaseModem *self,
|
||||||
|
const gchar *command,
|
||||||
|
guint timeout,
|
||||||
|
gboolean allow_cached,
|
||||||
|
GAsyncReadyCallback callback,
|
||||||
|
gpointer user_data)
|
||||||
|
{
|
||||||
|
_at_command (self, command, timeout, allow_cached, FALSE, callback, user_data);
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
mm_base_modem_at_command_raw (MMBaseModem *self,
|
||||||
|
const gchar *command,
|
||||||
|
guint timeout,
|
||||||
|
gboolean allow_cached,
|
||||||
|
GAsyncReadyCallback callback,
|
||||||
|
gpointer user_data)
|
||||||
|
{
|
||||||
|
_at_command (self, command, timeout, allow_cached, TRUE, callback, user_data);
|
||||||
|
}
|
||||||
|
@@ -138,6 +138,13 @@ void mm_base_modem_at_command (MMBaseModem *self,
|
|||||||
gboolean allow_cached,
|
gboolean allow_cached,
|
||||||
GAsyncReadyCallback callback,
|
GAsyncReadyCallback callback,
|
||||||
gpointer user_data);
|
gpointer user_data);
|
||||||
|
/* Like mm_base_modem_at_command() except does not prefix with AT */
|
||||||
|
void mm_base_modem_at_command_raw (MMBaseModem *self,
|
||||||
|
const gchar *command,
|
||||||
|
guint timeout,
|
||||||
|
gboolean allow_cached,
|
||||||
|
GAsyncReadyCallback callback,
|
||||||
|
gpointer user_data);
|
||||||
const gchar *mm_base_modem_at_command_finish (MMBaseModem *self,
|
const gchar *mm_base_modem_at_command_finish (MMBaseModem *self,
|
||||||
GAsyncResult *res,
|
GAsyncResult *res,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
Reference in New Issue
Block a user