[asterisk-users] call file question
Steve Edwards
asterisk.org at sedwards.com
Wed Jun 30 23:37:11 CDT 2010
On Thu, 1 Jul 2010, Jeff LaCoursiere wrote:
> I am sure this is simple, but have been struggling. I want to create a
> call file that dials out a particular Dahdi channel to enable call
> forwarding on a POTS line. I have this in extensions.conf:
>
> [custom-callfwd]
> exten => s,1,Answer
> exten => s,n,Dial(DAHDI/4-1/*717157750)
> exten => s,n,Verbose(${DIALSTATUS})
> exten => s,n,Hangup
>
> [custom-callfwdcanc]
> exten => s,1,Answer
> exten => s,n,Dial(DAHDI/4-1/*72)
> exten => s,n,Verbose(${DIALSTATUS})
> exten => s,n,Hangup
>
> Using FreePBX I have setup "custom destinations" and "custom
> applications" such that users can dial a code from their desks and
> enable or disable forwarding via the above contexts. That works fine.
>
> Now I whipped up a C program to create a call file to do the same thing
> from the command line:
>
> [snip]
> fprintf(callfile, "Channel: Local/*71 at custom-callfwd/n\n");
I don't see exten "*71" in custom-callfwd.
Why are you using a local channel in your call file?
> fprintf(callfile, "Application: Playback\n");
> fprintf(callfile, "Data: hello-world\n");
> [snip]
>
> When I run this it creates the call file and I see this in the console:
>
> -- Attempting call on Local/*71 at custom-callfwd/n for application
> Playback(hello-world) (Retry 1)
What does the call file look like before you mv it to the spool directory?
--
Thanks in advance,
-------------------------------------------------------------------------
Steve Edwards sedwards at sedwards.com Voice: +1-760-468-3867 PST
Newline Fax: +1-760-731-3000
More information about the asterisk-users
mailing list