Help Setting Up In bound calls on Zap Trunk


#1

Hello All

I have installed asterisk@home 2.8. I have two x100p clone cards which is on zap/1 and zap/2. i have two bell south line connected to it.

I would like to detect calls coming in on zap trunk 1 and forward it to specific extension. if calls comes in on zap trunk 2 it will also be forwarded to a specific extension or a group.

I have tried this with freePBX and creating a inbound calling rule where i set the DID number as the bell south line number. But that didn’t work.

could someone direct me to the right direction how to do this.
Thanks in advance.


#2

I dont use @home or free Pbx but if each zap trunk is in its own contex in zapata and extensions config files then it should work


#3

setting the DID won’t help. as rusty said, you need to have a context for each zap channel.


#4

thanks for your replies. any idea how to create context


#5

[line1]

for example?

i’d put this in extensions_custom.conf and have it then do whatever preprocessing it needs then jump to from-pstn…


#6

thanks for all the suggestion. i was trying to find some examples on the help pages on how to create context

i haven’t been found any documentation on how to set up a trunk and handle incoming calls.

the help docs seems to be scatereted all over the place and finding information seems to be tough. unless i am looking at the wrong place.

any suggestions?
thanks.


#7

if you are using AAH, it should be self-explanatory. e.g. go to the Trunks screen and click on adding a trunk and select Zap and go from there.


#8

in aah it doesn’t allow you to create any trunk or in bound call based on a trunk. i can create trunk but only there i can say outbound rule.

on in bound rule i can set it up for DID or CID but not on a trunk.


#9

oh, right. what i meant was, you have to add that context in the zapata.conf file (i think that’s it) for each channel…


#10

i was hoping someone will give me a link or paste some code. if anyone…can please help.


#11

honestly, this isn’t that hard. if you really want to be customizing asterisk, you need to read docs and such and figure out how this stuff works.


#12

voip-info.org/wiki-Asterisk+ … apata.conf


#13

thanks for your reply.

I found the answer. if anyone interested.

how to route in coming calls based on ZAP CHANNEL.

I am using Asterisk@Home and freePBX web admin 2.1

Go to Tools in you freePBX admin page.
Click on /etc/asterisk
go to
extensions_custom.conf
click on ext-did-custom or look for it

you will see this:

[ext-did-custom]
; this will allow calls to be routed by the ZAP channel they come in on.
; example a call comming in on ZAP cahnnel 1 will have Zap1 for it’s DID.

exten => s,2,GotoIf($["${CHANNEL:0:3}" = “Zap”]?ext-did|Zap${CHANNEL:4:1}|1)

CHANGE s,2… to s,1

exten => s,1,GotoIf($["${CHANNEL:0:3}" = “Zap”]?ext-did|Zap${CHANNEL:4:1}|1)

NOW GO BACK TO freePBX SETUP
Click on InBound Routes
Click on Add Incoming Route
on the DID Number: Zap1
it can be any channel number like if you have Zap10

Set the desitination. Wala! it worked for me.


#14

FreePBX 2.1 allows you to create Inbound Routes based on Zap channels now. You don’t have to muck about with custom contexts any more. The Inbound Routes now has a “Zaptel Channel” option.

Just make sure your Zapata.conf has your Zaptel context as “from-zaptel” for it to work, as specified in the pop-up help for the Zaptel Channel option on the Inbound Routes screen.

You then keep the DID and CID fields blank.


#15

question: i tried this and got a “no DID or CID match” error. poked around and found that zapata-auto.conf was still saying ‘context=from-pstn’. i fixed that, but that file is not supposed to be edited manually, but is created by genzaptelconf?