* Re: [9fans] Fax problem
@ 2001-05-31 21:06 Russ Cox
0 siblings, 0 replies; 6+ messages in thread
From: Russ Cox @ 2001-05-31 21:06 UTC (permalink / raw)
To: 9fans
try changing the line in /bin/fax that does
rx dinar /sys/lib/fax/faxgoose
to simply
/sys/lib/fax/faxgoose
and see if that clears things up.
you need a class 2 modem as well,
and those aren't the common ones.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [9fans] Fax problem
@ 2001-06-02 16:58 presotto
0 siblings, 0 replies; 6+ messages in thread
From: presotto @ 2001-06-02 16:58 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 496 bytes --]
I'm currently using:
# convert to g3
g3files=()
a=1
for(i in $infiles){
switch(`{file <$infiles(1)}){
case *:*g3* *:*fax*
g3files=($g3files $i)
case *:*postscript
gs -dSAFER '-sDEVICE=dfaxlow' '-sOUTPUTFILE='$tmp'.'$#a'.%03d' -dNOPAUSE -dQUIET $i quit.ps
g3files=($g3files $tmp.$#a.*)
case *
lp -dstdout $i > $tmpps
gs -dSAFER '-sDEVICE=dfaxlow' '-sOUTPUTFILE='$tmp'.'$#a'.%03d' -dNOPAUSE -dQUIET $tmpps quit.ps
g3files=($g3files $tmp.$#a.*)
}
a=($a $a)
}
[-- Attachment #2: Type: message/rfc822, Size: 2177 bytes --]
From: Richard Miller <miller@hamnavoe.demon.co.uk>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] Fax problem
Date: Sat, 2 Jun 2001 14:57:59 0100
Message-ID: <E156Bx3-000L0O-0K@tele-post-20.mail.demon.net>
If we're going to fix fax, we might as well also handle the general
case of faxing multiple files of different type. How about replacing
the switch(`{file $infiles(1)}) statement -- which only checks the type
of the first file -- with something like this:
# convert to g3
g3files=()
ntmp=1
for (infile in $infiles) {
otmp=$tmp.$ntmp
ntmp=`{echo $ntmp+1 | hoc}
switch(`{file <$infile}){
case *g3* *fax*
g3files=($g3files $infile)
case postscript
gs -dSAFER '-sDEVICE=dfaxlow' '-sOUTPUTFILE='$otmp.'.%03d' -dNOPAUSE -d QUIET $infile quit.ps
g3files=($g3files $otmp.*)
case *
lp -dstdout $infile > $tmpps
gs -dSAFER '-sDEVICE=dfaxlow' '-sOUTPUTFILE='$otmp'.%03d' -dNOPAUSE -dQUIET $tmpps quit.ps
g3files=($g3files $otmp.*)
}
}
-- Richard
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [9fans] Fax problem
@ 2001-06-02 13:57 Richard Miller
0 siblings, 0 replies; 6+ messages in thread
From: Richard Miller @ 2001-06-02 13:57 UTC (permalink / raw)
To: 9fans
If we're going to fix fax, we might as well also handle the general
case of faxing multiple files of different type. How about replacing
the switch(`{file $infiles(1)}) statement -- which only checks the type
of the first file -- with something like this:
# convert to g3
g3files=()
ntmp=1
for (infile in $infiles) {
otmp=$tmp.$ntmp
ntmp=`{echo $ntmp+1 | hoc}
switch(`{file <$infile}){
case *g3* *fax*
g3files=($g3files $infile)
case postscript
gs -dSAFER '-sDEVICE=dfaxlow' '-sOUTPUTFILE='$otmp.'.%03d' -dNOPAUSE -d QUIET $infile quit.ps
g3files=($g3files $otmp.*)
case *
lp -dstdout $infile > $tmpps
gs -dSAFER '-sDEVICE=dfaxlow' '-sOUTPUTFILE='$otmp'.%03d' -dNOPAUSE -dQUIET $tmpps quit.ps
g3files=($g3files $otmp.*)
}
}
-- Richard
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [9fans] Fax problem
@ 2001-06-01 13:09 Richard Miller
0 siblings, 0 replies; 6+ messages in thread
From: Richard Miller @ 2001-06-01 13:09 UTC (permalink / raw)
To: 9fans
There's a cute bug in /bin/fax, where it checks the input file type
to see if postscript or text files need converting to g3 fax format:
# convert to g3
switch(`{file $infiles(1)}){
case *g3* *fax*
g3files=$infiles
case postscript
gs -dSAFER '-sDEVICE=dfaxlow' ...
g3files=($tmp.*)
case *
lp -dstdout $infiles > $tmpps
gs -dSAFER '-sDEVICE=dfaxlow' ...
g3files=($tmp.*)
}
Because file(1) echoes the filename, the first case will be selected
erroneously for a text or postscript file whose name contains 'fax' -
and in particular when faxing from standard input, because stdin gets
copied to a temp file called /tmp/fax.in.$pid .
Simple correction: change the switch command to
switch(`{file <$infiles(1)}){
-- Richard Miller
^ permalink raw reply [flat|nested] 6+ messages in thread
* [9fans] Fax problem
@ 2001-05-31 22:43 William Staniewicz
0 siblings, 0 replies; 6+ messages in thread
From: William Staniewicz @ 2001-05-31 22:43 UTC (permalink / raw)
To: 9fans
I never tried faxing before. But when I did try it
recently I got this...
term% fax 5551212 Someone faxtest.txt
rx: can't dial dinar: cs: can't translate address(tcp!dinar!shell)
(note: prior to this I did "telco '#t/eia1' as I normally
do to set up that feature.)
What do I do next to set it up to work?
--
Bill William Staniewicz
Amsterdam, NL
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [9fans] Fax problem
@ 2001-05-31 21:07 presotto
0 siblings, 0 replies; 6+ messages in thread
From: presotto @ 2001-05-31 21:07 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 1244 bytes --]
Oops, that's local configuration that we shouldn't have let slip out.
The directory /sys/lib/fax and the command /rc/bin/fax are full of
local refrences.
This needs a manual. The machine that has the modem attached should
be running a telco with the appropriate dev in the command line. For
example, out system dinar has the following in it's cpurc:
telco -vs 19200 /dev/eia011 & # FAX
Then you should have a cron entry that kicks it ever now and then
just like for mail. For example, we have in /cron/upas/cron:
5,15,25,35,45,55 * * * * dinar /sys/lib/fax/faxtickle
Now edit /rc/bin/fax and everything in /sys/lib/fax to reflect
your local environment. Basicly change everything that mentions
emelie into a pointer to your file server.
If you only have one system, then just remove from /rc/bin/fax the
line:
rx dinar /sys/lib/fax/faxgoose
with
upas/runq -t3 /mail/faxoutqueue /sys/lib/fax/faxtry < /dev/null > /dev/null >[2=1] &
A bit of a pain all around. We never got around to making this generic and
it fell through the cracks in the release. This is part of why releases are
hard. We (i.e. Rob) usually have to go over the system with a fine tooth
comb to comb out all this local lice.
[-- Attachment #2: Type: message/rfc822, Size: 1959 bytes --]
From: William Staniewicz <wstan@localhostnl.demon.nl>
To: 9fans@cse.psu.edu
Subject: [9fans] Fax problem
Date: Thu, 31 May 2001 22:43:53 +0000
Message-ID: <20010531224353.B389@localhostnl.demon.nl>
I never tried faxing before. But when I did try it
recently I got this...
term% fax 5551212 Someone faxtest.txt
rx: can't dial dinar: cs: can't translate address(tcp!dinar!shell)
(note: prior to this I did "telco '#t/eia1' as I normally
do to set up that feature.)
What do I do next to set it up to work?
--
Bill William Staniewicz
Amsterdam, NL
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2001-06-02 16:58 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-05-31 21:06 [9fans] Fax problem Russ Cox
2001-05-31 21:07 presotto
2001-05-31 22:43 William Staniewicz
2001-06-01 13:09 Richard Miller
2001-06-02 13:57 Richard Miller
2001-06-02 16:58 presotto
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).