[Home]

Summary:ASTERISK-30391: res_rtp_asterisk: Issue with transcoding g722 after MES changes
Reporter:George Joseph (gjoseph)Labels:
Date Opened:2023-01-09 07:25:52.000-0600Date Closed:2023-01-13 07:21:46.000-0600
Priority:MajorRegression?Yes
Status:Closed/CompleteComponents:Resources/res_rtp_asterisk
Versions:GIT Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) call_setup.txt
( 1) Channels.txt
( 2) error.jpg
( 3) extension.pcap
( 4) extension-20.1.pcap
( 5) extension20.pcap
( 6) PJSip_Endpoints.txt
( 7) rtp.conf
( 8) timestamps.jpg
( 9) trunk.pcap
(10) trunk-20.1.pcap
(11) trunk20.pcap
Description:Transcoding to/from G722 produces no audio after the Asterisk Media Score changes possibly due to the forced sample rate of 8000 (it's a long story).

See:
https://community.asterisk.org/t/potential-transcoding-issue-in-master-branch/95318

Comments:By: Friendly Automation (friendly-automation) 2023-01-09 14:00:11.935-0600

Change 19827 merged by Friendly Automation:
res_rtp_asterisk: Asterisk Media Experience Score (MES)

[https://gerrit.asterisk.org/c/asterisk/+/19827|https://gerrit.asterisk.org/c/asterisk/+/19827]

By: Friendly Automation (friendly-automation) 2023-01-10 07:07:50.669-0600

Change 19826 merged by Friendly Automation:
res_rtp_asterisk: Asterisk Media Experience Score (MES)

[https://gerrit.asterisk.org/c/asterisk/+/19826|https://gerrit.asterisk.org/c/asterisk/+/19826]

By: Friendly Automation (friendly-automation) 2023-01-10 07:10:52.139-0600

Change 19788 merged by Friendly Automation:
res_rtp_asterisk: Asterisk Media Experience Score (MES)

[https://gerrit.asterisk.org/c/asterisk/+/19788|https://gerrit.asterisk.org/c/asterisk/+/19788]

By: Peter Whisker (whiskerp) 2023-01-11 02:27:59.103-0600

Discontinuities in timestamps caused by the MES code.

By: Peter Whisker (whiskerp) 2023-01-11 02:29:00.282-0600

This is still a serious problem with bad timestamps being sent to G722 channels. Please re-open.

By: Peter Whisker (whiskerp) 2023-01-11 04:36:45.035-0600

Attachments from Community:


By: Peter Whisker (whiskerp) 2023-01-11 04:37:51.381-0600

Call setup (asterisk -rvvv)
I've reattached the "core show channel..." as channels.txt to a later message

By: George Joseph (gjoseph) 2023-01-11 05:24:59.496-0600

[~whiskerp] The "Endpoints.txt" attachment has the channel dumps but not the endpoint details.  I need the output of {{pjsip show endpoint}} for each endpoint.  Also can you attach the actual pcap file that has both legs of the call?


By: Peter Whisker (whiskerp) 2023-01-11 05:48:46.487-0600

PJSip Endpoints and pcap files

By: Peter Whisker (whiskerp) 2023-01-11 05:50:19.774-0600

core show channel ...

By: Peter Whisker (whiskerp) 2023-01-11 05:57:26.912-0600

For reference, here is the same call on Asterisk 20.1 - there are no timestamp errors.

By: George Joseph (gjoseph) 2023-01-11 07:00:28.787-0600

Sorry, one more thing...   can you attach the contents of your rtp.conf file.



By: Peter Whisker (whiskerp) 2023-01-11 07:08:19.399-0600

Added rtp.conf file(s) - also the included ones

By: George Joseph (gjoseph) 2023-01-11 11:24:29.784-0600

Give the new set of patches a try.


By: Peter Whisker (whiskerp) 2023-01-11 15:05:51.283-0600

I have applied the patch 8ed08bd.diff and it appears to have fixed the issue.

I get one unused variable warning:

  [CC] res_rtp_asterisk.c -> res_rtp_asterisk.o
res_rtp_asterisk.c: In function 'calc_rxstamp_and_jitter':
res_rtp_asterisk.c:5500:9: warning: unused variable 'estimated_elapsed' [-Wunused-variable]
5500 |  double estimated_elapsed;
     |         ^~~~~~~~~~~~~~~~~
  [LD] res_rtp_asterisk.o -> res_rtp_asterisk.so


By: Peter Whisker (whiskerp) 2023-01-11 15:16:31.333-0600

I've taken tcpdumps and they look fine.

By: Peter Whisker (whiskerp) 2023-01-11 15:17:20.382-0600

tcpdumps after patching of tag 20 code
trunk20.pcap
extension20.pcap

By: Friendly Automation (friendly-automation) 2023-01-13 07:21:47.509-0600

Change 19833 merged by George Joseph:
res_rtp_asterisk: Don't use double math to generate timestamps

[https://gerrit.asterisk.org/c/asterisk/+/19833|https://gerrit.asterisk.org/c/asterisk/+/19833]

By: Friendly Automation (friendly-automation) 2023-01-13 07:21:49.545-0600

Change 19832 merged by George Joseph:
res_rtp_asterisk: Don't use double math to generate timestamps

[https://gerrit.asterisk.org/c/asterisk/+/19832|https://gerrit.asterisk.org/c/asterisk/+/19832]

By: Friendly Automation (friendly-automation) 2023-01-13 07:21:51.756-0600

Change 19790 merged by George Joseph:
res_rtp_asterisk: Don't use double math to generate timestamps

[https://gerrit.asterisk.org/c/asterisk/+/19790|https://gerrit.asterisk.org/c/asterisk/+/19790]