libosmocore/src/coding
Vadim Yanitskiy 71e8091c9d coding: properly handle AFS_SID_UPDATE frames in DTX mode
There are two similar values in enum gsm0503_amr_dtx_frames:

  * AFS_SID_UPDATE - precursor of SID UPDATE,
  * AFS_SID_UPDATE_CN - the actual SID UPDATE.

The former is internally used by libosmocoding to mark the current
frame as a precursor of the actual SID UPDATE frame - the later.

  +---+---+---+---+---+---+---+---+
  | _ | _ | _ | _ | a | b | c | d |  AFS_SID_UPDATE
  +---+---+---+---+---+---+---+---+
  | a | b | c | d | _ | _ | _ | _ |  AFS_SID_UPDATE_CN
  +---+---+---+---+---+---+---+---+

This is required because function gsm0503_tch_afs_decode_dtx() is
invoked by TDMA scheduler on every 4th received burst, while the
burst buffer is 8 bursts wide.

Currently, whenever gsm0503_detect_afs_dtx_frame() detects an
AFS_SID_UPDATE frame, we still attempt to decode it as a speech
or data below in gsm0503_tch_afs_decode_dtx().  This is indeed
a bug, which results in unexpected BER values:

  * expected BER 0/212,
  * actual BER 252/448.

We should return immediately once we have detected an AFS_SID_UPDATE.
This patch fixes unexpected BER-SUB values during DTXu silence periods.

Change-Id: I813081a4c0865958eee2496fe251ae17235ac842
Related: SYS#5853
2022-05-16 00:51:57 +03:00
..
Makefile.am Bump version: 1.5.1.282-ab5e-dirty → 1.6.0 2021-11-16 13:08:23 +01:00
gsm0503_amr_dtx.c coding: fix comments for detect_afs_sid_{first,update,onset} 2022-04-28 13:03:00 +00:00
gsm0503_coding.c coding: properly handle AFS_SID_UPDATE frames in DTX mode 2022-05-16 00:51:57 +03:00
gsm0503_interleaving.c treewide: remove FSF address 2021-12-14 12:44:03 +01:00
gsm0503_mapping.c treewide: remove FSF address 2021-12-14 12:44:03 +01:00
gsm0503_parity.c treewide: remove FSF address 2021-12-14 12:44:03 +01:00
gsm0503_tables.c treewide: remove FSF address 2021-12-14 12:44:03 +01:00
libosmocoding.map dtx: add decoding for AMR-DTX frames 2020-04-14 13:22:44 +00:00