[asterisk-dev] BRI support in chan_zap of asterisk 1.6?

Jean-Denis Girard jd.girard at sysnux.pf
Wed Mar 5 15:52:53 CST 2008


Tzafrir Cohen a écrit :
> On Wed, Mar 05, 2008 at 10:11:44AM -1000, Jean-Denis Girard wrote:
> 
> As I mentioned, you need the bri_dchan patch:

Yes I saw your message after posting mine, thanks. zaphfc now compiles 
fine, and does detect my card:
mISDNcore unloaded
Zapata Telephony Interface Registered on major 196
Zaptel Version: SVN--r3932M
Zaptel Echo Canceller: MG2
zaphfc: CCD/Billion/Asuscom 2BD0 configured at mem ffffc2000005a000 fifo 
ffff8100374f8000(0x374f8000) IRQ 20 HZ 1000
zaphfc: Card 0 configured for TE mode
zaphfc: 1 hfc-pci card(s) in this box.
Registered tone zone 2 (France)

> Or trunk. Right.

Ok, checked out svn branch-1.6.0.
*CLI> core show version
Asterisk SVN--r106140 built by jdg @ tiare.sysnux.pf on a x86_64 running 
Linux on 2008-03-05 21:14:48 UTC

Unfortunately it does not work. I probably missed something. This is 
what I get when starting asterisk:

[Mar  5 11:39:01] DEBUG[19820]: chan_zap.c:1794 set_actual_txgain: 
Failed to read gains: Invalid argument
[Mar  5 11:39:01] DEBUG[19820]: chan_zap.c:1812 set_actual_rxgain: 
Failed to read gains: Invalid argument
[Mar  5 11:39:01] DEBUG[19820]: chan_zap.c:1631 update_conf: Updated 
conferencing on 1, with 0 conference users
     -- Registered channel 1, ISDN BRI Point to MultiPoint signalling
[Mar  5 11:39:01] DEBUG[19820]: chan_zap.c:1794 set_actual_txgain: 
Failed to read gains: Invalid argument
[Mar  5 11:39:01] DEBUG[19820]: chan_zap.c:1812 set_actual_rxgain: 
Failed to read gains: Invalid argument
[Mar  5 11:39:01] DEBUG[19820]: chan_zap.c:1631 update_conf: Updated 
conferencing on 2, with 0 conference users
     -- Registered channel 2, ISDN BRI Point to MultiPoint signalling
     -- Automatically generated pseudo channel
[Mar  5 11:39:01] ERROR[19820]: chan_zap.c:9989 zt_pri_error: Making new 
tei 127
Starting in BRI mode
   == Starting D-Channel on span 1
[Mar  5 11:39:01] DEBUG[19820]: channel.c:572 ast_channel_register: 
Registered handler for 'Zap' (Zapata Telephony Driver w/PRI)
   == Registered channel type 'Zap' (Zapata Telephony Driver w/PRI)
   == Manager registered action ZapTransfer
   == Manager registered action ZapHangup
   == Manager registered action ZapDialOffhook
   == Manager registered action ZapDNDon
   == Manager registered action ZapDNDoff
   == Manager registered action ZapShowChannels
   == Manager registered action ZapRestart
  chan_zap.so => (Zapata Telephony) 
 


*CLI> pri show span 1
Primary D-channel: 3
Status: Provisioned, Down, Active
Switchtype: EuroISDN
Type: CPE
Window Length: 0/7
Sentrej: 0
SolicitFbit: 0
Retrans: 0
Busy: 0
Overlap Dial: 1
T200 Timer: 1000
T203 Timer: 10000
T305 Timer: 30000
T308 Timer: 4000
T309 Timer: -1
T313 Timer: 4000
N200 Counter: 3
Overlap Recv: Yes


When trying to dial out, I get:

[Mar  5 11:47:45] DEBUG[20028]: pbx.c:2680 pbx_extension_helper: 
Launching 'Dial'
     -- Executing [483527 at sortant:3] Dial("IAX2/tiare2ast-2", 
"Zap/g1/483527") in new stack
[Mar  5 11:47:45] DEBUG[20028]: chan_zap.c:8892 zt_request: Using channel 1
[Mar  5 11:47:45] DEBUG[20028]: chan_zap.c:8892 zt_request: Using channel 2
[Mar  5 11:47:45] WARNING[20028]: app_dial.c:1456 dial_exec_full: Unable 
to create channel of type 'Zap' (cause 34 - Circuit/channel congestion)
   == Everyone is busy/congested at this time (1:0/1/0)
[Mar  5 11:47:45] DEBUG[20028]: app_dial.c:1946 dial_exec_full: Exiting 
with DIALSTATUS=CONGESTION.
[Mar  5 11:47:45] DEBUG[20028]: pbx.c:2680 pbx_extension_helper: 
Launching 'Congestion'
     -- Executing [483527 at sortant:4] Congestion("IAX2/tiare2ast-2", "") 
in new stack
Received MDL message
Sending TEI management message 1, TEI=127
Sending TEI management message 1, TEI=127
Sending TEI management message 1, TEI=127
Received MDL message
Received MDL message
Sending TEI management message 1, TEI=127
...

If I call call my number, I get an error from the telco.

zapata.conf:
[channels]
switchtype = euroisdn
signalling = bri_cpe_ptmp
pridialplan = dynamic
prilocaldialplan = unknown
overlapdial = yes
echocancel=yes
echotraining = 100
echocancelwhenbridged=yes
immediate=yes
group = 1
context=entrant
channel => 1-2

zaptel.conf:
loadzone=fr
defaultzone=fr
span=1,1,3,ccs,ami
bchan=1-2
dchan=3


Thanks,
-- 
Jean-Denis Girard

SysNux                  Systèmes  Linux  en Polynésie française
http://www.sysnux.pf/   Tél: +689 50 10 40 / GSM: +689 79 75 27



More information about the asterisk-dev mailing list