Bad sound quality after redirect

Hi!

I’m building an application which allows to dial via the Asterisk Manager Interface using the originate command. There should be an optional conferencing feature. So my attempt was basically:

Initial call:
Originate(Channel1, Extension1)

If another partner should be called:
Redirect(Channel1, Channel of Extension1, ExtensionConferenceRoom)
Originate(Channel2, ExtensionConferenceRoom)

This approach works but results in a bad sound quality after the redirect. The sound seems to be scrambled. Before redirecting the sound quality is quite well, of course. All extensions are called via SIP with the same codec, so no transcoding should occur.

The application used for the conference room is AppConference from http://sourceforge.net/projects/appconference/. But even with a simple destination application (e. g. PlayTones or Playback) the sound quality is as bad as with AppConference.

Has anyone any ideas? :smile:

Regards Franz

Something I forgot to mention:

The bad sound quality arises only if the ExtraChannel parameter is given with Redirect. Without ExtraChannel the sound quality is still fine. But the second channel is hungup then of course, which is not intended.

These are the manager commands in detail:

[code]action: login
username: sdjklgdsjg
secret: 04864390
events: on

action: originate
callerid: 3847438609
priority: 1
exten: 4068439865
async: 1
context: out
channel: SIP/sip-gate/0394839405[/code]

Talk a while…

[code]action: redirect
priority: 1
exten: 1234
context: conference
channel: SIP/sip-gate-0868b000
extrachannel: SIP/sip-gate-086a5000

action: logoff
[/code]

How’d you get the sound quality to be good to begin with? Any custom configuration? My setup always sounds like a cellphone connection.

Hi!

I don’t have a special setup. I’m using SIP with alaw (g.711). Maybe transcoding causes your bad sound quality. Have a look at the channel properties with “core show channel SIP/xxxx” while your channels are up. All available channels will be listed after “core show channels”. You’ll see which codecs are used and if transconding takes place.

To avoid transcoding try to set all codecs to the same value. In sip.conf for example:

disallow = all allow = alaw

Regards Franz

[quote=“franzs”]
I don’t have a special setup. I’m using SIP with alaw (g.711). Maybe transcoding causes your bad sound quality. Have a look at the channel properties with “core show channel SIP/xxxx” while your channels are up. [/quote]

Well, hmmm. Trying to check, but just getting “No such command ‘core’ (type ‘help’ for help)”… What version are you running?

My version is 1.4.17. You have 1.2.x probably. Just leave out the “core” in front of the commands:

show channels show channel SIP/xxx
Further information can be obtained with

sip show channels sip show channel SIP/xxx

After month of research :wink: I found a workaround for this problem.

The dial application of the destination in originate command must have one of the t or T option.

Hope this helps someone else.