[Home]

Summary:ASTERISK-07970: codec g729 - unsupported format (when call TO skinny phone)
Reporter:pj (pj)Labels:
Date Opened:2006-10-20 10:20:56Date Closed:2006-11-08 17:01:21.000-0600
Priority:MajorRegression?No
Status:Closed/CompleteComponents:Channels/chan_skinny
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) 8190.diff
( 1) skinny2.diff
Description:calls initiated FROM skinny phone (7920) is working fine using g729,
but calls TO skinny fail, (alaw is always OK)


****** ADDITIONAL INFORMATION ******

FAILED g729 call TO phone (also no any skinny debug displayed):
Dial("IAX2/bill-gw-16", "Skinny/324@PJ|30|T") in new stack
chan_skinny.c:4397 skinny_request: Asked to get a channel of unsupported format '0'
app_dial.c:1081 dial_exec_full: Unable to create channel of type 'Skinny' (cause 0 - Unknown)


OK g729 call FROM skinny phone (with skinny debug on):
[Oct 20 17:10:06] Received Stimulus: Line(1)
[Oct 20 17:10:06] Setting ringer mode to '1'.
[Oct 20 17:10:06] skinny_new: tmp->nativeformats=256 fmt=256
[Oct 20 17:10:06] Attempting to Clear display on Skinny 324@PJ
[Oct 20 17:10:06] Clearing Display
[Oct 20 17:10:06]     -- Starting simple switch on '324@PJ'


codec settings in skinny.conf:
[general]
disallow=all
allow=g729

Comments:By: Anthony LaMantia (alamantia) 2006-10-20 17:16:26

this is a bit strange, it seems most of the codec negoiation in chan_skinny takes place in the handle_capabilties_request_message function..

and the codec used in skinny_request() and mostly ignored thoughout the program...

can you try running with the patch i've uploaded and tell me if the call's to 729 calls to the phone work. as well as what the cli output is in a working/non-working case.

i am going to go over this code a bit in the mean time some more.

By: pj (pj) 2006-10-23 04:04:17

seems, that this patch helps (applied to Asterisk SVN-branch-1.4-r45928M)
I can now make call in both directions using codec g729,
only this notice appears, when call to skinny phone:

NOTICE[27257]: chan_skinny.c:4397 skinny_request: Asked to get a channel of unsupported format '0'
NOTICE[27257]: chan_skinny.c:4398 skinny_request: Format Sent on request 0
    -- skinny_request(324@PJ)
    -- Called 324@PJ

By: Anthony LaMantia (alamantia) 2006-10-24 15:13:46

Cool,
I will work on the more intricate parts of this bug later on as long as the temp. solution is working for.. i've been sort of bogged down by getting to astricon, and the realted hardships of travel ;)..

btw thank you very much for your bug reports in chan_skinny ;) , they have helped the channel become more and more usable by all asterisk users :)

By: pj (pj) 2006-10-25 15:37:12

OK, I discover another minor issue: seems, that chan_skinny doesn't send keepalives to phone and when phone is hard disconnected (eg. I removed battery from my 7920, that phone can't send unregister request), "skinny show devices" still shows phone as registered and is even possible to call to this phone (I got normal ringtone). also if I have skinny debug turned on, no messages about sending keepalives or detecting, that phone is death.
I have "keepalive=30" in [general] section of skinny.conf.
Please look at this, when you have time. thx

console log:
phone is still as registered, when hard disconnected from network, no keepalives send:

ipbx*CLI> skinny show devices
Name                 DeviceId         IP              Type            R NL
-------------------- ---------------- --------------- --------------- - --
PJ                   SEP000D288E664B  193.179.xx.xx  7920            Y  1


when phone is powered on (after hard disconnect), phone is first unregisterd and then immediately registered


[Oct 25 22:32:23] WARNING[22254]: chan_skinny.c:4184 get_input: read() returned error: Connection reset by peer
[Oct 25 22:32:23] Skinny Client was lost, unregistering
[Oct 25 22:32:23] NOTICE[22254]: chan_skinny.c:4281 skinny_session: Skinny Session returned: Connection reset by peer
[Oct 25 22:32:28]     -- Starting Skinny session from 193.179.xx.xx
[Oct 25 22:32:29] Received Alarm Message: 25: Name=SEP000D288E664B Load=4.0(03.00) Last=Initialized
[Oct 25 22:32:29] Device SEP000D288E664B is attempting to register
[Oct 25 22:32:29]     -- Device 'SEP000D288E664B' successfully registered

By: Anthony LaMantia (alamantia) 2006-10-25 22:19:09

is this message happening right when you deactive your phone?

[Oct 25 22:32:23] WARNING[22254]: chan_skinny.c:4184 get_input: read() returned error: Connection reset by peer
[Oct 25 22:32:23] Skinny Client was lost, unregistering

By: pj (pj) 2006-10-26 03:10:06

no, this message appears after phone is powered on again, entire procedure again:
1) phone is normaly powered and registered:

ipbx*CLI> skinny show devices
Name                 DeviceId         IP              Type            R NL
-------------------- ---------------- --------------- --------------- - --
PJ                   SEP000D288E664B  193.179.xx.x  7920            Y  1

2) phone is hard disconnected, this list is after several minutes, when phone was powerd down, but register status is still the same "Y"
ipbx*CLI> skinny show devices
Name                 DeviceId         IP              Type            R NL
-------------------- ---------------- --------------- --------------- - --
PJ                   SEP000D288E664B  193.179.xx.xx  7920            Y  1

3) phone is powerd back again (first unregister, then register):
[Oct 26 10:00:48] WARNING[26616]: chan_skinny.c:4184 get_input: read() returned error: Connection reset by peer
[Oct 26 10:00:48] Skinny Client was lost, unregistering
[Oct 26 10:00:48] NOTICE[26616]: chan_skinny.c:4281 skinny_session: Skinny Session returned: Connection reset by peer
[Oct 26 10:00:54]     -- Starting Skinny session from 193.179.xx.xx
[Oct 26 10:00:54] Received Alarm Message: 25: Name=SEP000D288E664B Load=4.0(03.00) Last=Initialized
[Oct 26 10:00:54] Device SEP000D288E664B is attempting to register
[Oct 26 10:00:54]     -- Device 'SEP000D288E664B' successfully registered

By: Anthony LaMantia (alamantia) 2006-10-31 16:56:07.000-0600

please try my latest patch for the original issue.

By: pj (pj) 2006-11-01 15:50:12.000-0600

hello, skinny2.diff patch is working fine without any error message on console when calling phone using codec g729, many thanks!
tested with SVN-branch-1.4-r46822M:
patching file chan_skinny.c
Hunk #2 succeeded at 4282 (offset 20 lines).
Hunk #3 succeeded at 4392 (offset 20 lines).

this patch probably doesn't solve issue with not detecting death device, as mentioned before - still is possible normaly ring to skinny phone, when this phone is actually death (not unregistered by power off switch, but hard disconected)

By: pj (pj) 2006-11-08 14:52:22.000-0600

hello, as I said, this patch is working fine for my first reported issue (call using g729 codec), so it is possible to commit to current trunk and 1.4 branch?
issue with keepalives can be solved later or separatedly... thanks
PJ

By: jmls (jmls) 2006-11-08 15:58:02.000-0600

poke: developers: can we get this patch reviewed / applied ? Reporter has mentioned that it's fixed the problem. Thanks.

By: Anthony LaMantia (alamantia) 2006-11-08 16:50:08.000-0600

we are going to commit this one in a short bit. can you open another bug featuring the second issue you reported so we can start fresh on that one?

By: Steve Murphy (murf) 2006-11-08 17:00:16.000-0600

Committed the patch to trunk via r. 47343
and to 1.4 as 47344.

By: Steve Murphy (murf) 2006-11-08 17:01:20.000-0600

I'm closing this one.... side issues probably should go under a different bug report number.