[Asterisk-Users] chan_capi-cm-0.6.4

Ralf Schlatterbeck ralf at zoo.priv.at
Thu Feb 23 00:57:00 MST 2006


Hello Armin, hello List
I'm trying to get chan_capi working with asterisk from debian stable
(asterisk 1.0.7, the debian version number is 1:1.0.7.dfsg.1-2).
I managed to get it compiled by providing my own version of
ast_copy_string.
This is an Austrian PTP line.  I can do outgoing calls fine (no
comprehensive tests yet).  For incoming calls, I'm getting "No answer"
on the remote end (GSM-phone) and the last output on the asterisk
console (capi debug + set verbose 15) is
  == ISDN1: Incoming call '0650621XXXX' -> '11'

When I unplug the ISDN line *after several minutes* I'm getting a
disconnect indication with a layer 1 error.

Interesting is, that I receive an INFO_IND *before* the CONNECT_IND.
This looks like an interesting variation of Austrian ISDN to me.
I've tried both, immediate=no and immediate=yes in the config-file.
The attached log is with immediate=yes.
The behaviour is the similar to chan_capi-0.4 (I'm still using a
patched 0.35 version in my production system) and previous versions, for
these I had to apply a patch to make incoming calls work:
--- chan_capi-0.4.0-PRE1/chan_capi.c    2005-05-09 20:45:02.000000000 +0200
+++ chan_capi-0.4.0-PRE1-hacked-rsc/chan_capi.c 2005-06-04 13:30:19.000000000 +0
@@ -2141,7 +2175,8 @@
                                    ast_pthread_mutex_init(&(p->lock),NULL);
                                    i->mypipe = p;
                                    if (i->isdnmode) {
-                                       p->c = capi_new(i,AST_STATE_DOWN);
+                                        //RSC
+                                       p->c = capi_new(i,AST_STATE_RING);
                                        i->state = CAPI_STATE_DID;
                                    } else {
                                        p->c = capi_new(i,AST_STATE_RING);

This patch immediately hands the call to asterisk instead of waiting for
further protocol information that apparently never comes (the info_ind
that comes *before* the connect_ind?).


Other system data:
- AMD sempron running Kernel version 2.6.15.4
- mISDN mqueue from 2006-02-17
- Billion HFC card using hfcpci

snippet from /etc/modprobe.d/capi:
--->
alias /dev/capi20 hfcpci
alias char-major-68-0 hfcpci

install hfcpci /sbin/modprobe capi debug=1; \
/sbin/modprobe mISDN_core debug=1; \
/sbin/modprobe mISDN_l1 debug=1; \
/sbin/modprobe mISDN_l2 debug=1; \
/sbin/modprobe l3udss1 debug=1; \
/sbin/modprobe mISDN_capi debug=1; \
/sbin/modprobe mISDN_x25dte debug=0; \
/sbin/modprobe mISDN_dsp; \
/sbin/modprobe mISDN_dtmf; \
/sbin/modprobe --ignore-install hfcpci protocol=0x22 debug=1
<---


I'm attaching the full verbose 15 + capi debug log.

Ralf
-- 
Ralf Schlatterbeck
email: ralf at zoo.priv.at FAX: +43/2243/26465/23

-------------- next part --------------
Connected to Asterisk 1.0.7-BRIstuffed-0.2.0-RC7k currently running on fox (pid = 6069)
Verbosity is at least 15
fox*CLI> capi debug
CAPI Debugging Enabled
    -- Remote UNIX connection
    -- Starting simple switch on 'Zap/2-1'
    -- Hungup 'Zap/2-1'
INFO_IND ID=001 #0x0748 LEN=0016
  Controller/PLCI/NCCI            = 0x101
  InfoNumber                      = 0x18
  InfoElement                     = <89>

INFO_RESP ID=001 #0x0748 LEN=0012
  Controller/PLCI/NCCI            = 0x101

CAPI: INFO_IND no interface for PLCI=0x101
       > CAPI: Command=INFO_IND,0x8492: no interface for PLCI=0x101, MSGNUM=0x748!
CONNECT_IND ID=001 #0x0749 LEN=0046
  Controller/PLCI/NCCI            = 0x101
  CIPValue                        = 0x10
  CalledPartyNumber               = <81>11
  CallingPartyNumber              = <21 83>650621XXXX
  CalledPartySubaddress           = default
  CallingPartySubaddress          = default
  BC                              = <80 90 a3>
  LLC                             = default
  HLC                             = <91 81>
  AdditionalInfo                 
   BChannelinformation            = default
   Keypadfacility                 = default
   Useruserdata                   = default
   Facilitydataarray              = default

    -- CONNECT_IND (PLCI=0x101,DID=11,CID=650621XXXX,CIP=0x10,CONTROLLER=0x1)
       > ISDN1: msn='*' DNID='11' DID
  == ISDN1: Incoming call '0650621XXXX' -> '11'
    -- Remote UNIX connection disconnected
DISCONNECT_IND ID=001 #0x074a LEN=0014
  Controller/PLCI/NCCI            = 0x101
  Reason                          = 0x3301

DISCONNECT_RESP ID=001 #0x074a LEN=0012
  Controller/PLCI/NCCI            = 0x101

       > CAPI INFO 0x3301: Protocol error layer 1 (broken line or B-channel removed by signalling protocol)
    -- ISDN1: DISCONNECT_IND on incoming without pbx, doing hangup.
  == ISDN1: CAPI Hangingup
  == ISDN1: Interface cleanup PLCI=0x101
fox*CLI> 



More information about the asterisk-users mailing list