libosmocore/src/codec
Mychaela N. Falconia 315e78aab1 ecu: add is_dtx_pause() method
The ECU API of libosmocodec is unfortunately a peculiar non-3GPP
entity: an ECU by itself, severed from Rx DTX handler functions,
which is a logical/conceptual function with no place in the standard
3GPP architecture.  The closest thing that exists in the standard
architecture is the TFO spec (TS 28.062 section C.3.2.1.1) calling
for an ECU application, but not comfort noise generation, in the case
of destination leg doing DTXd - but even then it is not a totally
"pure" ECU like libosmocodec API, it is an ECU plus a SID preener,
and the SID preening transform is not possible within the constraints
of existing libosmocodec ECU API.  Hence truly correct handling of
corner cases, particularly invalid SID, is sadly impossible in the
current libosmocodec ECU framework.

The only current user of this API is the UL path in osmo-bts-trx;
however, as described in OS#6040, we would like to move that ECU call
from osmo-bts-trx model-specific code to the common layer of osmo-bts.
The current osmo-bts-trx incarnation avoids the SID handling problem
by suppressing the call to ECU frame_out() after any SID (valid or
invalid) was received on the air, thus pausing the RTP stream instead
of emitting ECU output during DTXu pauses.  We would like to retain
the same behavior when we move this ECU call to the common layer,
into its proper place _after_ the link quality check in l1sap - but
the current method of flagging post-SID state in osmo-bts-trx will
no longer work on the other side of that link quality check.

As a workaround, have the ECU remember via a separate Boolean flag
whether it is in post-SID state or not (was the most recent frame_in()
any kind of SID or not), and provide is_dtx_pause() method to
retrieve this flag - the relocated ECU call in osmo-bts UL path
will use this new is_dtx_pause() method call to decide if it should
call frame_out() or switch to pausing RTP output.

Related: OS#6040
Change-Id: I3857be84bba12aaca0c2cca91458b7e13c5a642a
2023-06-23 18:42:11 +00:00
..
Makefile.am cosmetic: codec/Makefile.am: list sources one file per line 2023-05-18 10:54:26 +02:00
ecu.c ecu: add is_dtx_pause() method 2023-06-23 18:42:11 +00:00
ecu_fr.c ecu: add is_dtx_pause() method 2023-06-23 18:42:11 +00:00
ecu_fr_old.c codec cosmetic: move old FR ECU code to ecu_fr_old.c 2023-05-17 13:53:20 +00:00
gsm610.c codec: new functions osmo_{fr,efr}_sid_reset() 2023-05-27 10:49:41 +00:00
gsm620.c codec: new function osmo_hr_sid_reset() 2023-05-27 10:51:17 +00:00
gsm660.c codec: new functions osmo_{fr,efr}_sid_reset() 2023-05-27 10:49:41 +00:00
gsm690.c treewide: remove FSF address 2021-12-14 12:44:03 +01:00