[asterisk-users] DAHDI FXO port only recognizes the "S"extension?

Danny Nicholas danny at debsinc.com
Wed Sep 29 11:10:54 CDT 2010


-----Original Message-----
From: asterisk-users-bounces at lists.digium.com
[mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Songtao Yu
Sent: 29 September 2010 10:56
To: asterisk-users at lists.digium.com
Subject: [asterisk-users] DAHDI FXO port only recognizes the "S"
extension?


Hi All,

When I tried to write my dial plan as below for my FXO port, which
connects one PSTN line:

[from-pstn]
exten =>s,1,Answer()
exten =>s,n,Wait(1)
exten =>_X.,1,Dial(DAHDI/1)
exten =>_X.,n,Hangup

I got the following message:
Connected to Asterisk 1.6.2.13 currently running on fax (pid = 8154)
Verbosity was 0 and is now 4
    -- Starting simple switch on 'DAHDI/1-1'
    -- Executing [s at from-pstn:1] Answer("DAHDI/1-1", "") in new stack
    -- Executing [s at from-pstn:2] Wait("DAHDI/1-1", "1") in new stack
    -- Auto fallthrough, channel 'DAHDI/1-1' status is 'UNKNOWN'
    -- Hungup 'DAHDI/1-1'

But if I changed the "_X." to "S" extension, I can get the whole thing
to work well:
[from-pstn]
exten =>s,1,Answer()
exten =>s,n,Wait(1)
exten =>s,n,Dial(DAHDI/3)
exten =>s,n,Hangup

Would you please let me which casuses this issue?

Thanks,
Songtao Yu 


<snip>

<reply 1>
>-----Original Message-----
>From: asterisk-users-bounces at lists.digium.com
[mailto:asterisk-users->bounces at lists.digium.com] On Behalf Of Andrew Thomas
>Sent: Wednesday, September 29, 2010 10:59 AM
>To: Asterisk Users Mailing List - Non-Commercial Discussion
>Subject: Re: [asterisk-users] DAHDI FXO port only recognizes the
"S"extension?

>The cause is bad programming.  You can't go from an 's' to an '_X.' the
way you tried.

>exten =>s,1,Answer()
>exten =>s,n,Wait(1)
>exten =>s,n,Dial(DAHDI/3)
>exten =>s,n,Hangup

>Is correct (that's why it works).

>What is it you are trying to achieve?

** Thank (NOT GOD) for Microsoft Outlook **

To (hopefully) illuminate, the two "s" lines in post 1 are "path 1" that is
followed by everything that hits this context;  the two _X. lines would only
be executed if the context were hit with a number.  As "I" read this code,
it looks like OP wants to answer one line and open a "manual dial" on the
other.  If I ran this in my shop (second "correct" post), assuming I wasn't
calling in on DAHDI/3, Asterisk would open the line, wait 1 second, then
give me a dial tone to make a new call using DAHDI/3.  When I finished the
call, * would hang up.





More information about the asterisk-users mailing list