<span style="font-family:verdana,sans-serif">Hi,</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">We are using Asterisk V1.8.13.0, Spandsp FAX Driver: 20090502 044449. Unable to ReceiveFAX.</span><br style="font-family:verdana,sans-serif">
<br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">We are using res_fax.so and res_fax_spandsp.so</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">Following is the dialplan.</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">[for-fax]</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">exten => _XX.,1,Goto(example-faxin,s,1)</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">[example-faxin]</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">exten => s,1,Set(E_MAIL=${ODBC_BOLO_FAX_ACTIVE(${DID:2})})</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">;exten => s,n,GotoIf($[${ODBCROWS} < 1]?FAXNOTFOUND)</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">;exten => s,n,GotoIf(${ISNULL(${E_MAIL})}?SERVICENOTFOUND:)</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">exten => s,n,Set(LOCALHEADERINFO= fax termination -<a href="http://www.example.com">www.example.com</a>)</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">exten => s,n,Set(LOCALSTATIONINFO= FAX)</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">exten => s,n,Set(FAXFILE=/tmp/fax_test/${UNIQUEID}.tif)</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">exten => s,n,ReceiveFAX(${FAXFILE})</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">exten => s,n,Hangup()</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">exten => h,1,NoOp(receivefax completed and status ${FAXSTATUS})</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">exten => h,n,NoOp(RX: FAXERROR is ${FAXERROR})</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">exten => h,n,NoOp(RX: REMOTESTATIONID is ${REMOTESTATIONID})</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">exten => h,n,NoOp(RX: FAXPAGES is ${FAXPAGES})</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">exten => h,n,NoOp(RX: FAXRESOLUTION is ${FAXRESOLUTION})</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">exten => h,n,NoOp(RX: FAXBITRATE is ${FAXBITRATE})</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">exten => h,n,NoOp(RX: PHASEESTATUS is ${PHASEESTATUS})</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">exten => h,n,NoOp(RX: PHASESTRING is ${PHASEESTRING})</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">We got the constantly error :: "The call dropped prematurely".</span><br style="font-family:verdana,sans-serif">
<br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">We are not using T.38, we need to send and receive FAX on PSTN only.</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">I am very new to asterisk. Please suggest me to running FAX module without any problem. Let me know if more information required from my end.</span><br style="font-family:verdana,sans-serif">
<br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">Sometimes fax receive successfully but at the end it shows failure with same "The call drop prematurely" error and WARNING T.30 Page did not end cleanly.</span><br style="font-family:verdana,sans-serif">
<br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif"> -- Executing [s@example-faxin:4] Set("SIP/52987-00000000", "FAXFILE=/tmp/fax_test/1-1351164952.0.tif") in new stack</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif"> -- Executing [s@example-faxin:5] ReceiveFAX("SIP/52987-00000000", "/tmp/fax_test/1-1351164952.0.tif") in new stack</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif"> -- Channel 'SIP/52987-00000000' receiving FAX '/tmp/fax_test/1-1351164952.0.tif'</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">[Oct 25 17:06:34] WARNING[9880]: res_fax_spandsp.c:369 spandsp_log: WARNING T.30 Page did not end cleanly</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif"> == Spawn extension (example-faxin, s, 5) exited non-zero on 'SIP/52987-00000000'</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif"> -- Executing [h@example-faxin:1] NoOp("SIP/52987-00000000", "receivefax completed and status FAILED") in new stack</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif"> -- Executing [h@example-faxin:2] NoOp("SIP/52987-00000000", "RX: FAXERROR is The call dropped prematurely") in new stack</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif"> -- Executing [h@example-faxin:3] NoOp("SIP/52987-00000000", "RX: REMOTESTATIONID is 30584433 ") in new stack</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif"> -- Executing [h@example-faxin:4] NoOp("SIP/52987-00000000", "RX: FAXPAGES is 0") in new stack</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif"> -- Executing [h@example-faxin:5] NoOp("SIP/52987-00000000", "RX: FAXRESOLUTION is 8031x3850") in new stack</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif"> -- Executing [h@example-faxin:6] NoOp("SIP/52987-00000000", "RX: FAXBITRATE is 9600") in new stack</span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif"> -- Executing [h@example-faxin:7] NoOp("SIP/52987-00000000", "RX: PHASEESTATUS is ") in new stack</span><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif"> -- Executing [h@example-faxin:8] NoOp("SIP/52987-00000000", "RX: PHASESTRING is ") in new stack</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">-- </span><br style="font-family:verdana,sans-serif"><span style="font-family:verdana,sans-serif">Regards,</span><br style="font-family:verdana,sans-serif"><br style="font-family:verdana,sans-serif">
<span style="font-family:verdana,sans-serif">Chandrakant Solanki </span><br style="font-family:verdana,sans-serif">