(solved)can * with HFC card and PBX coexist on one ISDN line


i have been looking aournd all day now, i can not seem to find the right info.
i am totally new to this telephone stuff, which is a problem i know.
you can hit me with tech talk about linux, but please bare with me
when it comes to telephone stuff :unamused:

i have a euro isdn line (germany) with the standard setup.

what i would like to do is setup asterisk, so that i can use it to receive
voicemail and faxes for certain numbers (got 6).
my pbx also got a S0 connection, so what i would like to do ist the following.

…->ntba->pbx->asterisk on linux box

so hook up asterisk to the S0 port of the pbx, or

…->asterisk on linux box

i have got asterisk installed and it does seem to work.
the problem i got now is, that it takes control of the whole isdn line.
as soon as asterisk is running, the pbx led is blinking, which means
that the isdn connection has been lost.

has anyone got an idea on what i am doing wrong ?
will it work at all, or will asterisk always be master ?
has anyone got a link to info on this ?

[code]ztcfg -v
Zaptel Configuration

SPAN 1: CCS/ AMI Build-out: 399-533 feet (DSX-1)

3 channels configured.

here are the config files i have changed.


hfc-s pci a SPAN Definitionen


/etc/asterisk/zapta.conf [channels] ;---------------------------------------------------------------------------- ;NT-Karte fuer ISDN-Telefonanlage im Mehrgeraete-Anschluss ;---------------------------------------------------------------------------- switchtype = euroisdn signalling = bri_net_ptmp pridialplan = local prilocaldialplan = local echocancel = yes overlapdial = yes echocancelwhenbridged=no echotraining=no immediate = no usecallerid = yes group = 1 context = pbx-trunk channel => 1 usecallingpres=yes nationalprefix = 0 internationalprefix = 00
i have tried signalling = bri_net_ptp, but then asterisk does not start any more.


IAXINFO=guest ; IAXtel username/password
include => tcom-trunk
include => pbx-trunk

; Hereinkommende Anrufe werden auf interne MSN 3333 geleitet
exten => _X.,1,Dial(Zap/g2/3333,60)
exten => _X.,2,Hangup

; 8 vorwaehlen -> Ueber ISDN waehlen
; ${EXTEN:1} bedeutet, dass von der zu waehlenden Rufnummer eine
; Ziffer abgeschnitten wird, hier also die ‘8’.
exten => _8.,1,Dial(Zap/g1/${EXTEN:1}/,60)
exten => _8.,2,Congestion
exten => _8.,3,Busy
exten => _8.,4,Hangup
; 9 vorwaehlen -> Ueber SIP waehlen
exten => _9.,1,Dial(SIP/${EXTEN:1}@myqsc,60)
exten => _9.,2,Congestion
exten => _9.,3,Busy
exten => _9.,4,Hangup[/code]

/etc/asterisk/rtp.conf [general] ; ; RTP start and RTP end configure start and end addresses ; rtpstart=10000 rtpend=11000

hope someone can help me out on this,


it is probably my englisch, but maybe if i clarify
this a little more, someone can answer this simple question.

is it possible to connect asterisk and another computer or
telefon hardware to the same S0 bus ?
if so, what needs to be in the config files ?

as soon as i run asterisk, everything else connected to
the S0 bus is dead.

hope someone has an answer, since asterisk seems to be a
pretty cool tool and i would like to use it for voicemail,
fax and VoIP but keeping my old telephone hardware.


The problem you need to put a 100Ohm resistore on TX and RX and you need to put the power on the S0.


great, someone with an answer :smiley:

power on the S0
doesn’t the telephone hardware or the NTBA supply that ?

100Ohm resistore on TX and RX
hhhmmmmm, do i need to cut the cable and place them in there ?
if so, which wires ? the ones in the middle i crossed.


The HFC configured in NT mode is not able to give the tension on the cable and you need to make a “cross over” cable in order to connect a phone.

need to make a “cross over” cable
i have already done that.

… order to connect a phone
i do not really want to connect a phone (hardware).
i want to use it for voicemail, fax and VoIP.
the old telephone hardware is supposed to stay and i want asterisk
to “listen” on the S0 bus and act as an answering machine and
then i would also like to use asterisk to make calls using a softphone.

in other words, i would like to use asterisk just like mgetty, which shares
the ISDN lines, but with a lot more features.

I do not understand, where you connect your HFC card?


I do not understand, where you connect your HFC card?
i connect it in parallel to the other telephonehardaware.
(1 NTBA = 2 S0 bus connections. one goes to the telephonehardware and
the other to the HFC card.)

if i would use the HFC card to surf the net without using both channels,
then i can still make another call on the other line.
asterisk however seems to assume that it is master and grabs both
channels, so that i can not make any more phone calls (both lines
are used).


In /etc/asterisk/zapata.conf

signalling = bri_net_ptmp

You are running the card in NT-mode? Why?
I think that you need to run the card in TE-mode. That is, in /etc/asterisk/zapata.conf:

signalling = bri_cpe_ptmp

or maybe

signalling = bri_cpe

You only need NT-mode if you want to create an S0-bus with Asterisk, as a relacement of the S0-bus that the phone company+NTBA is providing you.
Now you probably create a conflict on the S0-bus (two masters on one bus).
In NT-mode you will need a cross-cable, you need normal ISDN-cables and TE-mode.

How do you load the zaphfc module? For NT-mode or TE-mode. It should be for TE-mode as well, of course. Take a look at voip-info.org/tiki-index.php … isk+zaphfc
You need to use

insmod zaphfc.ko modes=0

and NOT

insmod zaphfc.ko modes=1

Also take a look at voip-info.org/tiki-index.php … apata.conf
The syntax of zapata.conf is such that you always end with a “channel =>” statement. Everything before that statement is than assigned to that channel.
(in your case: “signalling=bri_cpe_ptmp” is before “channel =>1”, so for channel 1 you have set signalling=bri_cpe_ptmp)

The last statements in your zapata.conf are not followed by any “channel =>” statement and are therefore not assigned to any channel (so you can as well leave these statements out).

In /etc/zaptel.conf you have


So you have three channels: 2 B-channels (data/voice) and 1 D-channel (signalling).
The settings in your zapata.conf are only for the first B-channel. Did you do this with a special reason? I would think that you want the zapata.conf settings also for the second B-channel (replace “channel=>1” in zapata.conf by “channel => 1-2”, and put it as the last statement in zapata.conf

hi gerralt,

that looks like just what i needed, thanx.
i will try it out as soon as i can get to it.


hi Gerralt,

with the changes you have shown me, it is working just like i want it.
excellent !!