Auto-dial does not work. help!

I follow the steps in voip-info to setup the auto-dial. It works great if I auto-dial to my own SIP extension. If I want to auto-dial to an outside nuber through my ZAP trunk, the outside # never gets the call. Any idea?

I follow the instructions listed here

voip-info.org/tiki-index.php … o-dial+out
voip-info.org/wiki/index.php … er+message

Here is my call file

Working One:

not working one:

I am using a X101P card. I can dail-in and call-out fine through this ZAP trunk. But the auto-dial just won’t work!

Please help! Thank you.

Any idea? Please help. Thank you.

post the CLI output when you attempt to initiate the call, with debug turned on - that will be the biggest help.

ok. This is when it works when dials to SIP/202

This is when it does not work, dial through ZAP to a outside #

post your zapata.conf - it looks like asterisk can’t even initiate the zap channel, which is why the call is failing.

Really? But I can call in/out fine with Linksys SPA2102 through my ZAP line with an analog phone.

Anyhow, here is my file

try this - change

Channel: Zap/1/1408xxxxxxx

to

Channel: Zap/g1/1408xxxxxxx

are you using freepbx or *@home or something?

Tried and it is the same… :frowning:

Here is the log

I am using Trixbox with freePBX. I did manually upgrade astrisk, zaptel, libpri to the lastest version.

Any idea? Thanks

can you post the zapata_additional.conf? i’m not sure i’ll be able to make heads or tails out of it, but it might shed some light on what is going on…

zapata_additional.conf has nothing inside. This is zapata_auto.conf

; Autogenerated by /usr/local/sbin/genzaptelconf -- do not hand edit
; Zaptel Channels Configurations (zapata.conf)
;
; This is not intended to be a complete zapata.conf. Rather, it is intended 
; to be #include-d by /etc/zapata.conf that will include the global settings
;
callerid=asreceived

; Span 1: WCFXO/0 "Wildcard X101P Board 1" 
signalling=fxs_ks
; Note: this is a trunk. Create a ZAP trunk in AMP for Channel 1
context=from-zaptel
group=0
channel => 1

can you initiate a regular outbound call via your extension and post the CLI results? this is really confusing me and i can’t see an issue off the top of my head…

Okay. Thanks for all your help!! :smile:

Here is the log, called from analog phone through SPA2102 (ext 202) to a outside number through ZAP

Sep 7 13:15:52 DEBUG[3501] manager.c: Manager received command 'Command'
Sep 7 13:15:52 DEBUG[3501] manager.c: Manager received command 'Command'
Sep 7 13:15:55 DEBUG[4221] chan_zap.c: Exception on 14, channel 1
Sep 7 13:15:55 DEBUG[4221] chan_zap.c: Got event Dial Complete(9) on channel 1 (index 0)
Sep 7 13:15:55 DEBUG[4221] chan_zap.c: Echo cancellation already on
Sep 7 13:16:01 DEBUG[4221] channel.c: Didn't get a frame from channel: SIP/202-09b6c3c8
Sep 7 13:16:01 DEBUG[4221] channel.c: Bridge stops bridging channels SIP/202-09b6c3c8 and Zap/1-1
Sep 7 13:16:01 DEBUG[4221] chan_zap.c: Hangup: channel: 1 index = 0, normal = 14, callwait = -1, thirdcall = -1
Sep 7 13:16:01 DEBUG[4221] chan_zap.c: disabled echo cancellation on channel 1
Sep 7 13:16:01 DEBUG[4221] chan_zap.c: Set option TDD MODE, value: OFF(0) on Zap/1-1
Sep 7 13:16:01 DEBUG[4221] chan_zap.c: Updated conferencing on 1, with 0 conference users
Sep 7 13:16:01 DEBUG[4221] app_dial.c: Exiting with DIALSTATUS=ANSWER.
Sep 7 13:16:01 DEBUG[4221] cdr_addon_mysql.c: cdr_mysql: inserting a CDR record.
Sep 7 13:16:01 DEBUG[4221] cdr_addon_mysql.c: cdr_mysql: SQL command as follows: INSERT INTO cdr (calldate,clid,src,dst,dcontext,channel,dstchannel,lastapp,lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid) VALUES ('2006-09-07 13:15:04','\"SAP2102-1\" <202>','202','14085693835','from-internal', 'SIP/202-09b6c3c8','Zap/1-1','Dial','ZAP/1/91408xxxxxxx|120|r',57,51,'ANSWERED',3,'','1157660104.0')
Sep 7 13:16:02 DEBUG[4221] chan_sip.c: update_call_counter(202) - decrement call limit counter

Use X-Lite to call to the same number (ext 201)

Sep 7 13:17:17 DEBUG[3289] chan_sip.c: Setting NAT on RTP to 0
Sep 7 13:17:17 DEBUG[3289] chan_sip.c: Stopping retransmission on '8b2f9757c11cac6bMTdkOWIxNzQ0OGVmMzcyNjVjNmYxMTNmMzMxNTJkNTg.' of Response 1: Match Found
Sep 7 13:17:17 DEBUG[3289] chan_sip.c: Setting NAT on RTP to 0
Sep 7 13:17:17 DEBUG[3289] chan_sip.c: Checking SIP call limits for device 201
Sep 7 13:17:17 DEBUG[3289] chan_sip.c: build_route: Contact hop:
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '1'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '0'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Not taking any branch
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '0'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Not taking any branch
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is '201'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is '201'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is 'X-Lite'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '0'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Not taking any branch
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is '"X-Lite" <201>'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is '201'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is '0'
Sep 7 13:17:17 VERBOSE[4278] logger.c: recordingcheck|20060907-131717|1157660237.2: Outbound recording not enabled
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '1'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is ''
Sep 7 13:17:17 DEBUG[4278] db.c: Unable to find key '201/emergency_cid' in family 'DEVICE'
Sep 7 13:17:17 DEBUG[4278] func_db.c: DB: DEVICE/201/emergency_cid not found in database.
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is ''
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '1'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '1'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '1'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is '"X-Lite" <201>'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is '1'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '0'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Not taking any branch
Sep 7 13:17:17 DEBUG[4278] pbx.c: Function result is 'ZAP/1'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Expression result is '0'
Sep 7 13:17:17 DEBUG[4278] pbx.c: Not taking any branch
Sep 7 13:17:17 DEBUG[4278] dsp.c: dsp busy pattern set to 0,0
Sep 7 13:17:17 DEBUG[4278] chan_zap.c: Dialing '91408xxxxxxx'
Sep 7 13:17:17 DEBUG[4278] chan_zap.c: Deferring dialing...
Sep 7 13:17:18 DEBUG[4278] chan_zap.c: Exception on 14, channel 1
Sep 7 13:17:18 DEBUG[4278] chan_zap.c: Got event Hook Transition Complete(12) on channel 1 (index 0)
Sep 7 13:17:20 DEBUG[4278] chan_zap.c: Exception on 14, channel 1
Sep 7 13:17:20 DEBUG[4278] chan_zap.c: Got event Dial Complete(9) on channel 1 (index 0)
Sep 7 13:17:20 DEBUG[4278] chan_zap.c: Enabled echo cancellation on channel 1
Sep 7 13:17:20 DEBUG[4278] chan_zap.c: Engaged echo training on channel 1
Sep 7 13:17:23 DEBUG[4278] chan_zap.c: Exception on 14, channel 1
Sep 7 13:17:23 DEBUG[4278] chan_zap.c: Got event Dial Complete(9) on channel 1 (index 0)
Sep 7 13:17:23 DEBUG[4278] chan_zap.c: Echo cancellation already on
Sep 7 13:17:23 DEBUG[3289] chan_sip.c: Stopping retransmission on '8b2f9757c11cac6bMTdkOWIxNzQ0OGVmMzcyNjVjNmYxMTNmMzMxNTJkNTg.' of Response 2: Match Found
Sep 7 13:17:52 DEBUG[3501] manager.c: Manager received command 'Command'
Sep 7 13:17:52 DEBUG[3501] manager.c: Manager received command 'Command'
Sep 7 13:18:07 DEBUG[4278] chan_zap.c: Exception on 14, channel 1
Sep 7 13:18:07 DEBUG[4278] chan_zap.c: Got event Dial Complete(9) on channel 1 (index 0)
Sep 7 13:18:07 DEBUG[4278] chan_zap.c: Echo cancellation already on
Sep 7 13:18:12 DEBUG[4278] channel.c: Didn't get a frame from channel: SIP/201-09b6c3c8
Sep 7 13:18:12 DEBUG[4278] channel.c: Bridge stops bridging channels SIP/201-09b6c3c8 and Zap/1-1
Sep 7 13:18:12 DEBUG[4278] chan_zap.c: Hangup: channel: 1 index = 0, normal = 14, callwait = -1, thirdcall = -1
Sep 7 13:18:12 DEBUG[4278] chan_zap.c: disabled echo cancellation on channel 1
Sep 7 13:18:12 DEBUG[4278] chan_zap.c: Set option TDD MODE, value: OFF(0) on Zap/1-1
Sep 7 13:18:12 DEBUG[4278] chan_zap.c: Updated conferencing on 1, with 0 conference users
Sep 7 13:18:12 DEBUG[4278] app_dial.c: Exiting with DIALSTATUS=ANSWER.
Sep 7 13:18:12 DEBUG[4278] cdr_addon_mysql.c: cdr_mysql: inserting a CDR record.
Sep 7 13:18:12 DEBUG[4278] cdr_addon_mysql.c: cdr_mysql: SQL command as follows: INSERT INTO cdr (calldate,clid,src,dst,dcontext,channel,dstchannel,lastapp,lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid) VALUES ('2006-09-07 13:17:17','\"X-Lite\" <201>','201','14085693835','from-internal', 'SIP/201-09b6c3c8','Zap/1-1','Dial','ZAP/1/91408xxxxxxx|120|r',55,49,'ANSWERED',3,'','1157660237.2')
Sep 7 13:18:12 DEBUG[4278] chan_sip.c: update_call_counter(201) - decrement call limit counter

This is the log when I use the auto-dial *.call file to to dial outside. I relaized that the one I did before does not have the “9” in front. I added “9” this time but my outside line still not ringing.

Thanks.

Sep 7 13:23:35 DEBUG[4562] dsp.c: dsp busy pattern set to 0,0
Sep 7 13:23:35 DEBUG[4562] chan_zap.c: Dialing '91408xxxxxxx'
Sep 7 13:23:35 DEBUG[4562] chan_zap.c: Deferring dialing...
Sep 7 13:23:36 DEBUG[4562] chan_zap.c: Exception on 14, channel 1
Sep 7 13:23:36 DEBUG[4562] chan_zap.c: Got event Hook Transition Complete(12) on channel 1 (index 0)
Sep 7 13:23:38 DEBUG[4562] chan_zap.c: Exception on 14, channel 1
Sep 7 13:23:38 DEBUG[4562] chan_zap.c: Got event Dial Complete(9) on channel 1 (index 0)
Sep 7 13:23:38 DEBUG[4562] chan_zap.c: Enabled echo cancellation on channel 1
Sep 7 13:23:38 DEBUG[4562] chan_zap.c: Engaged echo training on channel 1
Sep 7 13:23:40 DEBUG[4562] chan_zap.c: Exception on 14, channel 1
Sep 7 13:23:40 DEBUG[4562] chan_zap.c: Got event Dial Complete(9) on channel 1 (index 0)
Sep 7 13:23:40 DEBUG[4562] chan_zap.c: Echo cancellation already on
Sep 7 13:23:40 WARNING[4562] pbx.c: ResponseTimeout is deprecated, please use Set(TIMEOUT(response)=timeout) instead.
Sep 7 13:23:41 DEBUG[4562] channel.c: Scheduling timer at 160 sample intervals
Sep 7 13:23:45 DEBUG[4562] channel.c: Scheduling timer at 0 sample intervals
Sep 7 13:23:45 DEBUG[4562] channel.c: Scheduling timer at 0 sample intervals
Sep 7 13:23:45 DEBUG[4562] channel.c: Scheduling timer at 160 sample intervals
Sep 7 13:23:52 DEBUG[3501] manager.c: Manager received command 'Command'
Sep 7 13:23:52 DEBUG[3501] manager.c: Manager received command 'Command'
Sep 7 13:23:52 DEBUG[4562] channel.c: Scheduling timer at 0 sample intervals
Sep 7 13:23:52 DEBUG[4562] channel.c: Scheduling timer at 0 sample intervals
Sep 7 13:24:03 DEBUG[4562] channel.c: Scheduling timer at 160 sample intervals
Sep 7 13:24:04 DEBUG[4562] channel.c: Scheduling timer at 154 sample intervals
Sep 7 13:24:04 DEBUG[4562] channel.c: Scheduling timer at 0 sample intervals
Sep 7 13:24:04 DEBUG[4562] channel.c: Scheduling timer at 0 sample intervals
Sep 7 13:24:04 DEBUG[4562] cdr_addon_mysql.c: cdr_mysql: inserting a CDR record.
Sep 7 13:24:04 DEBUG[4562] cdr_addon_mysql.c: cdr_mysql: SQL command as follows: INSERT INTO cdr (calldate,clid,src,dst,dcontext,channel,dstchannel,lastapp,lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid) VALUES ('2006-09-07 13:23:40','','','t','outboundmsg1', 'Zap/1-1','','Hangup','',24,24,'ANSWERED',3,'','1157660615.7')
Sep 7 13:24:04 DEBUG[4562] chan_zap.c: Hangup: channel: 1 index = 0, normal = 14, callwait = -1, thirdcall = -1
Sep 7 13:24:04 DEBUG[4562] chan_zap.c: disabled echo cancellation on channel 1
Sep 7 13:24:04 DEBUG[4562] chan_zap.c: Set option TDD MODE, value: OFF(0) on Zap/1-1
Sep 7 13:24:04 DEBUG[4562] chan_zap.c: Updated conferencing on 1, with 0 conference users
Sep 7 13:24:04 NOTICE[4562] pbx_spool.c: Call completed to Zap/1/91408xxxxxxx

now it’s showing ANSWERED instead of FAILED for the dispo, though - that indicates that you’re making progress.

check your logger.conf, make sure the messages line has verbose in it…i think we’re missing some of the more important data, which probably will help figure the issue out.

It works now!! However, it works a bit funny…

After placing my auto-dial script to the /var/spool/asterisk/outgoing, my external phone will ring. If I answer the phone early, I can hear half of the message. If I pick up late, I won’t hear the message. It seems like Asterisk is playing my message file before I answer the phone. When I autodial to my internal SIP externsion, it won’t do this.

Any idea? Thanks.

The following is my log after I did the verbose.

Thanks.

seems like asterisk is seeing the zap trunk “answer” the phone before you actually pick up, which then means the manager will route the call to you internal extension…

i don’t think your logger changes took - do a ‘logger reload’ on the CLI, and see if asterisk is answering the zap trunk before you pick up…my guess is that it is. how to fix that depends on a number of things…

I see… I was showing you the “full” log. here is the “message” log

Yes, I had the same problem initially.

Unlesss you are fortunate to have answer supervision on your pots line asterisk will say that the call is answered once it hands the call over to the zap channel. That is why your message plays while the other phone rings. If you have answer supervision on your pots, you can use the command answeronpolarityswtich = yes. Otherwise, you need to use Backgrounddetect or Waitforsilence. The silence between rings if you are in the USA is 4000 ms, so set your Waitforsilence to 4250.

If you use sip channel, answer supervision works fine.

Thanks. Can you tell me where to put answeronpolarityswtich and Waitforsilence? What file do I need to edit?

Thank you.