From: FERNANDO V. <fvi...@ya...> - 2007-01-29 18:32:51
|
thanks for the answer Matthew. ....soon I prove it. Bye --- Matthew Nicholson <mni...@di...> wrote: > It does not execute the script on answer because the > dialing party hangs > up the channel before the script can execute. There > is an option to > dial to prevent that when the remote party hangs up, > but the best thing > would be to move execution of your script to the 'h' > exten: > > [andes] > > exten => _325405,1,Answer > exten => _325405,2,Noop(Cuenta cliente >>> > ${ACCOUNTCODE}) > exten => _325405,3,Set(NUMERO=111${EXTEN}) > exten => _325405,4,goto(${NUMERO},1) > > exten => _111.,1,Dial(SIP/${NUMERO:3},3) > exten => _111.,2,Hangup > > exten => h,1,AGI(trafico/graba.py|...) > > That way it will always get executed when the > channel is destroyed. > > FERNANDO VILLARROEL wrote: > > Hello I have the following problem; when I execute > > this script python, if the result is different to > > ANSWER works perfect and it keeps the registry to > me > > in the data base. > > > > -- Executing > Answer("SIP/192.168.0.2-081b0bc0", > > "") in new stack > > -- Executing NoOp("SIP/192.168.0.2-081b0bc0", > > "Cuenta cliente >>> andescall") in new stack > > -- Executing Set("SIP/192.168.0.2-081b0bc0", > > "NUMERO=111325405") in new stack > > -- Executing Goto("SIP/192.168.0.2-081b0bc0", > > "111325405|1") in new stack > > -- Goto (andes,111325405,1) > > -- Executing Dial("SIP/192.168.0.2-081b0bc0", > > "SIP/325405|3") in new stack > > -- Called 325405 > > -- Got SIP response 486 "Busy Here" back from > > 192.168.0.10 > > -- SIP/325405-081b68f8 is busy > > == Everyone is busy/congested at this time > (1:1/0/0) > > -- Executing AGI("SIP/192.168.0.2-081b0bc0", > > "trafico/graba.py|andescall||BUSY|325405") in new > > stack > > -- Launched AGI Script > > /var/lib/asterisk/agi-bin/trafico/graba.py > > trafico/graba.py|andescall||BUSY|325405: 0 > > trafico/graba.py|andescall||BUSY|325405: BUSY > > -- AGI Script trafico/graba.py completed, > > returning 0 > > -- Executing > Hangup("SIP/192.168.0.2-081b0bc0", > > "") in new stack > > == Spawn extension (andes, 111325405, 3) exited > > non-zero on 'SIP/192.168.0.2-081b0bc0' > > > > > > > > But the result is ANSWER does not execute the AGI > to > > me so that? > > > > -- Executing > Answer("SIP/192.168.0.2-081b0bc0", > > "") in new stack > > -- Executing NoOp("SIP/192.168.0.2-081b0bc0", > > "Cuenta cliente >>> andescall") in new stack > > -- Executing Set("SIP/192.168.0.2-081b0bc0", > > "NUMERO=111325405") in new stack > > -- Executing Goto("SIP/192.168.0.2-081b0bc0", > > "111325405|1") in new stack > > -- Goto (andes,111325405,1) > > -- Executing Dial("SIP/192.168.0.2-081b0bc0", > > "SIP/325405|3") in new stack > > -- Called 325405 > > -- SIP/325405-081b68f8 is ringing > > -- SIP/325405-081b68f8 answered > > SIP/192.168.0.2-081b0bc0 > > -- Attempting native bridge of > > SIP/192.168.0.2-081b0bc0 and SIP/325405-081b68f8 > > == Spawn extension (andes, 111325405, 1) exited > > non-zero on 'SIP/192.168.0.2-081b0bc0' > > > > > > extension.conf > > > > [andes] > > > > exten => _325405,1,Answer > > exten => _325405,2,Noop(Cuenta cliente >>> > > ${ACCOUNTCODE}) > > exten => _325405,3,Set(NUMERO=111${EXTEN}) > > exten => _325405,4,goto(${NUMERO},1) > > > > exten => _111.,1,Dial(SIP/${NUMERO:3},3) > > exten => > > > _111.,2,agi,trafico/graba.py|${ACCOUNTCODE}|${ANSWEREDTIME}|${DIALSTATUS}|${NUMERO:3} > > exten => _111.,3,hangup > > > > > > Any idea. > > > > Thanks. > > > > Fernando Villarroel Noriel > > > > > > > > > ____________________________________________________________________________________ > > Looking for earth-friendly autos? > > Browse Top Cars by "Green Rating" at Yahoo! Autos' > Green Center. > > http://autos.yahoo.com/green_center/ > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of > IT > > Join SourceForge.net's Techsay panel and you'll > get the chance to share your > > opinions on IT & business topics through brief > surveys - and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Pyst-users mailing list > > Pys...@li... > > > https://lists.sourceforge.net/lists/listinfo/pyst-users > > -- > Matthew Nicholson > Digium > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get > the chance to share your > opinions on IT & business topics through brief > surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Pyst-users mailing list > Pys...@li... > https://lists.sourceforge.net/lists/listinfo/pyst-users > ____________________________________________________________________________________ Finding fabulous fares is fun. Let Yahoo! FareChase search your favorite travel sites to find flight and hotel bargains. http://farechase.yahoo.com/promo-generic-14795097 |