[Home]

Summary:DAHLIN-00158: [patch] DIGITAL calls across a B410P connect, but no data transfer
Reporter:Alec Davis (alecdavis)Labels:
Date Opened:2009-10-29 04:57:44Date Closed:2009-11-24 11:20:49.000-0600
Priority:MajorRegression?No
Status:Closed/CompleteComponents:wcb4xxp
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) bug_16151.diff.txt
( 1) bug16151-2.patch
( 2) digital-call.txt
Description:When placing calls from port 1 of a B410P to port 2, the call appears to connect, but not data transfers.

Both ports are set to NT mode, with terminating resistor switched on.

dialplan code:
exten => _82XX,1,Dial(DAHDI/g4d/${EXTEN})


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

libpri version: SVN-branch-1.4-r1249
DAHDI Version: SVN-trunk-r7392 Echo Canceller: MG2
Asterisk SVN-trunk-r226270M

/etc/dahdi/system.conf
...
# Span 3: B4/0/1 "B4XXP (PCI) Card 0 Span 1" RED
span=3,2,0,ccs,ami
# termtype: te
bchan=36-37
hardhdlc=38
echocanceller=mg2,36-37

# Span 4: B4/0/2 "B4XXP (PCI) Card 0 Span 2" RED
span=4,3,0,ccs,ami
# termtype: te
bchan=39-40
hardhdlc=41
echocanceller=mg2,39-40

# Span 5: B4/0/3 "B4XXP (PCI) Card 0 Span 3"
span=5,4,0,ccs,ami
# termtype: te
bchan=42-43
hardhdlc=44
echocanceller=mg2,42-43

# Span 6: B4/0/4 "B4XXP (PCI) Card 0 Span 4" YELLOW
span=6,5,0,ccs,ami
# termtype: te
bchan=45-46
hardhdlc=47
echocanceller=mg2,45-46



/etc/asterisk/chan_dahdi.conf
...
switchtype=euroisdn
signalling=bri_net_ptmp
overlapdial=no (also tried yes)
immediate=no
group=3
channel => 36, 37
group=4
channel => 39, 40
group=5
channel => 42, 43
group=6
channel => 45, 46
Comments:By: Alec Davis (alecdavis) 2009-10-29 05:01:51

attached digital-call.txt
of a failed call from port 3 to port 4.
Although they appear to connect up fine, there is not data transfer happening.
setup as follows:<pre>
 8102        8202       Analog port 2 for each router
 8101        8201       Analog port 1 for each router
 8100        8200       Data number for each router
ROUTER A    ROUTER B
  ||          ||
  BRA         BRA
  ||          ||
 B410P/3     B410P/4
  G3          G4       Dialling Group
    [ASTERISK]</pre>
The same 2 routers, when connected to 2 ports of a Jtec QBRM card, without any configuration changes work fine.



By: Alec Davis (alecdavis) 2009-10-29 05:20:55

I forgot to add, SPEECH calls work fine, using the analog phone ports on each of the routers and dialing across the B410P, from 8101 to 8201, or the reverse.

Without forcing digital mode with option 'd' as below.

dialplan code:
exten => _81XX,1,Dial(DAHDI/g3/${EXTEN})
exten => _82XX,1,Dial(DAHDI/g4/${EXTEN})

By: Alec Davis (alecdavis) 2009-11-01 22:14:08.000-0600

Please change category to:
dahdi-linux/wcb4xxp

Reasoning:
Digital calls into TE110P and out of TE110P work fine every time, ruling out chan_dahdi.

Digital calls into B410P and out TE110P work once, then need 'dadhi restart'.

Digital calls into TE110P and out of B410P never work
Digital calls into B410P and out of B410P never work



By: Alec Davis (alecdavis) 2009-11-01 22:24:06.000-0600

Testing setup. Ascii Art is fun.<pre>
 8102        8202       Analog port 2 for each router
 8101        8201       Analog port 1 for each router
 8100        8200       Data number for each router
ROUTER A    ROUTER B
  ||          ||
  BRA         BRA
  ||          ||
[JTEC ISDN SWITCH]     Direct outbound down to E1 or BRA
  ||          ||
  E1          BRA
  ||          ||
TE110P       B410P
  G0          G3       Dialling Group
    [ASTERISK]
</pre>



By: Alec Davis (alecdavis) 2009-11-04 11:58:35.000-0600

need anything else from me?

By: Alec Davis (alecdavis) 2009-11-13 02:24:07.000-0600

As discussed with mattf on IRC
effectively disable all cards except B410P, I've physically removed them.
set echocancel=no and echocancelwhenbridged=no in chan_dahdi.conf

To get it working the fix was chan_dahdi.conf: echocancelwhenbridged=no

otherwise if "echocancelwhenbridged=yes" using 'dahdi show channel x'
inbound leg, channel 1, has echo turn off, this is good.
outbound leg, channel 4 has echo turn on, not good.

file chan_dahdi.conf below works.

context=incoming
pridialplan=unknown
prilocaldialplan=unknown
facilityenable=yes
transfer=yes

switchtype=euroisdn
signalling=bri_net_ptmp
overlapdial=yes
immediate=no
echocancel=yes
echocancelwhenbridged=no
group=1
channel => 1, 2
group=2
channel => 4, 5
group=3
channel => 7, 8
group=4
channel => 10, 11

dialplan:
[incoming]
exten => _81XX,1,Dial(DAHDI/g1/${EXTEN})
exten => _82XX,1,Dial(DAHDI/g2/${EXTEN})
exten => _83XX,1,Dial(DAHDI/g3/${EXTEN})
exten => _84XX,1,Dial(DAHDI/g4/${EXTEN})

By: Alec Davis (alecdavis) 2009-11-13 02:25:57.000-0600

The bug as I see it, with digital calls, echo canceller should be off on both legs.

By: Alec Davis (alecdavis) 2009-11-13 03:33:27.000-0600

uploaded bug_16151.diff.txt
callback required from sig_pri to chan_dahdi to set 'digital', Echo canceller is enabled from chan_dahdi, and doesn't know call is digital.

So far only tested with B410P installed as per ~113763 with
 chan_dahdi.conf echocancelwhenbridged=yes

Speech and Digital calls worked every time.
Speech calls had EC on, checked with "dahdi show channel x"
Digital calls had EC off.



By: Alec Davis (alecdavis) 2009-11-17 02:01:51.000-0600

This is a regression, since sig_pri.c was introduced. Where ever p->digital in sig_pri is set, needs to also set it in chan_dahdi.

Please change summary to:
"DIGITAL calls out of E1/T1/BRI cards, connect, but no data transfer"

The Category should be changed back to chan_dahdi, as it turns out - sorry Leif.

Verified this with a TE110P configured in the system, with software Echo Canceller enabled.

Equipment setup:<pre>
 8102        8202       Analog port 2 for each router
 8101        8201       Analog port 1 for each router
 8100        8200       Data number for each router
ROUTER A    ROUTER B
  ||          ||
  BRA         BRA
  ||          ||
[JTEC ISDN SWITCH]     Direct outbound down to E1
       ||    
       E1    
       ||
     TE110P
       G0              Dialling Group
    [ASTERISK]</pre>

/etc/dahdi/system.conf: (fxoks->fxsls and loadzone=NZ changes)
# Autogenerated by /usr/sbin/dahdi_genconf on Tue Nov 17 20:12:45 2009
# If you edit this file and execute /usr/sbin/dahdi_genconf again,
# your manual changes will be LOST.
# Dahdi Configuration File
#
# This file is parsed by the Dahdi Configurator, dahdi_cfg
#
# Span 1: WCT1/0 "Digium Wildcard TE110P T1/E1 Card 0" (MASTER)
span=1,1,0,ccs,hdb3,crc4
# termtype: te
bchan=1-15,17-31
dchan=16
echocanceller=mg2,1-15,17-31

# Span 2: WCTDM/4 "Wildcard TDM400P REV I Board 5"
# channel 32, WCTDM/4/0, no module.
# channel 33, WCTDM/4/1, no module.
fxols=34
echocanceller=mg2,34
fxols=35
echocanceller=mg2,35

# Global data

loadzone        = nz
defaultzone     = nz


chan_dahdi.conf
context=incoming
group=0
pridialplan=unknown
prilocaldialplan=unknown
facilityenable=yes
transfer=yes
switchtype=euroisdn
signalling=pri_net
overlapdial=yes
;signalling=pri_cpe
;qsigchannelmapping=physical
echocancel=yes
echotraining=900
echocancelwhenbridged=yes
rxgain=0.0
txgain=0.0
channel => 1-15,17-31

With bug_16151.diff.txt patch applied, the above setup works as expected, data transfer after connect, additionally speech calls still work.
Without patch, call setup connects, but no datatransfer, as out going leg has echo canceller turned on.

By: Matthew Fredrickson (mattf) 2009-11-23 13:06:15.000-0600

Hey Jeff, just wanted to let you know that this is the issue I was talking about (-MattF)

By: Jeff Peeler (jpeeler) 2009-11-23 20:24:29.000-0600

alec: Can you test my patch that contains a few more changes? I'm trying to remove any confusion due to the flags of sig_pri and chan_dahdi not being in sync.

By: Alec Davis (alecdavis) 2009-11-24 01:19:47.000-0600

Jeff: Tested your patch with TE110P setup as per ~113889
noting txgain=0.0 and rxgain=0.0 refer ASTERISK-14895

Tested Digital and Speech calls with both echocancelwhenbridged=yes and no.

verified with 'dahdi show channel x' that echo;
Was always off on both legs of a digital call.
Was 'on', on both legs of a speech call, when echocancelwhenbridged=yes
Was 'off', on both legs of a speech call, when echocancelwhenbridged=no

Seems good to me.

By: Digium Subversion (svnbot) 2009-11-24 11:19:24.000-0600

Repository: asterisk
Revision: 231058

U   trunk/channels/chan_dahdi.c
U   trunk/channels/sig_pri.c
U   trunk/channels/sig_pri.h

------------------------------------------------------------------------
r231058 | jpeeler | 2009-11-24 11:19:24 -0600 (Tue, 24 Nov 2009) | 11 lines

Fix problem on digital channels due to digital flag not getting set

Changed areas in sig_pri to set the digital flag using a callback that will
also set the corresponding flag in chan_dahdi. Modified dahdi_request slightly
so that if a bearer is marked as digital, that information is available when
creating the new channel.

(closes issue DAHLIN-158)
Reported by: alecdavis
Patch based on bug_16151.diff.txt uploaded by alecdavis (license 585)

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=231058

By: Digium Subversion (svnbot) 2009-11-24 11:20:48.000-0600

Repository: asterisk
Revision: 231059

_U  branches/1.6.2/

------------------------------------------------------------------------
r231059 | jpeeler | 2009-11-24 11:20:47 -0600 (Tue, 24 Nov 2009) | 17 lines

Blocked revisions 231058 via svnmerge

........
 r231058 | jpeeler | 2009-11-24 11:12:25 -0600 (Tue, 24 Nov 2009) | 11 lines
 
 Fix problem on digital channels due to digital flag not getting set
 
 Changed areas in sig_pri to set the digital flag using a callback that will
 also set the corresponding flag in chan_dahdi. Modified dahdi_request slightly
 so that if a bearer is marked as digital, that information is available when
 creating the new channel.
 
 (closes issue DAHLIN-158)
 Reported by: alecdavis
 Patch based on bug_16151.diff.txt uploaded by alecdavis (license 585)
........

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=231059