[Home]

Summary:ASTERISK-11792: [patch] channel groups dont work
Reporter:zaterio (zaterio)Labels:
Date Opened:2008-04-07 13:49:39Date Closed:2008-11-07 13:02:12.000-0600
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Addons/chan_mobile
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) 20080806__bug12377.diff.txt
Description:chan_mobile is configurated to work with two sony ericsson k510, in the first tests the cell phones are configurated to work in separated context , in this conditions audio quality are good, and the two phones can works at the same time when diferents sip client make outbound calls.
In the second test the phones are configurated two work in the same context, and are in the same group, when the first sip call all are ok, while the first cell is talking, a second call is make from another sip,(at this  point the two cells are connected and Free)  asterisk says:

app_dial.c:1449 dial_exec_full: Unable to create channel of type 'Mobile' (cause 44 - Requested channel not available)

besides in this second tests are no audio in one cell phone when  make only a single calls


see additional information  

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

asterisk-addons svn version: 576

zaptel from  http://svn.digium.com/svn/zaptel/branches/1.4, version: 4130, (only loaded ztdummy)

Debian 4.0

mobile.conf

[general]
interval=30

[adapter]
id=blue2
address=00:11:B1:0A:2B:E8


[adapter]
id=blue
address=00:11:B1:09:F8:51


[celu1]
address=00:1D:28:05:D3:52      
port=4                          
context=test                    
adapter=blue                    
group=1      
                 
[celu2]
address=00:1A:75:24:78:A6      
port=4                          
context=test                  
adapter=blue2                  
group=1                        


hcid.conf

options {
autoinit yes;
security auto;
pairing multi;
passkey "1234";
}

device {
name "asterisk-default";
class 0x5a0204;
iscan enable; pscan enable;
lm accept;
lp rswitch,hold,sniff,park;
}

device hci1{
name "asterisk2";
class 0x000100;
iscan enable; pscan enable;
lm accept;
lp rswitch,hold,sniff,park;
}

device hci0{
name "asterisk1";
class 0x000100;
iscan enable; pscan enable;
lm accept;
lp rswitch,hold,sniff,park;
}

hciconfig -a

hci0:   Type: USB
       BD Address: 00:11:B1:0A:2B:E8 ACL MTU: 384:8 SCO MTU: 64:8
       UP RUNNING PSCAN
       RX bytes:7583172 acl:164 sco:148476 events:344 errors:0
       TX bytes:1881168 acl:105 sco:36827 commands:88 errors:0
       Features: 0xff 0xff 0x8f 0xfe 0x9b 0xf9 0x00 0x80
       Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
       Link policy: RSWITCH HOLD SNIFF PARK
       Link mode: SLAVE ACCEPT
       Name: 'asterisk1'
       Class: 0x000100
       Service Classes: Unspecified
       Device Class: Computer, Uncategorized
       HCI Ver: 2.0 (0x3) HCI Rev: 0x7a6 LMP Ver: 2.0 (0x3) LMP Subver: 0x7a6
       Manufacturer: Cambridge Silicon Radio (10)

hci1:   Type: USB
       BD Address: 00:11:B1:09:F8:51 ACL MTU: 384:8 SCO MTU: 64:8
       UP RUNNING PSCAN
       RX bytes:3569 acl:76 sco:0 events:121 errors:0
       TX bytes:1580 acl:59 sco:0 commands:35 errors:0
       Features: 0xff 0xff 0x8f 0xfe 0x9b 0xf9 0x00 0x80
       Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
       Link policy: RSWITCH HOLD SNIFF PARK
       Link mode: SLAVE ACCEPT
       Name: 'asterisk2'
       Class: 0x000100
       Service Classes: Unspecified
       Device Class: Computer, Uncategorized
       HCI Ver: 2.0 (0x3) HCI Rev: 0x7a6 LMP Ver: 2.0 (0x3) LMP Subver: 0x7a6
       Manufacturer: Cambridge Silicon Radio (10)


dialplan:

[test]
exten => 103,1,Dial(Mobile/g1/${EXTEN},45,r)
exten => 103,n,Hangup()
exten => 4000,1,Dial(SIP/4000)
exten => 4000,n,Hangup()
exten => 5000,1,Dial(SIP/5000)
exten => 5000,n,Hangup()
exten => 6000,1,Dial(SIP/6000)
exten => 6000,n,Hangup()

obs: 103 is a free call number (only for test)

mobile show devices before the call

ID              Address           Group Adapter         Connected State SMS
celu2           00:1A:75:24:78:A6 1     blue2           Yes       Free  No
celu1           00:1D:28:05:D3:52 1     blue            Yes       Free  No


Comments:By: zaterio (zaterio) 2008-04-07 13:55:25

errata:
in the description of the problem i says:
"(at this point the two cells are connected and Free)"

replace with:

"(at this point the second cell are connected and Free)"

By: Jason Parker (jparker) 2008-04-07 15:12:26

I looked through the group code, and while the g/G options were implemented, they don't appear to actually do what is advertised.  It stops at the first channel it finds in the group, and does no checking whether it's free.

By: zaterio (zaterio) 2008-04-07 15:29:49

If a patch is released i will test very quickly

By: jmls (jmls) 2008-07-04 14:53:55

qwell, any progress on fixing the bug that you found in this ?

By: Sabin (binsa) 2008-07-10 10:53:58

Please, find in the source row if (pvt->group == group)
and try to replace with
if (pvt->group == group && pvt->state == MBL_STATE_IDLE)
Please, report the result if anybody can test with the change



By: Leif Madsen (lmadsen) 2008-10-27 14:43:04

This is a ping... anyone able to test this?

By: jongerenchaos (jongerenchaos) 2008-11-07 12:08:16.000-0600

This patch works well!! Maybe that anybody can add them to the SVN libery.

By: Leif Madsen (lmadsen) 2008-11-07 12:41:12.000-0600

Assigned to Tilghman since this is his patch and we have a case which confirms it solves the issue.

By: Tilghman Lesher (tilghman) 2008-11-07 13:02:11.000-0600

Fixed in revision 688.