DTMF Erkennung funktioniert nicht richtig

swatchy

Neuer User
Mitglied seit
18 Nov 2005
Beiträge
145
Punkte für Reaktionen
0
Punkte
16
Mein System: Asterisk CVS vom 15.11.2005 sowie chan_capi 0.6.1 von Sourceforge.

Ich habe folgendes Problem:
Wenn ich eine Kennzahl in X-Lite (SIP Client) eingebe (z.B. 5) und abhebe, dann möchte ich den Amtston hören und anschließend einfach per DTMF wählen können.
Habe mir dazu folgende Konfiguration erstellt:

extensions.conf
Code:
[ankommend]
exten => 5,1,Set(CallerID(number)=123456)
exten => 5,2,Dial(CAPI/contr1/${EXTEN}:1/b)
exten => 5,3,Hangup

capi.conf
Code:
[general]
nationalprefix=0
internationalprefix=00
rxgain=0.8
txgain=0.8

[ISDN1]
isdnmode=msn    
incomingmsn=123456,987654
controller=1    
group=1          
softdtmf=on      
relaxdtmf=on     
accountcode=     
context=ankommend 
holdtype=hold 
echocancelold=yes
devices=2

Wähle ich die 5 mit X-Lite (SIP Client), dauert es ein paar sekunden und ich höre dann einen schlecht übertragenen Amtston, kann dann aber mit X-Lite nicht per DTMF "nachwählen". Habe in X-Lite auch schon probiert die Einstellungen unter Advanced System Settings -> DTMF Settings -> DTMF Force Send in Band von Yes nach No zu ändern, aber brachte keine Abhilfe!
Habe auch schon probiert die Parameter der Zeile:
exten => 5,2,Dial(CAPI/contr1/${EXTEN}:1/b) nach bo oder B oder Bo zu ändern, ebenso ohne Erfolg.

Habe abseits von dem Problem auch schon probiert folgendes Schema aufzubauen: Ein Ruf über ISDN (MSN 123456) geht in den Asterisk Server ein und soll dem Anrufer direkt einen Rufton der 2.ten ISDN Leitung (MSN 987654) übergeben. capi.conf siehe oben.

extensions.conf
Code:
[ankommend]
exten => 123456,1,Set(CallerID(number)=987654)
exten => 123456,2,Dial(CAPI/contr1/${EXTEN}:7/b)

Auch dabei hatte ich kein Erfolg, ich wurde noch nicht einmal angenommen, sondern direkt abgewiesen. Vielleicht gibt es auch hierfür eine Erklärung?

Martin
 
was hast Du denn bei dem sip-account für das XLITE als DTMF-Verfahren eingestellt ?
 
Anbei die SIP Konfiguration in einer SIP Datei, welche in der sip.conf included wird:

sip_martin.conf
Code:
[101]
username=101
type=friend
secret=xyz
record_out=On-Demand
record_in=On-Demand
qualify=no
port=5060
nat=yes
host=dynamic
dtmfmode=rfc2833
context=martin
canreinvite=no
callerid="swatchy" <101>

Hoffe das war das was gesucht war, ansonsten hatte ich ja in der Konfiguration des X-Lite ja schon mit beiden Einstellungen gearbeitet (DTMF Force Send in Band).
Ach sehe, dass ich nicht bekannt gegeben habe, dass ich mit einer AVM Fritz PCI unter Ubuntu 5.10 arbeite.
Was mich nur ein wenig wundert, dass wenn ich die 5 wähle folgende Meldung aus dem CLI kommt:
Code:
    -- Executing Set("SIP/101-c382", "CallerID(number)=123456") in new stack

----------------------
Nov 30 14:10:32 ERROR[6535]: pbx.c:1408 ast_func_write: Function CallerID not registered
----------------------

    -- Executing Dial("SIP/101-c382", "CAPI/contr1/5:1/b") in new stack
       > data = contr1/5:1/b
       > parsed dialstring: 'contr1' '5' '1' 'b'
       > capi request controller = 1
       > parsed dialstring: 'contr1' '5' '1' 'b'
  == ISDN1: Call CAPI/ISDN1/1-8c with B3  (pres=0x00, ton=0x00)
CONNECT_REQ ID=001 #0x015a LEN=0045
  Controller/PLCI/NCCI            = 0x1
  CIPValue                        = 0x1
  CalledPartyNumber               = <80>1
  CallingPartyNumber              = <00 80>5
  CalledPartySubaddress           = default
  CallingPartySubaddress          = default
  BProtocol
   B1protocol                     = 0x1
   B2protocol                     = 0x1
-------------------   
B3protocol                     = 0x0
-------------------
   B1configuration                = default
   B2configuration                = default
   B3configuration                = default
   GlobalConfiguration            = default
  BC                              = default
  LLC                             = default
  HLC                             = default
  AdditionalInfo
   BChannelinformation            = <00 00>
   Keypadfacility                 = default
   Useruserdata                   = default
   Facilitydataarray              = default
   SendingComplete                = default

    -- Called contr1/5:1/b
CONNECT_CONF ID=001 #0x015a LEN=0014
  Controller/PLCI/NCCI            = 0x501
  Info                            = 0x0

    -- ISDN1: received CONNECT_CONF PLCI = 0x501
INFO_IND ID=001 #0x64be LEN=0015
  Controller/PLCI/NCCI            = 0x501
  InfoNumber                      = 0x800d
  InfoElement                     = default

INFO_RESP ID=001 #0x64be LEN=0012
  Controller/PLCI/NCCI            = 0x501

    -- ISDN1: info element SETUP ACK
INFO_IND ID=001 #0x64bf LEN=0016
  Controller/PLCI/NCCI            = 0x501
  InfoNumber                      = 0x18
  InfoElement                     = <89>

INFO_RESP ID=001 #0x64bf LEN=0012
  Controller/PLCI/NCCI            = 0x501

    -- ISDN1: info element CHANNEL IDENTIFICATION 89
INFO_IND ID=001 #0x64c0 LEN=0015
  Controller/PLCI/NCCI            = 0x501
  InfoNumber                      = 0x8045
  InfoElement                     = default

INFO_RESP ID=001 #0x64c0 LEN=0012
  Controller/PLCI/NCCI            = 0x501

    -- ISDN1: info element DISCONNECT
    -- ISDN1: Disconnect case 4
INFO_IND ID=001 #0x64c1 LEN=0017
  Controller/PLCI/NCCI            = 0x501
  InfoNumber                      = 0x1e
  InfoElement                     = <82 88>

Ein Fehler habe ich mittels der logs somit gefunden und zwar muss man in der extensions.conf folgendes ändern:
exten => 123456,1,Set(CallerID(number)=987654) -> sollte heissen: exten => 123456,1,Set(CALLERID(number)=987654), also "CALLERID" komplett groß schreiben. Aber warum steht dort eigentlich: B3protocol = 0x0 und nicht B3protocol = 0x1, da in C doch 0 ==false oder irre ich mich da jetzt?
Habe trotz der einen Fehlerbehebung aber nach wie vor das Problem keine DTMF Erkennung wie bereits beschrieben zu haben.

Danke für Eure Hilfe!
Martin
 
Warum setzt Du die CallerId auf 123456, wenn du im Dialstring sowieso eine andere Nummer setzt?
Warum DTMF nicht geht, kann ich nicht sagen. Im Log ist zumindest nichts zu erkennen, dass Asterisk einen DTMF an CAPI weitergibt.
B3protocol ist eine Einstellung (von 0x0 bis 0xff) und hat nichts mit True oder False zu tun.

Armin
 
Du meinst diese Stelle, oder?

exten => 123456,1,Set(CALLERID(number)=987654)
exten => 123456,2,Dial(CAPI/contr1/${EXTEN}:6/b)

Wollte hiermit eigentlich bezwecken, dass ein ISDN Anruf auf die MSN 123456 per Early B3 auf den 2.ten B-Kanal geschaltet wird. Damit es allerdings keine Probleme mit dem Belegen der MSN 123456 gibt wollte ich gezielt die MSN 987654 nehmen.

Oder hattest du etwas anderes gemeint, oder ist meine Überlegung sogar falsch?

Läuft denn bei jemanden mit der chan_capi 0.6.1 Early B3 mittels eines SIP Clients?

Martin
 
Ja, diese Stelle meine ich. Den zweiten Kanal kann man nicht gezielt belegen. Du kannst nur eine MSN auswahlen (aus deinem Pool), die abgehend als CallerID verwendet werden soll. Die geschieht entweder durch die in Asterisk bereits gesetzte CallerId, bzw durch den SET() Befehl veraenderte, oder eben direkt im Dial() fuer CAPI. Beides ist unsinning, denn die CallerID im DialString hat Vorrang.
Mit deinem DialString 'CAPI/contr1/${EXTEN}:6/b' rufst Du die Nummer 6 an, und benutzt dabei als MSN '123456', ist es dass was du willst?

Armin
 
Ach so, dann habe ich das falsch verstanden, das wollte ich natürlich nicht. Dachte dass ich mit ${EXTEN}:6 die gewählte Zahl verkürze hier 123456 und das sind ja nun mal 6 Zahlen, mit Set zuvor wollte ich eigentlich nur sagen welche MSN ich für den ausgehenden Ruf nehmen möchte (hier: 987654).
Wollte eigentlich nur einmal testen, ob zumindest über ISDN eine DTMF Wahl möglich ist, indem ich über den einen B-Kanal rein (MSN 123456) und den anderen wieder raus gehe, allerdings mit einer anderen MSN (987654) und über Early B3, damit ich DTMF testen kann.
Wie soll der Wählstring denn dann am besten aussehen?

Martin
 
Um eine Nummer zu verkürzen, muss das :6 innerhalb der Klammern sein ${EXTEN:6}.
Dial(CAPI/contr1//b) gibt dir einen Waehlton und du kannst dann mit DTMF weiterwaehlen...

Armin
 
Habe jetzt folgendes gemacht:
exten => 123456,1,Dial(CAPI/contr1//b)
später obiges gelöscht und stattdessen folgendes probiert:
exten => s,1,Dial(CAPI/contr1//b)

aber leider bekomme ich, wenn ich übers Handy mich zu Hause anrufe (MSN 123456) kein Rufton, habe mal mitgeschnitten (Einstellung: 123456,1,Dial(CAPI/contr1//b)):
Code:
CONNECT_IND ID=001 #0x150e LEN=0048
  Controller/PLCI/NCCI            = 0x101
  CIPValue                        = 0x10
  CalledPartyNumber               = <c1>123456
  CallingPartyNumber              = <21 83>Meine Handynr
  CalledPartySubaddress           = default
  CallingPartySubaddress          = default
  BC                              = <80 90 a3>
  LLC                             = default
  HLC                             = <91 81>
  AdditionalInfo                  = default

    -- CONNECT_IND (PLCI=0x101,DID=123456,CID=Meine Handynr,CIP=0x10,CONTROLLER=0x1)
       > ISDN1: msn='123456' DNID='123456' MSN
  == ISDN1: Incoming call 'Meine Handynr' -> '123456'
INFO_IND ID=001 #0x150f LEN=0023
  Controller/PLCI/NCCI            = 0x101
  InfoNumber                      = 0x70
  InfoElement                     = <c1>123456

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

    -- ISDN1: info element CALLED PARTY NUMBER
       > ISDN1: INFO_IND DID digits not used in this state.
INFO_IND ID=001 #0x1510 LEN=0016
  Controller/PLCI/NCCI            = 0x101
  InfoNumber                      = 0x18
  InfoElement                     = <89>

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

    -- ISDN1: info element CHANNEL IDENTIFICATION 89
INFO_IND ID=001 #0x1511 LEN=0016
  Controller/PLCI/NCCI            = 0x101
  InfoNumber                      = 0xa1
  InfoElement                     = <a1>

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

    -- ISDN1: info element Sending Complete
  == Started pbx on channel CAPI/ISDN1/123456-c
    -- Executing Dial("CAPI/ISDN1/123456-c", "CAPI/contr1//b") in new stack
       > data = contr1//b
       > parsed dialstring: 'contr1' '' '' 'b'
       > capi request controller = 1
       > parsed dialstring: 'contr1' 'CAPI' '' 'b'
  == ISDN1: Call CAPI/ISDN1/-d with B3  (pres=0x03, ton=0x21)
CONNECT_REQ ID=001 #0x0018 LEN=0047
  Controller/PLCI/NCCI            = 0x1
  CIPValue                        = 0x1
  CalledPartyNumber               = <80>
  CallingPartyNumber              = <21 83>CAPI
  CalledPartySubaddress           = default
  CallingPartySubaddress          = default
  BProtocol
   B1protocol                     = 0x1
   B2protocol                     = 0x1
   B3protocol                     = 0x0
   B1configuration                = default
   B2configuration                = default
   B3configuration                = default
   GlobalConfiguration            = default
  BC                              = default
  LLC                             = default
  HLC                             = default
  AdditionalInfo
   BChannelinformation            = <00 00>
   Keypadfacility                 = default
   Useruserdata                   = default
   Facilitydataarray              = default
   SendingComplete                = default

    -- Called contr1//b
CONNECT_CONF ID=001 #0x0018 LEN=0014
  Controller/PLCI/NCCI            = 0x201
  Info                            = 0x0

    -- ISDN1: received CONNECT_CONF PLCI = 0x201
INFO_IND ID=001 #0x1512 LEN=0019
  Controller/PLCI/NCCI            = 0x201
  InfoNumber                      = 0x8
  InfoElement                     = <82 e4 98>l

INFO_RESP ID=001 #0x1512 LEN=0012
  Controller/PLCI/NCCI            = 0x201

    -- ISDN1: info element CAUSE 82 e4
INFO_IND ID=001 #0x1513 LEN=0015
  Controller/PLCI/NCCI            = 0x201
  InfoNumber                      = 0x800d
  InfoElement                     = default

INFO_RESP ID=001 #0x1513 LEN=0012
  Controller/PLCI/NCCI            = 0x201

    -- ISDN1: info element SETUP ACK
INFO_IND ID=001 #0x1514 LEN=0017
  Controller/PLCI/NCCI            = 0x201
  InfoNumber                      = 0x1e
  InfoElement                     = <82 88>

INFO_RESP ID=001 #0x1514 LEN=0012
  Controller/PLCI/NCCI            = 0x201

    -- ISDN1: info element PI 82 88
       > ISDN1: In-band information available
CONNECT_B3_REQ ID=001 #0x0019 LEN=0013
  Controller/PLCI/NCCI            = 0x201
  NCPI                            = default

INFO_IND ID=001 #0x1515 LEN=0016
  Controller/PLCI/NCCI            = 0x201
  InfoNumber                      = 0x18
  InfoElement                     = <8a>

INFO_RESP ID=001 #0x1515 LEN=0012
  Controller/PLCI/NCCI            = 0x201

    -- ISDN1: info element CHANNEL IDENTIFICATION 8a
CONNECT_B3_CONF ID=001 #0x0019 LEN=0014
  Controller/PLCI/NCCI            = 0x10201
  Info                            = 0x0

CONNECT_B3_ACTIVE_IND ID=001 #0x1516 LEN=0013
  Controller/PLCI/NCCI            = 0x10201
  NCPI                            = default

CONNECT_B3_ACTIVE_RESP ID=001 #0x1516 LEN=0012
  Controller/PLCI/NCCI            = 0x10201

    -- CAPI/ISDN1/-d is making progress passing it to CAPI/ISDN1/123456-c
  == ISDN1: Requested PROGRESS-Indication for CAPI/ISDN1/123456-c
DATA_B3_IND ID=001 #0x1517 LEN=0030
  Controller/PLCI/NCCI            = 0x10201
  Data32                          = 0xb7a30b6a
  DataLength                      = 0xa0
  DataHandle                      = 0x190
  Flags                           = 0x0
  Data64                          = 0x0

DATA_B3_RESP ID=001 #0x1517 LEN=0014
  Controller/PLCI/NCCI            = 0x10201
  DataHandle                      = 0x190

    -- ISDN1: DATA_B3_IND (len=160) fr.datalen=160 fr.subclass=8
DATA_B3_IND ID=001 #0x1518 LEN=0030
  Controller/PLCI/NCCI            = 0x10201
  Data32                          = 0xb7a3136a
  DataLength                      = 0xa0
  DataHandle                      = 0x191
  Flags                           = 0x0
  Data64                          = 0x0

DATA_B3_RESP ID=001 #0x1518 LEN=0014
  Controller/PLCI/NCCI            = 0x10201
  DataHandle                      = 0x191

dann kommt eine ganze Zeit lang diese Meldung hier drüber, es ändern sich lediglich ein paar Zahlen
und zum Schluss:

   -- ISDN1: DATA_B3_IND (len=160) fr.datalen=160 fr.subclass=8
DATA_B3_IND ID=001 #0x16d3 LEN=0030
  Controller/PLCI/NCCI            = 0x10201
  Data32                          = 0xb7b0eb6a
  DataLength                      = 0xa0
  DataHandle                      = 0x34c
  Flags                           = 0x0
  Data64                          = 0x0

DATA_B3_RESP ID=001 #0x16d3 LEN=0014
  Controller/PLCI/NCCI            = 0x10201
  DataHandle                      = 0x34c

    -- ISDN1: DATA_B3_IND (len=160) fr.datalen=160 fr.subclass=8
DATA_B3_IND ID=001 #0x16d4 LEN=0030
  Controller/PLCI/NCCI            = 0x10201
  Data32                          = 0xb7b0f36a
  DataLength                      = 0xa0
  DataHandle                      = 0x34d
  Flags                           = 0x0
  Data64                          = 0x0

DATA_B3_RESP ID=001 #0x16d4 LEN=0014
  Controller/PLCI/NCCI            = 0x10201
  DataHandle                      = 0x34d

    -- ISDN1: DATA_B3_IND (len=160) fr.datalen=160 fr.subclass=8
DISCONNECT_IND ID=001 #0x16d5 LEN=0014
  Controller/PLCI/NCCI            = 0x101
  Reason                          = 0x0

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

  == ISDN1: CAPI Hangingup
    -- ISDN1: activehangingup (cause=100)
DISCONNECT_B3_REQ ID=001 #0x001a LEN=0013
  Controller/PLCI/NCCI            = 0x10201
  NCPI                            = default

  == Spawn extension (ankommend, 123456, 1) exited non-zero on 'CAPI/ISDN1/123456-c'
  == ISDN1: CAPI Hangingup
  == ISDN1: Interface cleanup PLCI=0x101
DISCONNECT_B3_CONF ID=001 #0x001a LEN=0014
  Controller/PLCI/NCCI            = 0x10201
  Info                            = 0x0

DISCONNECT_B3_IND ID=001 #0x16d6 LEN=0015
  Controller/PLCI/NCCI            = 0x10201
  Reason_B3                       = 0x3301
  NCPI                            = default

DISCONNECT_B3_RESP ID=001 #0x16d6 LEN=0012
  Controller/PLCI/NCCI            = 0x10201

DISCONNECT_REQ ID=001 #0x001b LEN=0018
  Controller/PLCI/NCCI            = 0x201
  AdditionalInfo
   BChannelinformation            = default
   Keypadfacility                 = default
   Useruserdata                   = default
   Facilitydataarray              = default
   SendingComplete                = default

DISCONNECT_CONF ID=001 #0x001b LEN=0014
  Controller/PLCI/NCCI            = 0x201
  Info                            = 0x0

DISCONNECT_IND ID=001 #0x16d7 LEN=0014
  Controller/PLCI/NCCI            = 0x201
  Reason                          = 0x3400

DISCONNECT_RESP ID=001 #0x16d7 LEN=0012
  Controller/PLCI/NCCI            = 0x201
Höre danach die Ansage: Der von Ihnen gewählte Teilnehmer ist zur Zeit nicht erreichbar, bekomme aber kein Amtston.

Martin
 
Ein Wählton kannst du hier auch nicht erwarten, denn erst musst du das ankommende Gespraech annehmen -> Answer()

Armin
 
Holen Sie sich 3CX - völlig kostenlos!
Verbinden Sie Ihr Team und Ihre Kunden Telefonie Livechat Videokonferenzen

Gehostet oder selbst-verwaltet. Für bis zu 10 Nutzer dauerhaft kostenlos. Keine Kreditkartendetails erforderlich. Ohne Risiko testen.

3CX
Für diese E-Mail-Adresse besteht bereits ein 3CX-Konto. Sie werden zum Kundenportal weitergeleitet, wo Sie sich anmelden oder Ihr Passwort zurücksetzen können, falls Sie dieses vergessen haben.

IPPF im Überblick

Neueste Beiträge