[Workaround] 7170 Rufnummer mit Rufumleitung durchreichen

black-tiger

Neuer User
Mitglied seit
26 Sep 2006
Beiträge
11
Punkte für Reaktionen
0
Punkte
0
Hallo zusammen,

Ich mache gerade meine ersten "Gehversuche" mit Asterisk auf der FB. Dank der vielen hilfreichen Tipps und Anleitungen hier habe ich es auch am Analoganschluss ganz befriedigend am laufen.

Meine FB ist als 772 bei Asterisk angemeldet und leitet alle Anrufe, die vom Festnetz kommen per Rufumleitung an 772 weiter (anders bekommt der Asterisk das Gespräch nicht, soweit ich das verstanden habe). Das Problem dabei ist, dass die originale Anrufernummer nicht weitergereicht wird, sondern als Anrufer im Display des Tel. immer nur "772" erscheint.

Ich habe schon etwas mit der extensions.con rumgespielt, es aber nicht hinbekommen:
Code:
Set(__OriginalCaller=${CALLERID(number)})
exten => _77X,1,SetCallerID(${OriginalCaller})
exten => _77X,2,Dial,SIP/${EXTEN}|55|Ttr

Weiß jemand, wie ich die Nummer des Anrufers weiterleiten kann?
Vielen Dank!
b.T.
 
Zuletzt bearbeitet:
Das Problem scheint zu sein, dass die FritzBox die externe Nummer nicht weitergibt: Wenn ich vor dem Dial ein

Code:
exten => _77X,1,NoOp(${CALLERID})

setze, kommt nur immer die Nr. von der FritzBox an:

Code:
Executing NoOp("SIP/772-40e5", ""FritzBox" <772>") in new stack

Habe auch den Threat von Firechris gefunden:
http://ting.ip-phone-forum.de/showthread.php?t=143448

Leider führen die Änderungen in der capi.conf und in der extensions.conf bei mir nicht zum Erfolg.
 
Zuletzt bearbeitet:
Ok, ich habe es mit einem Workaround geschafft:
Nachdem ich die Änderungen von Firechris leicht umgeändert habe, bekommt mein Asterisk gleichzeitig zur FritzBox einen eingehenden Anruf. Der Asterisk kann diesen dann direkt zu meinem SIP Telefon durchstellen und die Rufumleitung der FB ist nicht mehr nötig. So wird auch die richtige Nummer übertragen.

Da die originale Rufnummer von der FB nicht zum SIP Telefon übertragen wird, müssten doch eigentlich alle Benutzer, die sich ihre Anrufe auf einen SIP Account weiterleiten lassen (also z.B. 1&1, kein Asterisk) auch alle das Problem haben, dass sie nicht sehen wer eigentlich anruft, oder?
 
Zuletzt bearbeitet:
Tatsächlich? Auch stabil, nach Neustart etc.? Audio von extern-analog nach SIP und umgekehrt? Poste doch bitte mal Deine Konfugration der capi.conf.
Ich habe das Problem, das es mal funktioniert und mal nicht, und darum aufgegeben den analogen Anschluß "ohne Rufumleitung" also direkt zu nutzen.
Danke und Gruß,
Holger
 
Hallo Holger,

Produktiv habe ich es NOCH nicht am Laufen, aber auch nach mehreren Neustarts der FB hat es noch funktioniert:

capi.conf:
Code:
;
; CAPI config
; (1234567 gets replaced by script cfg_asterisk start)
;

; general section

[general]
nationalprefix=0
internationalprefix=00
rxgain=0.4
txgain=0.6
language=de      ;set default language (en/de...)
;ulaw=yes        ;set this, if you live in u-law world instead of a-law

; interface sections ...
[ISDN1]          ; fritzbox 7050/7170 external S0 (or external analog line: experimental)
ntmode=no      ;if isdn card operates in nt mode, set this to yes
isdnmode=msn     ;'MSN' (point-to-multipoint) or 'DID' (direct inward dial)
incomingmsn=*   ;allow incoming calls to this list of MSNs/DIDs, * = any,
                       ;a ="analog controller": empty incoming msn gets replaced
		       ;with defaultcid (-> fritzbox 7050/7170 at analog line)
defaultcid=1234567  ;set a default caller id to that interface for dial-out,
                 ;this caller id will be used when dial option 'd' is set.
controller=4     ;capi controller number to use (=4: fritzbox 7050/7150 at analog line)
group=1          ;dialout group
softdtmf=off      ;enable/disable software dtmf detection, recommended for AVM cards
relaxdtmf=off     ;in addition to softdtmf, you can use relaxed dtmf detection
accountcode=     ;PBX accountcode to use in CDRs
context=capi-in1  ;context for incoming calls
;holdtype=hold   ;when the PBX puts the call on hold, ISDN HOLD will be used. If
                 ;set to 'local' (default value), no hold is done and the PBX may
                 ;play MOH.
bridge=no      ;native bridging (CAPI line interconnect) if available
devices=1       ;number of concurrent calls on this controller
                 ;(2 makes sense for single BRI, 30 for PRI)
immediate=yes

[ISDN3]          ; fritzbox 7050 internal S0
ntmode=yes      ;if isdn card operates in nt mode, set this to yes
isdnmode=did     ;'MSN' (point-to-multipoint) or 'DID' (direct inward dial)
                 ;when using NT-mode, 'DID' should be set in any case
incomingmsn=*    ;allow incoming calls to this list of MSNs/DIDs, * = any
;defaultcid=123  ;set a default caller id to that interface for dial-out,
                 ;this caller id will be used when dial option 'd' is set.
controller=3     ;capi controller number to use
group=3          ;dialout group
softdtmf=off      ;enable/disable software dtmf detection, recommended for AVM cards
relaxdtmf=off     ;in addition to softdtmf, you can use relaxed dtmf detection
accountcode=     ;PBX accountcode to use in CDRs
context=capi-in3  ;context for incoming calls
;holdtype=hold   ;when the PBX puts the call on hold, ISDN HOLD will be used. If
                 ;set to 'local' (default value), no hold is done and the PBX may
                 ;play MOH.
;immediate=yes   ;DID: immediate start of pbx with extension 's' if no digits were
                 ;     received on incoming call (no destination number yet)
                 ;MSN: start pbx on CONNECT_IND and don't wait for SETUP/SENDING-COMPLETE.
                 ;     info like REDIRECTINGNUMBER may be lost, but this is necessary for
                 ;     drivers/pbx/telco which does not send SETUP or SENDING-COMPLETE.
bridge=no      ;native bridging (CAPI line interconnect) if available
devices=2        ;number of concurrent calls on this controller
                 ;(2 makes sense for single BRI, 30 for PRI)


; unused example (reference)
;[ISDN9]          ;this example interface gets name 'ISDN9' and may be any
                 ;name not starting with 'g' or 'contr'.
;ntmode=yes      ;if isdn card operates in nt mode, set this to yes
;isdnmode=did     ;'MSN' (point-to-multipoint) or 'DID' (direct inward dial)
                 ;when using NT-mode, 'DID' should be set in any case
;incomingmsn=*    ;allow incoming calls to this list of MSNs/DIDs, * = any
;incomingmsn=8001,8002,8003    ;allow incoming calls to this list of MSNs/DIDs, * = any
;defaultcid=123  ;set a default caller id to that interface for dial-out,
                 ;this caller id will be used when dial option 'd' is set.
;controller=0    ;ISDN4BSD default
;controller=7    ;ISDN4BSD USB default
;controller=3     ;capi controller number to use
;group=1          ;dialout group
;prefix=0        ;set a prefix to calling number on incoming calls
;softdtmf=off      ;enable/disable software dtmf detection, recommended for AVM cards
;relaxdtmf=off     ;in addition to softdtmf, you can use relaxed dtmf detection
;accountcode=     ;PBX accountcode to use in CDRs
;context=capi-in  ;context for incoming calls
;holdtype=hold   ;when the PBX puts the call on hold, ISDN HOLD will be used. If
                 ;set to 'local' (default value), no hold is done and the PBX may
                 ;play MOH.
;immediate=yes   ;DID: immediate start of pbx with extension 's' if no digits were
                 ;     received on incoming call (no destination number yet)
                 ;MSN: start pbx on CONNECT_IND and don't wait for SETUP/SENDING-COMPLETE.
                 ;     info like REDIRECTINGNUMBER may be lost, but this is necessary for
                 ;     drivers/pbx/telco which does not send SETUP or SENDING-COMPLETE.
;echosquelch=1   ;_VERY_PRIMITIVE_ echo suppression
;echocancel=yes  ;EICON DIVA SERVER (CAPI) echo cancelation
                 ;(possible values: 'no', 'yes', 'force', 'g164', 'g165') 
;echocancelold=yes;use facility selector 6 instead of correct 8 (necessary for older eicon drivers)
;echotail=64     ;echo cancel tail setting
;bridge=yes      ;native bridging (CAPI line interconnect) if available
;callgroup=1     ;PBX call group
;language=de     ;set language for this device (overwrites default language)
;disallow=all    ;RTP codec selection (valid with Eicon DIVA Server only)
;allow=all       ;RTP codec selection (valid with Eicon DIVA Server only)
;devices=2        ;number of concurrent calls on this controller
                 ;(2 makes sense for single BRI, 30 for PRI)

Ich habe die FB übrigens neulich auf die neuste Firmware .40 aktualisiert.

Grüße
bT
 
Analog eingehend klingelt nur etwa 10 Sek.

Hallo,

ich habe im Wesentlichen das Gleiche durchgeführt. Allerdings wird der Ruf nach mehrmaligem Klingeln kurzerhand abgebrochen. Vermutlich von der Fritzbox. Hier einen Auszug aus dem Asterisk CLI-log mit capi debug aktiv:

Code:
  == Started pbx on channel CAPI/ISDN1#01/-9

    -- Executing [s@capi_in1:1] Dial("CAPI/ISDN1#01/-9", "SIP/421,55,tr") in new stack

  == Using SIP RTP CoS mark 5

    -- Called 421

    -- SIP/421-0062f9c8 is ringing
    -- ISDN1#01: attempting ALERT in state 1
    -- chan_capi queue frame: [ TYPE: Control (4) SUBCLASS: Hangup (1) ] [ISDN1#01]

  == Spawn extension (capi_in1, s, 1) exited non-zero on 'CAPI/ISDN1#01/-9'
  == ISDN1#01: Interface cleanup PLCI=0xdead0000

Die /-9 ist nichts weniger als ein Counter, der bei jedem Versuch nach unten zählt. Die Zielummer 421 ist in diesem Falle Außerhalb der Fritzbox. Wenn ein Ziel innerhalb der Fritzbox genommen wird (der an einem der Analoganschlüsse gekoppelt ist) ist das Ergebnis das Gleiche.

Meine Firmware: 29.04.67; Asterisk 1.6.0.1 (von spblinux; auf USB-stick).

Irgendwer eine Idee woher dieses Verhalten rührt?
-Rob
 
Ergänzung:
Wenn der Hörer rechtzeitig abgenommen wird, funktioniert die Verbindung ohne diesen Abbruch.
Für den Fall, dass die Fritzbox abbricht, muss ich mir eine ältere Firmware überlegen. Die Vorversion (.04.57) habe ich auf der mitgelieferten CD.

Wer hat mit welcher Version ein gutes Verhalten von Asterisk/CAPI?
 
servus,
ich habe nach einen tag rumspielen auch endlich den analogen externen anschluss zum Laufen bekommen. Nachdem ich schon die ganze nacht bis früh mich mit dem 1und1 voip rumgekotzt habe...

tipp von mir: wenn ihr mit CAPI rumspielt... reicht nicht ein reload im CLI.
ich glaube, ich hätte mir einen halben Tag Arbeit spaaren können... wenn ich ein asterisk stop.... asterisk start ausgeführt hätte ;)

ich habe jetzt nur noch das Problem, dass beim eingehenden Anruf aufm Analoganschluss nur kurz signalisiert wird! Box 7170 firmware .70 asterisk1.4.22
hat jemand ne Idee??
 
ich habe das Problem gefunden!
Das kurze signalisieren eines eingehenden analogen anrufes auf einem Sip Telfon am Asterisk hängt damit zusammen, dass ich wie oben vorgeschlagen, die Rufnummernzuordnung der analogen Nummer bei fon1-3 in der Fritzbox Oberfläche herausgenommen habe.

Lösung
nachdem ich die analoge Nummer wieder fon1-3 zugewiesen habe, funktioniert alles wie gewollt.

meine Konfigs:
extensions.conf
Code:
[globals]
; gehende Nummer in [festnetz_out]
;CAPI_CALLERID=xxxx

[festnetz_out]
exten => _X.,1,Dial(CAPI/ISDN1/${EXTEN},55,Tt/bd)

[capi_in1]
exten => s,1,Dial(SIP/7701,30,r)

[sip7702]
include => lokal
include => festnetz_out
include => capi_in1

capi.conf
Code:
[general]
nationalprefix=0
internationalprefix=00
rxgain=1.0       ;linear receive gain (1.0 = no change)
txgain=1.0       ;linear transmit gain (1.0 = no change)
language=de      ;set default language (en/de...)
;ulaw=yes

[ISDN1]          ; fritzbox 7050/7170 external S0 (or external analog line: experimental)
ntmode=no      ;if isdn card operates in nt mode, set this to yes
isdnmode=msn     ;'MSN' (point-to-multipoint) or 'DID' (direct inward dial)
incomingmsn=*    ;allow incoming calls to this list of MSNs/DIDs, * = any,
;defaultcid=xxxx  ;set a default caller id to that interface for dial-out,
                 ;this caller id will be used when dial option 'd' is set.
controller=4     ;capi controller number to use (=4: fritzbox 7050/7150 at analog line)
group=1          ;dialout group
softdtmf=off      ;enable/disable software dtmf detection, recommended for AVM cards
relaxdtmf=off     ;in addition to softdtmf, you can use relaxed dtmf detection
accountcode=     ;PBX accountcode to use in CDRs
context=capi_in1  ;context for incoming calls
;holdtype=hold   ;when the PBX puts the call on hold, ISDN HOLD will be used. If
                 ;set to 'local' (default value), no hold is done and the PBX may
                 ;play MOH.
bridge=yes      ;native bridging (CAPI line interconnect) if available
devices=1        ;number of concurrent calls on this controller
                 ;(2 makes sense for single BRI, 30 for PRI)
immediate=yes

sip.conf
Code:
[general]
context=default
bindport=5061                   ; UDP Port to bind to (SIP standard port is 5060)
bindaddr=0.0.0.0                ; IP address to bind to (0.0.0.0 binds to all)
tcpenable=yes
tcpbindaddr=0.0.0.0:5061
externhost=xxxxxx.dyndns.org
;tlsenable=yes                  ; tls is not enabled by default
;tlsbindaddr=0.0.0.0:5062       ; default tls port is 5061 which conflicts with
                                ; default fritzbox asterisk sip port 5061
srvlookup=yes                   ; Enable DNS SRV lookups on outbound calls
language=de
nat=yes
canreinvite=no
localnet=192.168.166.0/255.255.255.0

[7702]
context=sip7702
callerid="TestSIP 7702" <7702>
host=dynamic
domain=192.168.166.254
;nat=yes                       ; X-Lite is behind a NAT router
type=friend
user=7702
secret=7702
;mailbox=7702
;canreinvite=no                ; Typically set to NO if behind NAT
;regexten=1234                 ; When they register, create extension 1234
;username=xlite1
disallow=all
allow=gsm                     ; GSM consumes far less bandwidth than ulaw
allow=ulaw
allow=alaw
 
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.