⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 efax.1

📁 使用efax的fax工具程序
💻 1
📖 第 1 页 / 共 3 页
字号:
rings.  The example below will make the modem answer incomingcalls in fax mode on the fourth ring and save the received faxesusing files names corresponding to the reception date and time..RS.nf.ft CWefax -d /dev/ttyb -or -i"+FCLASS=2;+FCR=1" \\   -iS0=4 -w -r "" 2>&1 >> fax.in.log.ft P.fi.RE.B Sharing the modem with outgoing callsThe modem device can be shared by programs that use the UUCPdevice locking protocol (kermit, uucico, efax, cu, etc.).efax will lock the modem device before opening it if one or moreUUCP lock file names are given with \fB-x\fP options.  The lockfile names are typically \fR/usr/spool/uucp/LCK..\fP\fIdev\fPwhere \fIdev\fP is the name of the device file in the /devdirectory that is to be locked.If the \fB-s\fP (share) option is used, the lock file is removedwhile waiting for incoming calls so other programs can use thesame device.If efax detects another program using the modem while it iswaiting to receive a fax, efax exits with a termination code of1.  A subsequent efax process using this device will wait untilthe other program is finished before re-initializing the modemand starting to wait for incoming calls again.Programs that try to lock the modem device by using devicelocking facilities other than UUCP lock files not be able to usethis arbitration mechanism because the device will still be opento the efax process.  In this case you will need to kill the efaxprocess (e.g. "fax stop") before starting the other program..B Accepting both fax and data callsMany modems have an adaptive data/fax answer mode that can beenabled using the \fB-i+FAE=1\fP (for Class 1) or \fB-i+FAA=1\fP(for Class 2) initialization string.  The type of call (data orfax) can then be deduced from the modem's responses.Some modems have limited adaptive answer features (e.g. onlyworking properly at certain baud rates or only in Class 2) ornone at all.  In this case use the initialization string\fB-i+FCLASS=0\fP to answer in data mode first and the \fB-oa\fPoption to then hang up and try again in fax mode if the firstanswer attempt was not successful.  This method only works ifyour telephone system waits a few seconds after you hang upbefore disconnecting incoming calls.If the \fB-g\fP option is used, the option's argument will be runas a shell command when an incoming data call is detected.Typically this command will exec \fBgetty\fP(8).  This programshould expect to find the modem already off-hook and a lock filepresent so it should not try to hang up the line or create a lockfile.  Note that the modem should be set up to report the DCE-DTE(modem-computer, e.g. CONNECT 38400) speed, not the DCE-DCE(modem-modem, e.g. CONNECT 14400) speed.  For many modems theinitialization option -iW0 will set this.The following command will make efax answer incoming calls on\fB/dev/cua1\fP on the second ring.  This device will be lockedusing two different lock files but these lock files will beremoved while waiting for incoming calls (\fB-s\fP).  If a datacall is detected, the \fBgetty\fP program will be run toinitialize the terminal driver and start a \fBlogin\fP(1)process.  Received fax files will be stored using names like\fBDec02-12.32.33.001\fP, in the \fB/usr/spool/fax/incoming\fPdirectory and the log file will be appended to\fB/usr/spool/fax/faxlog.cua1\fP..RS.nf.ft CWefax -d /dev/cua1 -or \\   -i '+FCLASS=2;+FCR=1;+FAA=1' \\   -x /usr/spool/uucp/LCK..cua1 \\   -x /usr/spool/uucp/LCK..ttyS1 \\   -g "exec /sbin/getty -h /dev/cua1 %d" \\   -iS0=2 -w -s \\   -r "/usr/spool/fax/incoming/%b%d-%H.%I.%S" \\   >> /usr/spool/fax/faxlog.cua1 2>&1.ft P.fi.RENote that adaptive answer of either type will not work for allcallers.  For some data calls the duration of the initialdata-mode answer may be too short for the initial handshaking tocomplete.  In other cases this duration may be so long thatincoming fax calls will time out before efax switches to faxmode.  In addition, some calling fax modems mistake data-modeanswering tones for a fax answer (CED) tone and initiate faxnegotiation too soon.  If you use software adaptive answer youcan reduce the value of the initial data-mode answer (set byTO_DATAF in efax.c) to get more reliable fax handshaking orincrease it for more reliable data handshaking.  However, if youneed to provide reliable fax and data service to all callers youshould use separate phone numbers for the two types of calls..SH USING INIT TO RUN EFAXefax can answer all incoming calls if you place an entry for efaxin \fB/etc/inittab\fP (for SysV-like systems) or\fB/etc/ttytab\fP (for BSD-like systems). The \fBinit\fP(8)process will run a new copy of efax when the system boots up andwhenever the previous process terminates.  The inittab or ttytabentry should invoke efax by running the \fBfax\fP script with an\fBanswer\fP argument.For example, placing the following line in \fB/etc/inittab\fP(and running "kill -1 1") will make init run the \fBfax\fP scriptwith argument \fBanswer\fP every time previous process terminates(and \fBinit\fP is in runlevel 4 or 5)..RS.nf.ft CWs1:45:respawn:/bin/sh /usr/bin/fax SPKR=-iM0 answer.ft P.fi.REFor BSD-like systems, a line such as the following in\fB/etc/ttytab\fP will have the same effect:.RS.nf.ft CWttya "/usr/local/bin/fax answer" unknown off.ft P.fi.REIn these cases the fax script should be protected againsttampering since init will execute it as a privileged (root)process.  If you will also be allowing data calls via getty andlogin you should ensure that your system is reasonably secure(e.g. that all user id's have secure passwords)..SH RESOLVING PROBLEMSDouble check the configuration setup in the fax script.Run the "fax test" script to check the modem's responses tovarious commands.  The results will be displayed at the end ofthe test.  Some ERROR responses from the modem should be expectedsince most modems don't implement all the possible commands.If efax hangs when trying to open the modem device (typicallyttyX), the device is either already in use by another process(e.g. getty) or it requires the carrier detect line to be truebefore it can be opened.  Many systems define an alternate devicename for the same physical device (typically cuaX) that can beopened even if carrier is not present or other programs arealready using it.If modem responses are being lost or generated at random, anotherprocesses (e.g. getty) may be trying to use the same device atthe same time.  Using lock files (-x options) can sometimesresolve this problem.Check the response to the "AT+FCLASS=?" command to make sure yourmodem supports the Class (1 or 2) that you have selected.  If youhave a Class 1 modem, check the response to the "AT+FRM=?"command to verify the speeds supported (e.g. a response of"24,48" would mean only 2400 and 4800 bps are supported).  ForClass 2 modems check the response to the "AT+FDCC=?" command tomake sure the modem supports the capabilities you have selected(see CAPABILITIES above).Attempt to send a fax. Check that the modem starts making CNGtones (a 0.5 second tone every 3 seconds) as soon as it'sfinished dialing.  This shows the modem is in fax mode.  You mayneed to change the SPKR string in the fax script to -iM2L3 tomonitor the phone line.Listen to the answering fax machine and check that it sends a 3second beep (CED) followed by a "warbling" sound (DIS frames)every 3 seconds.  If you hear a continuous signal instead (tonesor noise), then you've connected to a data modem instead.Your modem should now send back another warble (DCS frame)followed by 1.5 seconds of noise (training check data).  Ifeverything is OK, the receiving end will send another warble (CFRframe) and your modem will start to send data.  Check the modem'sLEDs.  If flow control is working properly, the modem's send data(SD) LED will turn off periodically while the fax data is sent.When the transmission completes, check the message showing theline count and the average bit rate.Low line counts (under 1000 for a letter size image) or thewarning "fax output buffer overflow" indicate that the imageformat is probably incorrect. Possibly the bit order is reversed.If the average bit rate is much higher than the negotiated bitrate (e.g. 14000 bps for a 9600bps connection) then flow controlwas not active.  This usually results in a garbled transmissionand the receiving machine may reject the page, abort the call,print a distorted or blank image and/or hang up.Most modems enable XON/XOFF flow control when fax mode isenabled.  Check the output of the fax test command for the flowcontrol settings in fax mode (typically &K4 or \\Q1).  If theyare incorrect you can use additional -i commands to enable flowcontrol after the +FCLASS= command.An <XOFF> message appearing during the transmission means thatthe operating system was ignoring the modem's XON/XOFFcharacters.  This could be caused by bugs in the serial driver(some Linux 1.1 kernels before 1.1.42).  In this case use thestty command to check the definitions of the start and stopcontrol characters and to check if xon/xoff flow control isenabled.  You can use stty to set up the port manually (stty stop^S start ^Q ixon </dev/XXX) before starting efax if necessary.Check that the remote machine confirms reception with a +FTPS:1response (Class 2) or an MCF frame (Class 1).For Class 2 modems, the error message "abnormal call termination(code \fInn\fP)" indicates that the modem detected an error andhung up.  The modem's manual may give an explanation for theerror number \fInn\fP.Many companies advertise services that will fax back informationon their products.  These can be useful for testing faxreception.If efax should display the message "can't happen (<details>)"please send a bug report to the author.Finally, don't play "option bingo," if you can't resolve theproblem save the output of the \fBfax test\fP command to a file(e.g. \fBfax test >test.out\fP) and send it along with a verbose(\fBVERB="-v chewmainr"\fP) log of the failed session to theaddress below.  You may also want to use the mailing listdescribed below..SH MAILING LISTA mailing list has been set up to support users of efax andrelated software.  To subscribe, send e-mail toefax-request@renaissoft.com with the word "subscribe" in thesubject field.  After subscribing you can post to the mailinglist by sending your post to efax@renaissoft.com..SH RELATED SOFTWAREFor Linux SystemsAn independent package, Qfax, uses efax to provide fax servicesfor multiuser Linux systems through a mail-to-fax gateway.  It isavailable by anonymous ftp from sunsite.unc.edu as/pub/Linux/apps/comm/fax/qfax1.0.tar.gz.  Another program, g3vga,can be used to provide fax preview with VGA displays. Alsoavailable from sunsite.unc.edu.For Amiga SystemsA port of efax for the Amiga is available as a component of ashareware voice mail package, AVM, distributed by Al Villarica(rvillari@cat.syr.edu)..SH AUTHOREfax was written by Ed Casas.  Please send comments or bugreports to edc@cce.com.  Please mention the operating system, thetype of the modem used and include a copy of any relevant sessionlogs..SH ACKNOWLEDGEMENTSMany people have helped with the development of efax by providingencouragement, suggestions, bug reports and fixes, by doingpre-release testing and by developing related software.A very incomplete list includes: John Conover, Mitchum DSouza, Bradley Dale, Debbe Gervin, Jamie Honan, Michael Huehne,Lester Ingber, Sarantos Kapidakis,Al Knudson, Ken Land,Ulrich Lauther, Robert J. LeBlanc,Norm Matloff, Mark Montague, Jose' M. Piquer, Markus Regnet, Adam J. Richter, Lal Sanjay,Bogdan Urma,Derek Lee,and Al Villarica..SH COPYRIGHTefax is copyright 1993, 1994, 1995 Ed Casas.  It may be used,copied and modified under the terms of the GNU Public License..SH DISCLAIMERAlthough \fBefax\fP has been tested it may have errors that willprevent it from working correctly on your system.  Some of theseerrors may cause serious problems including loss of data andinterruptions to telephone service..SH REFERENCESDennis Bodson et. al., "FAX: Digital Facsimile Technology andApplications", Second Edition. Artech House, Boston. 1992.CCITT Recommendation T.4, "Standardization of Group 3 FacsimileApparatus for Document Transmission". 1988.CCITT Recommendation T.30, "Procedures for Document FacsimileTransmission in the General Switched Telephone Network". 1988The above CCITT (now ITU-T) standards can be downloaded fromgopher://info.itu.ch.Documentation on Class 1 and Class 2 fax commands as implementedby Rockwell are available fromhttp://www.tokyo.rockwell.com/ref/reference.html.The pbm utilities can be obtained by ftp from wuarchive.wustl.eduin /graphics/graphics/packages/NetPBM/netpbm-1mar1994.tar.gz.Ghostscript can be obtained from any GNU archive site..SH SEE ALSO.BR fax(1),.BR efix(1),.BR pbm(5),.BR g3topbm(1),.BR ghostscript(1),.BR init(8), .BR inittab(5), .BR ttytab(5), .BR printf(3),.BR strftime(3)..SH  BUGSClass 1 operation may fail if the program can't respond within 55milliseconds.May fail if multitasking delays cause the received data tooverflow the computer's serial device buffer or if an under-runof transmit data exceeds 5 seconds.Does not handle documents with pages of mixed formats or 2-Dcoding.  Does not do ECM, BFT, or polling and ignores procedureinterrupts.Can't read or write TIFF-F files.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -