Commit Graph

3500 Commits

Author SHA1 Message Date
Aleksander Morgado
8e83a10c1e hso: disable echo removal
Built-in echo removal conflicts with _OWANCALL unsolicited messages, which are
not coming prefixed with <CR><LF>.

Fixes LP#953294
2012-03-13 20:14:58 +01:00
Aleksander Morgado
791e097ab5 at-serial-port: new property to control whether echo removal should be applied 2012-03-13 20:14:58 +01:00
Aleksander Morgado
7c9ba7faf2 samsung: remove unused variables 2012-03-05 16:59:52 +01:00
Dan Williams
5f6c65e7c1 gsm: retry sending SMS in PDU mode if text fails and PDU is supported
In the future we'll just default to PDU mode.
2012-03-01 17:23:46 -06:00
Aleksander Morgado
bc118aa160 modem-helpers: plug memleak
g_match_info_fetch() returns always a heap-allocated string which should be
freed by the caller.
2012-02-29 16:51:50 +01:00
Dan Williams
30e7063094 iridium: convert to new port grabbing scheme 2012-02-28 10:06:04 -06:00
Dan Williams
4dad94d500 core: rework port grabbing and organization
Make port roles more flexible.  We have modems that do PPP
on interfaces other than the primary interface, and that
wasn't possible with the old code.  So clean up all that
logic and move the port organization code into the core
so we can reduce code in the plugins.

In the new world order, the plugins say whether the port
is a QCDM port, an AT port, or ignored.  If it's an AT
port the plugins get to tag it as primary, secondary, or
PPP, or any combination of the 3.  This allows for modems
where PPP should really be done on the secondary port
(Huawei E220, Sierra devices) so that the primary port
stays open for command and status.

Modem subclasses no longer get asked to handle port grabbing
themselves.  Instead, that's now done by the generic classes
(MMGenericCdma and MMGenericGsm) and the plugins are notified
when a port is grabbed so they can add unsolicited response
handlers for it.  After all ports are grabbed by the generic
classes, they get "organized", which assigns various ports
to the roles of PRIMARY, SECONDARY, DATA, and QCDM based
on specific rules and hints that the plugin provided (which
are expressed as MMAtPortFlags).  The plugins then have
a chance to perform fixups on the primary port if they choose.

The plugin code is responsible for determining the port
hints (ie MMAtPortFlags) at probe time, instead of having
a combination of the plugin and the modem class do the
job.  This simplifies things greatly for the plugins at
the expense of more complicated logic in the core.
2012-02-28 10:06:04 -06:00
Aleksander Morgado
36ee1b9c76 build: include proper build dependencies for the polkit conf file
So that the final conf file is updated if the original one gets modified.
2012-02-26 22:10:48 +01:00
Tom Goetz
86bfe96ddb cdma: fix crash on NULL error (bgo #670145) 2012-02-25 20:06:33 -06:00
Aleksander Morgado
b42ce2d8e6 charsets: plug memleak
The string passed to utils_bin2hexstr() needs to be freed afterwards.
2012-02-18 11:15:31 +01:00
Dan Williams
2e99aa2557 qcdm: decode some more log items 2012-02-17 13:06:11 -06:00
Aleksander Morgado
7b8e9203f2 gsm: don't query PS network registration status if not supported 2012-02-17 13:25:03 +01:00
Aleksander Morgado
f2af208f05 iridium: don't try to update signal quality if not registered
Seems that launching AT+CSQF when not registered ends up timing out. AT+CSQF
is meant to be the fast version to get the signal quality, and is expected to
return instantly with the last cached signal quality value. But if we never
got registered, there is no such cached value, so it probably waits to get the
first one.
2012-02-17 13:25:03 +01:00
Aleksander Morgado
5371cce11d iridium: ensure cached capabilities get checked 2012-02-17 13:25:03 +01:00
Aleksander Morgado
fc88c53fad iridium: handle Motorola-branded Iridium modems 2012-02-17 13:25:03 +01:00
Aleksander Morgado
8b1016f4e1 iridium: close and open the port during disconnection
The Iridium modem doesn't seem to like only the port flashing during the
disconnection, so we fully close and open again the port.
2012-02-17 13:25:03 +01:00
Aleksander Morgado
d52b38b1f2 iridium: set bearer service type to 9600bps V.110 2012-02-17 13:25:03 +01:00
Aleksander Morgado
707647da45 iridium: override generic initialization
We must send ATZ alone and once reply received, wait some time before sending
the next initialization commands. Otherwise, the next commands will receive
garbage as reply. The only way to handle this is to override the whole generic
initialization phase.

We will also avoid sending any power-up command, as not needed.
2012-02-17 13:25:03 +01:00
Aleksander Morgado
c0f390470e iridium: allow up to 200s to configure IP 2012-02-17 13:25:03 +01:00
Aleksander Morgado
920fefa8e2 modem: new property to allow specifying longer timeouts when configuring IP
This IpTimeout property will be read by NetworkManager, and used as the time to
wait for pppd to establish the IP configuration.
2012-02-17 13:25:03 +01:00
Aleksander Morgado
e6d085246f iridium: ensure 9600 baudrate is used 2012-02-17 13:25:03 +01:00
Aleksander Morgado
4b0cd28baf iridium: fix operator name and code to be reported 2012-02-17 13:25:02 +01:00
Aleksander Morgado
3a7f970931 gsm: let plugins override the operator name and code retrieval 2012-02-17 13:25:02 +01:00
Aleksander Morgado
26d69ca0f2 gsm: allow leading zeroes in numbers in CREG/CGREG responses 2012-02-17 13:25:02 +01:00
Aleksander Morgado
4ed3391859 iridium: PS network is not supported 2012-02-17 13:25:02 +01:00
Aleksander Morgado
40512451cc generic: only send CGACT if PS network is supported 2012-02-17 13:25:02 +01:00
Aleksander Morgado
740680fd3b generic: query PS network registration status only if PS network supported by the modem 2012-02-17 13:25:02 +01:00
Aleksander Morgado
0c6eb6dcaa iridium: handle access technology 2012-02-17 13:25:02 +01:00
Aleksander Morgado
156a05afe0 iridium: handle allowed mode 2012-02-17 13:25:02 +01:00
Aleksander Morgado
85de9bbcc9 iridium: override signal quality retrieval command 2012-02-17 13:25:02 +01:00
Aleksander Morgado
b7b37c4738 iridium: override SMS indications setup commands 2012-02-17 13:25:02 +01:00
Aleksander Morgado
a87b4b46c8 gsm: set pin check flag before requesting ICCID check 2012-02-17 13:25:02 +01:00
Aleksander Morgado
1c6e17857f iridium: skip ICCID/IMSI query 2012-02-17 13:25:02 +01:00
Aleksander Morgado
7cbc8f3b80 gsm: allow no whitespaces before CPIN? reply value 2012-02-17 13:25:02 +01:00
Aleksander Morgado
b714441272 iridium: disable power up command and modify flow control setup 2012-02-17 13:25:02 +01:00
Aleksander Morgado
670f560b3d iridium: add initial dummy plugin 2012-02-17 13:25:02 +01:00
Aleksander Morgado
20693529ef core: fix loop limits in echo removal
-1 was actually correct, if data->len is 10, i goes from 0 to 8.
2012-02-16 18:20:31 +01:00
Aleksander Morgado
21162a366a at-serial-port: implement built-in echo/garbage removal
We expect the responses to start always with <CR><LF>. We just remove anything
that comes before that.
2012-02-16 10:27:22 +01:00
Aleksander Morgado
1db0004033 charsets: don't crash when passing a NULL string to the UTF-8 converter 2012-02-08 12:06:59 -06:00
Dan Williams
7b4d6cf605 test: fix SMS testcase errors due to uninitialized GError 2012-02-07 14:12:15 -06:00
Dan Williams
2104cd725a gsm: ensure text mode SMS list doesn't pick up too much text
This likely has no effect, but just make sure the regex stops
grabbing message content when it hits the CF/LF that terminates
the message content in text mode.
2012-02-07 13:59:32 -06:00
Dan Williams
c7f54a635a gsm: fix text mode SMS list regex for single messages
We don't get a \r\n at the end for single messages.
2012-02-07 13:48:47 -06:00
Aleksander Morgado
ff31122eba build: do not warn about using deprecated methods
GValueArray is deprecated since GLib 2.31.14, but we need to use it for
dbus-glib based code.

We should re-enable deprecation warnings once we switch to GDBus.
2012-02-07 19:45:30 +01:00
Aleksander Morgado
4af8483ae4 gsm: use new common charset converter when parsing operator name/code 2012-02-07 19:24:50 +01:00
Aleksander Morgado
03678df6fd gsm: convert SMS text and number from current charset to UTF-8 2012-02-07 19:24:36 +01:00
Aleksander Morgado
00ce1d6874 charsets: new method to do our best to convert from current charset to UTF-8
This method will try to convert the input string to UTF-8. The input string is
supposed to be in the given charset; or otherwise is supposed to be the hex
representation of the string in the given charset.
2012-02-07 19:24:36 +01:00
Aleksander Morgado
9f6f80a63a charsets: don't warn if we couldn't convert from hex to utf8 2012-02-07 17:52:53 +01:00
Aleksander Morgado
0c6e5e713e core: plug leaks when passing GValueArrays to dbus_g_method_return()
The ownership of the GValueArray is not transferred.
2012-02-07 11:42:06 +01:00
Dan Williams
4706ea488e sms: handle text mode SMS listing
Undoubtedly we'll need to adjust the regex but this works for now.
2012-02-02 21:12:44 -06:00
Dan Williams
76c9b29415 test: (sms-get.py) don't fail if we don't get an SMSC 2012-02-02 21:12:17 -06:00