On 11/01/2019 09:19, Administrator TOOTAI wrote:> Le 11/01/2019 à 10:12, Neil Youngman a écrit : >> A while back, I posted about detecting when a call was picked up by a >> fax machine. It was suggested that having a "fax" extension and >> "faxdetect=yes" would cause it to jump to the "fax" extension. This >> was not something I could get to work. >> >> I have now created a very simple example. In sip.conf I have >> "faxdetect = yes". My example extension is: >> >> [test] >> ; >> ; Voice test extension >> ; >> exten => voicetest,1,NoOp() >> same => n,LOG(Notice,${CHANNEL}: Extension voiceout starting) >> same => n,LOG(Notice,${CHANNEL}: Starting Answer Machine Detection) >> same => n,AMD() >> same => n,LOG(Notice,${CHANNEL}: Answer Machine Detection >> ${AMDSTATUS}/${AMDCAUSE}) >> same => n,Playback(/var/lib/asterisk/sounds/en/demo-congrats) >> same => n,LOG(Notice,${CHANNEL}: Voice out extension complete) >> same => n(hangup),Hangup() >> >> >> ; >> ; Fax detected extension >> ; >> exten => fax,1,NoOp() >> same => n,LOG(Notice,${CHANNEL}: Extension fax starting) >> same => n,LOG(Notice,${CHANNEL}: Fax Machine Detected) >> same => n,Playback(/var/lib/asterisk/sounds/en/silence/2) >> same => n,LOG(Notice,${CHANNEL}: Fax extension complete) >> same => n(hangup),Hangup() >> >> and the logs show that calling a fax using the voiceout extension in >> context test does not result in the fax extension being triggered. >> >> [Jan 11 08:55:10] NOTICE[18073][C-00000115] Ext. voicetest: >> SIP/31.13.156.183:5060-000000f4: Extension voiceout starting >> [Jan 11 08:55:10] NOTICE[18073][C-00000115] Ext. voicetest: >> SIP/31.13.156.183:5060-000000f4: Starting Answer Machine Detection >> [Jan 11 08:55:13] NOTICE[18073][C-00000115] Ext. voicetest: >> SIP/31.13.156.183:5060-000000f4: Answer Machine Detection >> MACHINE/LONGGREETING-1500-1500 >> [Jan 11 08:55:44] NOTICE[18073][C-00000115] Ext. voicetest: >> SIP/31.13.156.183:5060-000000f4: Voice out extension complete >> >> Just for completeness this is how the call is originated, with a >> different phone number: >> >> Action: Originate >> ActionId: 1234567W001-125 >> Context: test >> Exten: voicetest >> Priority: 1 >> Channel: SIP/+441632660987 at 31.13.156.183:5060 >> Timeout: 60000 >> Async: True >> >> Can anyone offer any insight into why this isn't working? >> >> Neil Youngman >> >> > > You didn't ANSWER() the callIt's an outgoing call. I wouldn't expect to answer an outgoing call? Neil Neil Youngman Developer Wirefast Limited Wirefast provides secure corporate messaging services. See our messaging solutions at http://www.wirefast.com/ Please consider the environment. Does this email or attachment need to be printed? This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this email. Please notify the sender immediately by email if you have received this email by mistake and delete this email from your system. Any views or opinions are solely those of the author and do not necessarily represent those of Wirefast Limited Email transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of email transmission. Wirefast Limited is registered in England & Wales Company number: 03865860 Registered Office: 7/10 Chandos Street, Cavendish Square, London, W1G 9DQ Wirefast definitions of classification can be found here: www.wirefast.com/classifications
I would guess from your explanation that the "outgoing" call somehow ends up in your Asterisk machine again, either at the voicetest or fax extension. You don't answer it in either of the extensions. That's what TOOTAI meant. If this is done in another extension, than this part of the Dialplan is missing in your post. So we can only guess what's going on. Either post the full dialplan or add some log or cli output (with verbose set to at least 1) so we can have a chance of seeing what's going on. With best regards Florian Floimair Innovation - Software-Development COMMEND INTERNATIONAL GMBH A-5020 Salzburg, Saalachstraße 51 http://www.commend.com <http://www.commend.com/> Security and Communication by Commend FN 178618z | LG Salzburg Am 11.01.19, 10:23 schrieb "asterisk-users im Auftrag von Neil Youngman" <asterisk-users-bounces at lists.digium.com im Auftrag von neil.youngman at wirefast.com>: On 11/01/2019 09:19, Administrator TOOTAI wrote: > Le 11/01/2019 à 10:12, Neil Youngman a écrit : >> A while back, I posted about detecting when a call was picked up by a >> fax machine. It was suggested that having a "fax" extension and >> "faxdetect=yes" would cause it to jump to the "fax" extension. This >> was not something I could get to work. >> >> I have now created a very simple example. In sip.conf I have >> "faxdetect = yes". My example extension is: >> >> [test] >> ; >> ; Voice test extension >> ; >> exten => voicetest,1,NoOp() >> same => n,LOG(Notice,${CHANNEL}: Extension voiceout starting) >> same => n,LOG(Notice,${CHANNEL}: Starting Answer Machine Detection) >> same => n,AMD() >> same => n,LOG(Notice,${CHANNEL}: Answer Machine Detection >> ${AMDSTATUS}/${AMDCAUSE}) >> same => n,Playback(/var/lib/asterisk/sounds/en/demo-congrats) >> same => n,LOG(Notice,${CHANNEL}: Voice out extension complete) >> same => n(hangup),Hangup() >> >> >> ; >> ; Fax detected extension >> ; >> exten => fax,1,NoOp() >> same => n,LOG(Notice,${CHANNEL}: Extension fax starting) >> same => n,LOG(Notice,${CHANNEL}: Fax Machine Detected) >> same => n,Playback(/var/lib/asterisk/sounds/en/silence/2) >> same => n,LOG(Notice,${CHANNEL}: Fax extension complete) >> same => n(hangup),Hangup() >> >> and the logs show that calling a fax using the voiceout extension in >> context test does not result in the fax extension being triggered. >> >> [Jan 11 08:55:10] NOTICE[18073][C-00000115] Ext. voicetest: >> SIP/31.13.156.183:5060-000000f4: Extension voiceout starting >> [Jan 11 08:55:10] NOTICE[18073][C-00000115] Ext. voicetest: >> SIP/31.13.156.183:5060-000000f4: Starting Answer Machine Detection >> [Jan 11 08:55:13] NOTICE[18073][C-00000115] Ext. voicetest: >> SIP/31.13.156.183:5060-000000f4: Answer Machine Detection >> MACHINE/LONGGREETING-1500-1500 >> [Jan 11 08:55:44] NOTICE[18073][C-00000115] Ext. voicetest: >> SIP/31.13.156.183:5060-000000f4: Voice out extension complete >> >> Just for completeness this is how the call is originated, with a >> different phone number: >> >> Action: Originate >> ActionId: 1234567W001-125 >> Context: test >> Exten: voicetest >> Priority: 1 >> Channel: SIP/+441632660987 at 31.13.156.183:5060 >> Timeout: 60000 >> Async: True >> >> Can anyone offer any insight into why this isn't working? >> >> Neil Youngman >> >> > > You didn't ANSWER() the call It's an outgoing call. I wouldn't expect to answer an outgoing call? Neil Neil Youngman Developer Wirefast Limited Wirefast provides secure corporate messaging services. See our messaging solutions at http://www.wirefast.com/ Please consider the environment. Does this email or attachment need to be printed? This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this email. Please notify the sender immediately by email if you have received this email by mistake and delete this email from your system. Any views or opinions are solely those of the author and do not necessarily represent those of Wirefast Limited Email transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of email transmission. Wirefast Limited is registered in England & Wales Company number: 03865860 Registered Office: 7/10 Chandos Street, Cavendish Square, London, W1G 9DQ Wirefast definitions of classification can be found here: www.wirefast.com/classifications -- _____________________________________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- Check out the new Asterisk community forum at: https://community.asterisk.org/ New to Asterisk? Start here: https://wiki.asterisk.org/wiki/display/AST/Getting+Started asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Le 11/01/2019 à 10:23, Neil Youngman a écrit :> On 11/01/2019 09:19, Administrator TOOTAI wrote: >> Le 11/01/2019 à 10:12, Neil Youngman a écrit : >>> A while back, I posted about detecting when a call was picked up by >>> a fax machine. It was suggested that having a "fax" extension and >>> "faxdetect=yes" would cause it to jump to the "fax" extension. This >>> was not something I could get to work. >>> >>> I have now created a very simple example. In sip.conf I have >>> "faxdetect = yes". My example extension is: >>> >>> [test] >>> ; >>> ; Voice test extension >>> ; >>> exten => voicetest,1,NoOp() >>> same => n,LOG(Notice,${CHANNEL}: Extension voiceout starting) >>> same => n,LOG(Notice,${CHANNEL}: Starting Answer Machine Detection) >>> same => n,AMD() >>> same => n,LOG(Notice,${CHANNEL}: Answer Machine Detection >>> ${AMDSTATUS}/${AMDCAUSE}) >>> same => n,Playback(/var/lib/asterisk/sounds/en/demo-congrats) >>> same => n,LOG(Notice,${CHANNEL}: Voice out extension complete) >>> same => n(hangup),Hangup() >>> >>> >>> ; >>> ; Fax detected extension >>> ; >>> exten => fax,1,NoOp() >>> same => n,LOG(Notice,${CHANNEL}: Extension fax starting) >>> same => n,LOG(Notice,${CHANNEL}: Fax Machine Detected) >>> same => n,Playback(/var/lib/asterisk/sounds/en/silence/2) >>> same => n,LOG(Notice,${CHANNEL}: Fax extension complete) >>> same => n(hangup),Hangup() >>> >>> and the logs show that calling a fax using the voiceout extension in >>> context test does not result in the fax extension being triggered. >>> >>> [Jan 11 08:55:10] NOTICE[18073][C-00000115] Ext. voicetest: >>> SIP/31.13.156.183:5060-000000f4: Extension voiceout starting >>> [Jan 11 08:55:10] NOTICE[18073][C-00000115] Ext. voicetest: >>> SIP/31.13.156.183:5060-000000f4: Starting Answer Machine Detection >>> [Jan 11 08:55:13] NOTICE[18073][C-00000115] Ext. voicetest: >>> SIP/31.13.156.183:5060-000000f4: Answer Machine Detection >>> MACHINE/LONGGREETING-1500-1500 >>> [Jan 11 08:55:44] NOTICE[18073][C-00000115] Ext. voicetest: >>> SIP/31.13.156.183:5060-000000f4: Voice out extension complete >>> >>> Just for completeness this is how the call is originated, with a >>> different phone number: >>> >>> Action: Originate >>> ActionId: 1234567W001-125 >>> Context: test >>> Exten: voicetest >>> Priority: 1 >>> Channel: SIP/+441632660987 at 31.13.156.183:5060 >>> Timeout: 60000 >>> Async: True >>> >>> Can anyone offer any insight into why this isn't working? >>> >>> Neil Youngman >>> >>> >> >> You didn't ANSWER() the call > > It's an outgoing call. I wouldn't expect to answer an outgoing call?I don't understand your goal. You want to send or receive fax? On our side, dialplan very simplified on incoming calls (receive fax): . in CLI> fax show settings ; output FAX For Asterisk Settings: blabla . Set(FAXOPT(faxdetect)=yes); or faxdetect=yes in sip.conf . Answer() ; if a fax is detected, go to fax extension . exten => fax,n,ReceiveFAX(${FAXPATHTOFILE}/${FAXFILE},fs) and done. -- Daniel
On 11/01/2019 10:08, Administrator TOOTAI wrote:> I don't understand your goal. You want to send or receive fax?I'm attempting to deliver a voice message. If the message has been mistakenly sent to a fax I want to detect that it's a fax and report that. Neil Youngman Neil Youngman Developer Wirefast Limited Wirefast provides secure corporate messaging services. See our messaging solutions at http://www.wirefast.com/ Please consider the environment. Does this email or attachment need to be printed? This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this email. Please notify the sender immediately by email if you have received this email by mistake and delete this email from your system. Any views or opinions are solely those of the author and do not necessarily represent those of Wirefast Limited Email transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of email transmission. Wirefast Limited is registered in England & Wales Company number: 03865860 Registered Office: 7/10 Chandos Street, Cavendish Square, London, W1G 9DQ Wirefast definitions of classification can be found here: www.wirefast.com/classifications
锘縊n 11/01/2019 10:04, Floimair Florian wrote:> I would guess from your explanation that the "outgoing" call somehow ends up in your Asterisk machine again, either at the voicetest or fax extension. > You don't answer it in either of the extensions. > That's what TOOTAI meant.No, it's not looped back to the same asterisk extension. For this particular test I'm testing against a hardware fax machine plugged into a standard phone line.> If this is done in another extension, than this part of the Dialplan is missing in your post. So we can only guess what's going on. > Either post the full dialplan or add some log or cli output (with verbose set to at least 1) so we can have a chance of seeing what's going on.I attach some CLI output. Neil Neil Youngman Developer Wirefast Limited Wirefast provides secure corporate messaging services. See our messaging solutions at http://www.wirefast.com/ Please consider the environment. Does this email or attachment need to be printed? This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this email. Please notify the sender immediately by email if you have received this email by mistake and delete this email from your system. Any views or opinions are solely those of the author and do not necessarily represent those of Wirefast Limited Email transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of email transmission. Wirefast Limited is registered in England & Wales Company number: 03865860 Registered Office: 7/10 Chandos Street, Cavendish Square, London, W1G 9DQ Wirefast definitions of classification can be found here: www.wirefast.com/classifications -------------- next part -------------- [Kswasp6*CLI> [0K[1;30m == Using SIP RTP CoS mark 5 [Kswasp6*CLI> [0K[1;30m -- Called +441632900987 at 10.11.12.13:5060 [Kswasp6*CLI> [0K[1;30m -- SIP/10.11.12.13:5060-000000f8 is making progress [Kswasp6*CLI> [0K[1;30m -- SIP/10.11.12.13:5060-000000f8 answered [Kswasp6*CLI> [0K[1;30m -- Executing [voicetest at test:1] [1;36mNoOp("[1;35mSIP/10.11.12.13:5060-000000f8", "[1;35m") in new stack [Kswasp6*CLI> [0K[1;30m -- Executing [voicetest at test:2] [1;36mLog("[1;35mSIP/10.11.12.13:5060-000000f8", "[1;35mNotice,SIP/10.11.12.13:5060-000000f8: Extension voiceout starting") in new stack [Kswasp6*CLI> [0K[Jan 11 10:36:35] [1;33mNOTICE[9709][C-00000117]: [1;37mExt. voicetest:[1;37m2 [1;37m@ test: SIP/10.11.12.13:5060-000000f8: Extension voiceout starting [1;30m -- Executing [voicetest at test:3] [1;36mLog("[1;35mSIP/10.11.12.13:5060-000000f8", "[1;35mNotice,SIP/10.11.12.13:5060-000000f8: Starting Answer Machine Detection") in new stack [Jan 11 10:36:35] [1;33mNOTICE[9709][C-00000117]: [1;37mExt. voicetest:[1;37m3 [1;37m@ test: SIP/10.11.12.13:5060-000000f8: Starting Answer Machine Detection [1;30m -- Executing [voicetest at test:4] [1;36mAMD("[1;35mSIP/10.11.12.13:5060-000000f8", "[1;35m") in new stack [1;30m -- AMD: SIP/10.11.12.13:5060-000000f8 (N/A) (N/A) (Fmt: alaw) [1;30m -- AMD: initialSilence [2500] greeting [1500] afterGreetingSilence [800] totalAnalysisTime [5000] minimumWordLength [100] betweenWordsSilence [50] maximumNumberOfWords [3] silenceThreshold [256] maximumWordLength [5000] [Kswasp6*CLI> [0K[1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Changed state to STATE_IN_SILENCE [Kswasp6*CLI> [0K[1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Word detected. iWordsCount:1 [1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Detected Talk, previous silence duration: 1980 [Kswasp6*CLI> [0K[1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Changed state to STATE_IN_SILENCE [Kswasp6*CLI> [0K[1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Detected Talk, previous silence duration: 100 [Kswasp6*CLI> [0K[1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Word detected. iWordsCount:2 [Kswasp6*CLI> [0K[1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Changed state to STATE_IN_SILENCE [Kswasp6*CLI> [0K[1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Detected Talk, previous silence duration: 100 [Kswasp6*CLI> [0K[1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. Word detected. iWordsCount:3 [1;30m -- AMD: Channel [SIP/10.11.12.13:5060-000000f8]. ANSWERING MACHINE: iWordsCount:3 [Kswasp6*CLI> [0K[1;30m -- Executing [voicetest at test:5] [1;36mLog("[1;35mSIP/10.11.12.13:5060-000000f8", "[1;35mNotice,SIP/10.11.12.13:5060-000000f8: Answer Machine Detection MACHINE/MAXWORDS-3-3") in new stack [Kswasp6*CLI> [0K[Jan 11 10:36:38] [1;33mNOTICE[9709][C-00000117]: [1;37mExt. voicetest:[1;37m5 [1;37m@ test: SIP/10.11.12.13:5060-000000f8: Answer Machine Detection MACHINE/MAXWORDS-3-3 [1;30m -- Executing [voicetest at test:6] [1;36mPlayback("[1;35mSIP/10.11.12.13:5060-000000f8", "[1;35m/var/lib/asterisk/sounds/en/demo-congrats") in new stack [Kswasp6*CLI> [0K[1;30m -- <SIP/10.11.12.13:5060-000000f8> Playing '/var/lib/asterisk/sounds/en/demo-congrats.gsm' (language 'en') [Kswasp6*CLI> [0K[1;30m -- Executing [voicetest at test:7] [1;36mLog("[1;35mSIP/10.11.12.13:5060-000000f8", "[1;35mNotice,SIP/10.11.12.13:5060-000000f8: Voice out extension complete") in new stack [Kswasp6*CLI> [0K[Jan 11 10:37:09] [1;33mNOTICE[9709][C-00000117]: [1;37mExt. voicetest:[1;37m7 [1;37m@ test: SIP/10.11.12.13:5060-000000f8: Voice out extension complete [1;30m -- Executing [voicetest at test:8] [1;36mHangup("[1;35mSIP/10.11.12.13:5060-000000f8", "[1;35m") in new stack [1;30m == Spawn extension (test, voicetest, 8) exited non-zero on 'SIP/10.11.12.13:5060-000000f8' [Kswasp6*CLI> exit Asterisk cleanly ending (0). Executing last minute cleanups kroot at swasp6:~\[root at swasp6 ~]# logout Connection to 127.0.0.1 closed. kneily at swasp6:~\neily at swasp6 ~ 10:37:30 919 $ exit