[asterisk-bugs] [Asterisk 0010807]: Incorrectly sized IAX2 frames sent from mISDN with b410p
Asterisk Bug Tracker
noreply at bugs.digium.com
Tue Aug 5 17:51:12 CDT 2008
The following issue has been RESOLVED.
======================================================================
http://bugs.digium.com/view.php?id=10807
======================================================================
Reported By: ZX81
Assigned To: crich
======================================================================
Project: Asterisk
Issue ID: 10807
Category: Channels/chan_misdn
Reproducibility: always
Severity: major
Priority: normal
Status: resolved
Asterisk Version: 1.4.11
SVN Branch (only for SVN checkouts, not tarball releases): N/A
SVN Revision (number only!):
Disclaimer on File?: N/A
Request Review:
Resolution: no change required
Fixed in Version:
======================================================================
Date Submitted: 2007-09-23 04:27 CDT
Last Modified: 2008-08-05 17:51 CDT
======================================================================
Summary: Incorrectly sized IAX2 frames sent from mISDN with
b410p
Description:
With the following setup
PSTN -- BRI --> B410P -> * -> IAX2 Phone/Softphone
The packet sizes are 16ms with a g711.ulaw or alaw codec to the phone.
The phone is expecting 20ms packets (and timestamp differences).
If we use the SIP component of the same softphone (and the same codec) we
get the following:
PSTN -- BRI --> B410P -> * -> SIP Phone/Softphone
With this setup there are no problems.
So, with IAX2 we get a distorted voice (sounds like it is playing 16ms of
samples followed by 4ms of silence every 20ms).
The problem does not occur if you are transcoding to GSM for example
(maybe because the packet sizes have to change anyway).
The reason that the problem occurred in IAX2 and not in SIP is because SIP
is using the ast_smoother.
I saw the patch on 10229 for a problem with choppy audio from incorrect
packet sizes for chan_mobile. Basically adding a smoother in to the struct
and then initialising it if it hadn't been used followed by filling and
emptying it.
I added it to chan_iax2.c and the problem went away instantly.
My implementation of the smoother is probably somewhat lacking.
I think the problem may be caused by the mISDN channel reading 128 instead
of 160 bytes (is it bytes) from the PSTN.
I also saw the issue with choppy audio when using recent versions of GCC,
and tried the patches for it.
If someone wants me to upload a patch as an example I can, but I'm not
sure how many people will be able to test it (you'd need to have 128
instead of 160 coming in).
It may be that IAX2 is not the place to do the smoothing either. Anyway
let me know and I'll help how I can.
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
2008-08-05 17:51 kpfleming Status assigned => resolved
2008-08-05 17:51 kpfleming Resolution open => no change
required
======================================================================
More information about the asterisk-bugs
mailing list