Age | Commit message (Collapse) | Author |
|
|
|
|
|
In the future we'll just default to PDU mode.
|
|
g_match_info_fetch() returns always a heap-allocated string which should be
freed by the caller.
|
|
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.
|
|
|
|
The string passed to utils_bin2hexstr() needs to be freed afterwards.
|
|
|
|
This IpTimeout property will be read by NetworkManager, and used as the time to
wait for pppd to establish the IP configuration.
|
|
|
|
|
|
|
|
|
|
by the modem
|
|
|
|
|
|
|
|
-1 was actually correct, if data->len is 10, i goes from 0 to 8.
|
|
We expect the responses to start always with <CR><LF>. We just remove anything
that comes before that.
|
|
|
|
|
|
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.
|
|
We don't get a \r\n at the end for single messages.
|
|
|
|
|
|
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.
|
|
|
|
The ownership of the GValueArray is not transferred.
|
|
Undoubtedly we'll need to adjust the regex but this works for now.
|
|
Even though we don't parse them correctly yet, at least
send the right command for listing them.
|
|
Stupid signed/unsigned mistake.
|
|
The MMModemTime interface was getting initialized more than once.
|
|
Signed-off-by: Thomas Tuttle <ttuttle@chromium.org>
|
|
Signed-off-by: Thomas Tuttle <ttuttle@chromium.org>
|
|
Signed-off-by: Thomas Tuttle <ttuttle@chromium.org>
|
|
|
|
|
|
|
|
The introspection data specified the Send() method to return
an array of unsigned integers, presumably the indexes of the
messages just sent. But the code wasn't doing that, leading
to a crash when dbus-glib tried to interpret garbage on the
return.
The problem is that sms_send_auth_cb() gave async_call_done()
as the callback for sending the SMS, but that method just calls
dbus_g_method_return() with no return arguments. dbus-glib
interprets the arguments of dbus_g_method_return() according
to the XML introspection data, and thus it was attempting to
read the non-existent argument as an 'au' and getting garbage.
Fix that by actually returning an array of message indexes from
the SMS send code, and propagate that back to the SMS dbus
code so it can return something sensible.
|
|
Might as well keep it simple.
|
|
The first byte of the PDU is the SMSC length, but it's not
the padded SMSC length. So we need to subtract the actual
byte index of the start of the message from length of the
PDU, and since the PDU creation function knows all about
where the SMSC address stops and the message begins, just
have it return that length instead of making the callers
calculate it.
|
|
Eventually we should be using PDU mode whenever the modem supports
it instead of defaulting to text mode, but there are still some
bugs.
|
|
Tests that the last septet (packed in an octet by itself)
doesn't get left off the message like the old code used to
do before "core: fix some bugs in GSM7 packing code".
|
|
The existing gsm_pack() had a bug where if the last
septet should be in an octet by itself, that last
octet wouldn't be added. Plus, kinda pointless to
use a GByteArray here when we already know what the
length will be through simple arithmetic.
We can also simplify the function too.
Furthermore, there weren't any testcases for starting
packing at an offset other than zero, so add one.
|
|
Only for basic SMS-SUBMIT PDUs at the moment, and doesn't
support large SMSs yet.
|
|
|
|
|
|
|
|
There's no encoding information about 8-bit SMS messages,
and they are often binary things like ringtones or voicemail
indicator commands. Since there's no point to our parsing
them just let clients deal with it.
|
|
|