Discussion:
[Linphone-users] linphonec: making gsm the preferred codec?
Mikhail Ramendik
2005-02-04 20:54:41 UTC
Permalink
Hello,

Looks like liphonec does connect to my proxy, if I give its adderss explicitly
with the phone number. It takes the password from ~/.gnome2/linphone , which
was created by linphone 0.12.2 .

However, judging by the traffic, it's using pcma or pcmu as the codec. I know
that the other side supports GSM; in fact I've tried deleting all codecs
except GSM from the config file, and before I deleted them, they had
"enabled=0". Still I can't make it connect with GSM!

What can I do to make linphonec use gsm as the preferred codec, or better yet,
as the only available codec?

Here's the entire config file, with the password altered of course:

[net]
con_type=2
use_nat=0

[sip]
username=rame_01
hostname=sip1.titl.ru
sip_port=5060
use_registrar=1
as_proxy=1
registrar=sip:sip1.titl.ru
passwd=mypassword
addr_of_rec=sip:***@sip1.titl.ru
expires=900

[rtp]
audio_rtp_port=7078
video_rtp_port=0
audio_jitt_comp=60
video_jitt_comp=60

[sound]
dev_id=2
rec_lev=80
play_lev=80
source=m
local_ring=/usr/local/share/sounds/linphone/rings/oldphone.wav
remote_ring=/usr/local/share/sounds/linphone/ringback.wav

[video]
enabled=0
show_local=0

[audio_codec_0]
mime=GSM
rate=8000
enabled=1

[address_book]
entry_count=0
--
Yours, Mikhail Ramendik
Simon Morlat
2005-02-07 10:40:42 UTC
Permalink
Your config file is ok.
just change con_type=4 (the default value on 1.0.0preX but as you were
upgrading from 0.12.2 it was not changed).
This fields describes your internet connection type:
0: 28k analog modem
1: 56k analog modem
2: ISDN link
3: ADSL
4: ethernet or more.

Those things are not friendly-handled by linphonec, it is planned to do so so
that anybody should have to even look at this config file.
Simon
Post by Mikhail Ramendik
Hello,
Looks like liphonec does connect to my proxy, if I give its adderss
explicitly with the phone number. It takes the password from
~/.gnome2/linphone , which was created by linphone 0.12.2 .
However, judging by the traffic, it's using pcma or pcmu as the codec. I
know that the other side supports GSM; in fact I've tried deleting all
codecs except GSM from the config file, and before I deleted them, they had
"enabled=0". Still I can't make it connect with GSM!
What can I do to make linphonec use gsm as the preferred codec, or better
yet, as the only available codec?
[net]
con_type=2
use_nat=0
[sip]
username=rame_01
hostname=sip1.titl.ru
sip_port=5060
use_registrar=1
as_proxy=1
registrar=sip:sip1.titl.ru
passwd=mypassword
expires=900
[rtp]
audio_rtp_port=7078
video_rtp_port=0
audio_jitt_comp=60
video_jitt_comp=60
[sound]
dev_id=2
rec_lev=80
play_lev=80
source=m
local_ring=/usr/local/share/sounds/linphone/rings/oldphone.wav
remote_ring=/usr/local/share/sounds/linphone/ringback.wav
[video]
enabled=0
show_local=0
[audio_codec_0]
mime=GSM
rate=8000
enabled=1
[address_book]
entry_count=0
Simon Morlat
2005-02-07 16:10:01 UTC
Permalink
Post by Simon Morlat
Your config file is ok.
just change con_type=4 (the default value on 1.0.0preX but as you were
Done this. But still, it uses g.711 instead of GSM.
I really need to make it use GSM only. The remote does support GSM. How do
I do this?
setting enabled=0 for all codec descriptions except GSM should work. But of
course the remote host must propose GSM in order for linphone to use it.
If you just set gsm as your first codec (in [audio_codec_0]) with enabled=1
will make linphone use it preferabily (if remote sip phone supports it). If
the remote sip phone does not support it, then it can fallback to other
codecs, in their order of preference.

Simon
Mikhail Ramendik
2005-02-07 16:31:10 UTC
Permalink
Post by Simon Morlat
I really need to make it use GSM only. The remote does support GSM. How
do I do this?
setting enabled=0 for all codec descriptions except GSM should work. But of
course the remote host must propose GSM in order for linphone to use it.
If you just set gsm as your first codec (in [audio_codec_0]) with enabled=1
will make linphone use it preferabily (if remote sip phone supports it). If
the remote sip phone does not support it, then it can fallback to other
codecs, in their order of preference.
The other end does support GSM and does propose it. In 0.12.2 GSM did work.
And in XLite (Windows) it works now.

Yet, even with GSM as the first codec and with others "enabled=0" in the
config, the thing connects with g.711 !

Is there some way to trace the protocol negotiation, to at least understand
what's going on? And, is there a way to really disable other protocols, so
that linphone would propose *only* GSM, or nothing at all?
--
Yours, Mikhail Ramendik
Simon Morlat
2005-02-07 17:09:07 UTC
Permalink
Post by Mikhail Ramendik
The other end does support GSM and does propose it. In 0.12.2 GSM did work.
Do you mean that you are using 1.0.0preX release ?
I had understood that you were only using 0.12.2. Please clarify.
Post by Mikhail Ramendik
And in XLite (Windows) it works now.
Yet, even with GSM as the first codec and with others "enabled=0" in the
config, the thing connects with g.711 !
That's not normal.
Can you please send me the logs of a call ? use linphonec -d 5
Thanks.
Post by Mikhail Ramendik
Is there some way to trace the protocol negotiation, to at least understand
what's going on? And, is there a way to really disable other protocols, so
that linphone would propose *only* GSM, or nothing at all?
Loading...