diff options
Diffstat (limited to 'src/mm-port-probe.c')
-rw-r--r-- | src/mm-port-probe.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/mm-port-probe.c b/src/mm-port-probe.c index 3d9cd37c..f30e8fdc 100644 --- a/src/mm-port-probe.c +++ b/src/mm-port-probe.c @@ -78,6 +78,8 @@ typedef struct { GCancellable *at_probing_cancellable; /* Send delay for AT commands */ guint64 at_send_delay; + /* Flag to leave/remove echo in AT responses */ + gboolean at_remove_echo; /* Number of times we tried to open the AT port */ guint at_open_tries; /* Custom initialization setup */ @@ -904,9 +906,10 @@ serial_open_at (MMPortProbe *self) } g_object_set (task->serial, - MM_SERIAL_PORT_SEND_DELAY, task->at_send_delay, - MM_PORT_CARRIER_DETECT, FALSE, - MM_SERIAL_PORT_SPEW_CONTROL, TRUE, + MM_SERIAL_PORT_SEND_DELAY, task->at_send_delay, + MM_AT_SERIAL_PORT_REMOVE_ECHO, task->at_remove_echo, + MM_PORT_CARRIER_DETECT, FALSE, + MM_SERIAL_PORT_SPEW_CONTROL, TRUE, NULL); mm_at_serial_port_set_response_parser (MM_AT_SERIAL_PORT (task->serial), @@ -1025,6 +1028,7 @@ void mm_port_probe_run (MMPortProbe *self, MMPortProbeFlag flags, guint64 at_send_delay, + gboolean at_remove_echo, const MMPortProbeAtCommand *at_custom_probe, const MMAsyncMethod *at_custom_init, GAsyncReadyCallback callback, @@ -1043,6 +1047,7 @@ mm_port_probe_run (MMPortProbe *self, task = g_new0 (PortProbeRunTask, 1); task->at_send_delay = at_send_delay; + task->at_remove_echo = at_remove_echo; task->flags = MM_PORT_PROBE_NONE; task->at_custom_probe = at_custom_probe; task->at_custom_init = at_custom_init ? (MMPortProbeAtCustomInit)at_custom_init->async : NULL; |