Hi, Do you have any example showing how to use SendFAX ? I can see several examples of ReceiveFAX but not a single one showing SendFAX. Regards -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20081127/b41ca08b/attachment.htm
On Thu, Nov 27, 2008 at 1:03 PM, Olivier <oza-4h07 at myamail.com> wrote:> Hi, > > Do you have any example showing how to use SendFAX ? > I can see several examples of ReceiveFAX but not a single one showing > SendFAX.This is not from 1.6, but rather from callweaver attached to Asterisk 1.4. When i'll finally switch to 1.6, i intend to just move those contexts to Asterisk dialplan. extensions.conf: [fax_out] exten => _X.,1,NoOp(--- sending fax to ${EXTEN} ---) exten => _X.,n,SipDTMFMode(inband) exten => _X.,n,TxFAX(${TIFF},caller,debug,ecm) exten => _X.,n,Hangup() exten => h,1,NoOp(--- done sending fax ---) exten => h,n,NoOp(TX: REMOTESTATIONID is ${REMOTESTATIONID}) exten => h,n,NoOp(TX: FAXPAGES is ${FAXPAGES}) exten => h,n,NoOp(TX: FAXRESOLUTION is ${FAXRESOLUTION}) exten => h,n,NoOp(TX: FAXBITRATE is ${FAXBITRATE}) exten => h,n,NoOp(TX: PHASEESTATUS is ${PHASEESTATUS}) exten => h,n,NoOp(TX: PHASEESTRING is ${PHASEESTRING}) exten => h,n,NoOp(TX: DIALSTATUS is ${DIALSTATUS}) exten => h,n,System(${SCRIPT}/fax_out_end.php --status ${uniqueid_storage} --pages ${FAXPAGES} --resolution ${FAXRESOLUTION} --bitrate ${FAXBITRATE} --phase exten => failed,1,NoOp(--- failed sending fax ---) Then, to send a fax, generate tiff file and call-file. Snapshot of my PHP generating call-file from hylafax job: $channel = 'SIP/'.$job['number'].'@asterisk-t38'; $destination array('context'=>'fax_out','extension'=>$job['number'],'priority'=>'1'); $vars = array( 'LOCALSTATIONID' => 'CallWeaver-T38-TxFax', 'T38CALL'=>'1', 'TIFF'=>$job['private']['tiff_file'], ); $callerid = 'CallWeaver T38 TxFax'; $waittime = 180; $deliver_time = NULL; $filename = NULL; $retries = array(); $callfile_dir = T38_CALLFILE_DIR.'/'; $result = ast_originate_callfile($channel,$destination,$vars,$callerid,$waittime,$deliver_time,$filename,$retries,$callfile_dir); Of course you'll need ast_originate_callfile which writes data to file and then moves to correct dir. I would publish that, but it's full of my constants and realted to much other libs.. Basically, you dial destination number (SIP/123 at privider) and send local side of channel to fax_out,${NUMBER},1 which does SendFax. Regards, Atis -- Atis Lezdins, VoIP Project Manager / Developer, IQ Labs Inc, atis at iq-labs.net Skype: atis.lezdins Cell Phone: +371 28806004 Cell Phone: +1 800 7300689 Work phone: +1 800 7502835
Thanks for this detailed reply. I was trying to test SendFAX, ReceiveFAX as first on my way to Hylafax with either iaxmodem or t38modem. Have you tried any of those 2 (iaxmodem or t38modem) ? Which one would you pick ? -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20081127/f9ccec98/attachment.htm
Olivier wrote:> Thanks for this detailed reply. > > I was trying to test SendFAX, ReceiveFAX as first on my way to Hylafax > with either iaxmodem or t38modem. > Have you tried any of those 2 (iaxmodem or t38modem) ? > Which one would you pick ?iaxmodem only does audio FAXing (for the present). t38modem only does T.38 FAXing. You pick the one you need. Steve
On Thu, Nov 27, 2008 at 4:39 PM, Olivier <oza-4h07 at myamail.com> wrote:> Thanks for this detailed reply. > > I was trying to test SendFAX, ReceiveFAX as first on my way to Hylafax with > either iaxmodem or t38modem. > Have you tried any of those 2 (iaxmodem or t38modem) ? > Which one would you pick ? >We had IAXmodem with Hylafax installation base, and we sent our faxes out trough PRI. Then we switched to pure SIP, but were unable to get T38modem to work with our provider. So, we wrote a wrapper for Hylafax that grabs processed tiff file from outgoing spool and generates call file for Callweaver (which sends trough Asterisk with T38 passtrough). So, if you have PRI ir analogue lines, use IAXmodem, otherwise you have to do either T38modem or SendFax. Regards, Atis -- Atis Lezdins, VoIP Project Manager / Developer, IQ Labs Inc, atis at iq-labs.net Skype: atis.lezdins Cell Phone: +371 28806004 Cell Phone: +1 800 7300689 Work phone: +1 800 7502835
On Thursday 27 November 2008 05:03:00 Olivier wrote:> Hi, > > Do you have any example showing how to use SendFAX ? > I can see several examples of ReceiveFAX but not a single one showing > SendFAX.i'm working on a script to incorporate e-mail <-> fax gatewaying with asterisk using programs that are already available in linux. there are simple examples here: http://messinet.com/viewvc/asterisk-fax-gw/trunk/ -- Anthony - http://messinet.com - http://messinet.com/~amessina/gallery 8F89 5E72 8DF0 BCF0 10BE 9967 92DC 35DC B001 4A4E -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 197 bytes Desc: This is a digitally signed message part. Url : http://lists.digium.com/pipermail/asterisk-users/attachments/20081128/b8a75dd1/attachment.pgp