Commit Graph
6114 Commits
Author SHA1 Message Date
Aleksander Morgado f1dcc71e71 iface-modem: don't assume that setting bands is immediate
The modem may take the request to set bands and reply right away with
a success before actually changing the current bands in use.

Therefore, If we reload bands right after we receive the set response,
we may still see the old band mask instead of the new one. Try to
avoid this, by reloading current bands a couple of times after we have
set them if the band mask is not the expected one.
2019-07-21 22:27:10 +02:00
Aleksander Morgado f39dbe72e5 broadband-modem,voice: implement call waiting status setup/query with +CCWA 2019-07-19 17:47:51 +02:00
Aleksander Morgado 9263e79dc3 api,voice: new CallWaitingSetup() and CallWaitingQuery() methods
These new methods allow querying and updating the status of the call
waiting network service, as per 3GPP TS 22.083.

The status of the service is not a property because we don't want to
unconditionally load it on every boot, given that the process involves
talking to the network (i.e. it is not a device setting).
2019-07-19 17:47:51 +02:00
Aleksander Morgado 0c921bbc94 sms: initialize common fields early for multipart messages
Do not wait until all parts are received in order to initialize all
fields that are common to all parts in the SMS message, do it as soon
as the first part is received.

https://gitlab.freedesktop.org/mobile-broadband/ModemManager/issues/137
2019-07-19 14:09:37 +00:00
Aleksander Morgado 756480de6a test: new 'mmsmsmonitor' tool to monitor SMS messages
The tool monitors SMS message additions and SMS state updates, e.g.:

  $ sudo ./test/mmsmsmonitor
  [/org/freedesktop/ModemManager1/SMS/0] sms found: received
  [/org/freedesktop/ModemManager1/SMS/1] sms found: received
  [/org/freedesktop/ModemManager1/SMS/2] sms found: received
  [/org/freedesktop/ModemManager1/SMS/3] sms found: received
  [/org/freedesktop/ModemManager1/SMS/4] sms found: received
  [/org/freedesktop/ModemManager1/SMS/5] sms found: received
  [/org/freedesktop/ModemManager1/SMS/6] sms found: received
  [/org/freedesktop/ModemManager1/SMS/7] new sms: receiving
  [/org/freedesktop/ModemManager1/SMS/7] sms updated: received
2019-07-17 10:19:39 +02:00
Aleksander Morgado 4a4779729a test: new 'mmsmspdu' tool to parse PDUs given in hex 2019-07-15 13:49:49 +02:00
Aleksander Morgado 5a25776807 sms-list: improve logging of multipart related fields
We were not logging anywhere the "concat max" field for example.
2019-07-15 13:42:45 +02:00
Aleksander Morgado 22afa8a74e shared-qmi: monitor attempt after NAS initiate network register
The QMI NAS Initiate Network Register command will return a successful
response when the request to register is received and accepted by the
module, but this does not mean the requested registration has been
completed yet.

This issue was making e.g. manual registration attempts to a forbidden
network report success right away, even if the actual registration
would end up failing.

In order to avoid that, the QMI based network registration relies on
receiving QMI NAS Serving System indications after QMI NAS Initiate
Network Register replies. As soon as we get a non-searching
registration state in the indication, we'll report the operation as
successful.

Note that the 3GPP interface logic is anyway in charge of checking
if the specific request was successful or not, no need to do that
explicitly in the QMI implementation.
2019-07-15 04:43:54 +00:00
Aleksander Morgado 417c0ed882 iface-modem-3gpp: denied if all reg states idle except for one
If there is one registration state which is denied and the remaining
ones are either unknown or idle, then report denied.
2019-07-15 04:43:54 +00:00
Aleksander Morgado e9f5700d5f iface-modem-3gpp: make registered state checking a macro 2019-07-15 04:43:54 +00:00
Aleksander Morgado d9615bfc2e iface-modem-3gpp: log how the consolidated registration state is built 2019-07-15 04:43:54 +00:00
Aleksander Morgado ef89dd154b telit: additional port type hints for the ME910 2019-07-13 23:21:55 +02:00
Aleksander Morgado 8c8e0e8805 voice,call,cinterion: add Purism as copyright holder
The GSM supplementary services related changes, as well as the rework
done to manage calls per call id, is copyrighted by Purism SPC.
2019-07-12 11:31:04 +02:00
Aleksander Morgado d833b8644c cinterion: setup/cleanup time unsolicited events
We will parse +CTZU URCs, which end up getting in the way of other
commands if we don't process them.

Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/issues/135
2019-07-11 23:21:00 +02:00
Aleksander Morgado fe11a3fa1f cinterion: new +CTZU URC parser 2019-07-11 23:21:00 +02:00
Aleksander Morgado b9a3290871 iface-modem-time: allow updating network timezone via URCs 2019-07-11 23:21:00 +02:00
Aleksander Morgado 63ccd36361 huawei: cleanup/setup voice unsolicited events 2019-07-11 23:21:00 +02:00
Aleksander Morgado 4c2aa2b54e base-call: use g_object_connect() to connect all handlers 2019-07-11 23:21:00 +02:00
Aleksander Morgado 272abc6394 iface-modem-voice: use g_object_connect() to connect all handlers 2019-07-11 23:21:00 +02:00
Aleksander Morgado 148466f768 broadband-modem: implement LeaveMultiparty() with +CHLD=2x 2019-07-11 23:21:00 +02:00
Aleksander Morgado 75d2431f96 broadband-modem: implement JoinMultiparty() with +CHLD=3 2019-07-11 23:21:00 +02:00
Aleksander Morgado 511b0ff244 api,call: new JoinMultiparty() and LeaveMultiparty() methods 2019-07-11 23:21:00 +02:00
Aleksander Morgado 6f23519239 iface-modem-voice: disable special terminated match on multiparty calls 2019-07-11 23:21:00 +02:00
Aleksander Morgado 213c60b76d api,call: new Multiparty boolean property
It will be set to TRUE if this call is part of a multiparty call.
2019-07-11 23:21:00 +02:00
Aleksander Morgado 8bc38110c9 base-call: remove in-call event and audio settings logic
The in-call unsolicited events and the in-call audio settings are
managed exclusively at modem level, and no longer at call object
level. This is because these two things are applicable to all calls
that may be active at the same time.
2019-07-11 23:21:00 +02:00
Aleksander Morgado 73096c0596 broadband-modem: setup in-call unsolicited event handling
The in-call handlers will monitor events that report the call being
terminated.
2019-07-11 23:21:00 +02:00
Aleksander Morgado 24c0c7aa6b huawei: audio channel setup at modem-level
The audio channel setup is shared between all ongoing calls, so it is
a modem-level feature, not specific to a single call.
2019-07-11 23:21:00 +02:00
Aleksander Morgado b7fa4e3661 base-call: allow updating audio settings from out of the call object
E.g. if we want the modem-level in-call state management to provide
what audio settings are expected in all ongoing calls.
2019-07-11 23:21:00 +02:00
Aleksander Morgado 12bad162e3 huawei: voice-related URCs are not in-call
The URCs report the specific call index they apply to, so they should
be managed by the modem object and reported to the Voice interface.
2019-07-11 23:21:00 +02:00
Aleksander Morgado ee2f3fb904 iface-modem-voice: allow reporting received DTMF by call index
If the URC reporting the DTMF does not specify the call index,
mark it as received in all active ones.
2019-07-11 23:21:00 +02:00
Aleksander Morgado fca8955721 ublox: +UCALLSTAT as device-level URC, not in-call
+UCALLSTAT is used to report the state of specific calls by index, and
therefore this is not an in-call URC.
2019-07-11 23:21:00 +02:00
Aleksander Morgado 55e37a6836 iface-modem-voice: allow reporting state updates of any single call
Instead of providing a method to exclusively provide incoming call
updates, make it more generic so that we allow plugins to provide
state updates for any kind of call, not just incoming ones.

The logic to match the call info provided by URCs is updated so that
it can be reused also by the single call reports, in addition to the
full call list reports.
2019-07-11 23:21:00 +02:00
Aleksander Morgado 86aeb84f95 iface-modem-voice: handle in-call state at modem level
We cannot handle in-call state at call level because the state may
apply to multiple active calls at the same time:
 * the modem is in-call if there is at least one ongoing call (>=1).
 * the modem is not in-call if there are no ongoing calls (==0).

The new logic implements call state monitoring for all available call
objects, and whenever the state of one or more calls change, we'll go
over all of them to see how many of the calls can be considered to be
ongoing (i.e. not terminated, not unknown). If we have at least one
call ongoing, we'll setup the in-call state and otherwise, we'll clean
it up.

Setting up and cleaning up the in-call state involves unsolicited
message and audio channel settings management operations.
2019-07-11 23:21:00 +02:00
Aleksander Morgado de2c24ec44 call-list: allow getting call object by DBus path 2019-07-11 23:21:00 +02:00
Aleksander Morgado 13b4c9f6ac iface-modem-voice: minor logging update 2019-07-11 23:21:00 +02:00
Aleksander Morgado df8918ff8c base-call: implement Deflect() with +CTFR 2019-07-11 23:21:00 +02:00
Aleksander Morgado 222874299e api,call: new Deflect() method
This method allows deflecting an incoming or waiting call to a
different number.
2019-07-11 23:20:59 +02:00
Aleksander Morgado 81f1483eec broadband-modem: implement Transfer() with +CHLD=4 2019-07-11 23:20:59 +02:00
Aleksander Morgado 8b01958cb4 api,voice: new Transfer() method
This method will join all active and held calls into a single
multiparty call, and then request the network to terminate the call on
the subscriber's end and transfer the control of the call to the
parties that are still in the call.
2019-07-11 23:20:59 +02:00
Aleksander Morgado 7ceac6f789 broadband-modem: implement HangupAll() with +CHUP 2019-07-11 23:20:59 +02:00
Aleksander Morgado efcc4c60fe api,voice: new HangupAll() method
This method will terminate all ongoing calls.
2019-07-11 23:20:59 +02:00
Aleksander Morgado f065105f17 broadband-modem: implement HoldAndAccept() with +CHLD=2 2019-07-11 23:20:59 +02:00
Aleksander Morgado c713c2c5f9 api,voice: new HoldAndAccept() method
This method will put the currently active call on hold, and right away
accept the next available call.

The user of the API does not need to specify explicitly which is the
next call to accept, because that is decided automatically:
  * If there is any waiting call, it will accept it right away.
  * If there is no waiting call but there is a held call, it will make
  the held call active again.
2019-07-11 23:20:59 +02:00
Aleksander Morgado 5de3c4893f broadband-modem: implement HangupAndAccept() with +CHLD=1 2019-07-11 23:20:59 +02:00
Aleksander Morgado d56d1b2656 api,voice: new HangupAndAccept() method
This method will hangup the currently active call and right away
accept the next available call.

The user of the API does not need to specify explicitly which is the
next call to accept, because that is decided automatically:
  * If there is any waiting call, it will accept it right away.
  * If there is no waiting call but there is a held call, it will make
    the held call active again.
2019-07-11 23:20:59 +02:00
Aleksander Morgado f994982cce base-call: support hanging up specific calls
E.g. we can hangup a waiting call without interfering with the active
one.
2019-07-11 23:01:30 +02:00
Aleksander Morgado 4b2f9e7d3e broadband-modem: implement call list polling with +CLCC 2019-07-11 23:01:30 +02:00
Aleksander Morgado f699308958 cinterion: disable call list polling if ^SLCC is supported
Early detect that ^SLCC is supported, and disable the call list
polling in the interface if so.
2019-07-11 23:01:29 +02:00
Aleksander Morgado d0c0e925b6 iface-modem-voice: setup full call list polling logic
If the modem supports call list polling, we'll setup a timeout to poll
for the full call list periodically, in order to get detailed call
states.

The timeout is setup as soon as a new call is created, and it will be
kept enabled as long as there is a call being established (i.e. not
unknown, not terminated, not active).
2019-07-11 23:01:08 +02:00
Aleksander Morgado faaaf20276 cinterion: when ^SLCC is supported, detailed call state updates are implicit 2019-07-11 23:01:08 +02:00