help wrt UUCP between 3B1 OBM and TB

Chris Lewis clewis at ferret.ocunix.on.ca
Mon May 6 13:59:54 AEST 1991


In article <1991May4.210605.28387 at sceard.Sceard.COM> mrm at Sceard.COM (M.R.Murphy) writes:
>[Friend has difficulty between 3B1's OBM and trailblazers]

This C program, in addition to setting the line to tone dial (mine won't
thru "normal" channels for some reason, sets PIOCOVSPD on the modem which
permits it to talk to trailblazers.

#! /bin/sh
# This is a shell archive.  Remove anything before this line, then feed it
# into a shell via "sh file" or similar.  To overwrite existing files,
# type "sh file -c".
# The tool that generated this appeared in the comp.sources.unix newsgroup;
# send mail to comp-sources-unix at uunet.uu.net if you want that tool.
# Contents:  phfix.c
# Wrapped by clewis at ecicrl on Mon May  6 00:57:58 1991
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
echo If this archive is complete, you will see the following message:
echo '          "shar: End of archive 1 (of 1)."'
if test -f 'phfix.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'phfix.c'\"
else
  echo shar: Extracting \"'phfix.c'\" \(1136 characters\)
  sed "s/^X//" >'phfix.c' <<'END_OF_FILE'
X/*	Sample program for bashing the OBM into tone dial and
X	setting PIOCOVSPD to permit talking to certain modems
X	(particularly telebits).
X	The documentation mentions 2.3% speed change for PIOCOVSPD.
X	That's all I know.
X
X	You are free to do whatever you wish with this code, but
X	please leave this comment in.
X
X	Chris Lewis, clewis at ecicrl.uucp, Jan 2 1991.
X */
X#include <stdio.h>
X#include <fcntl.h>
X#include <sys/phone.h>
X
Xmain(argc, argv)
Xint argc; char **argv; {
X    int f;
X    struct updata upd;
X    f = open("/dev/ph1", O_RDWR | O_NDELAY, 0);
X    if (f < 0) {
X	perror("/dev/ph1");
X	exit(1);
X    }
X    ioctl(f, PIOCGETP, &upd);	/* retrieve Phone parameters */
X    upd.c_lineparam &= ~PULSE;	/* reverse the sense to set to pulse dial */
X    upd.c_lineparam |= DTMF;	/* reverse the sense to set to pulse dial */
X
X#ifdef	NEVER
X    upd.c_feedback |= SPEAKERON;
X    upd.c_feedback |= LOUDSPK;
X    ioctl(f, PIOCDISC, &upd);	/* apply PIOCOVSPD for talking to some modems*/
X#endif
X
X    ioctl(f, PIOCOVSPD, &upd);	/* apply PIOCOVSPD for talking to some modems,
X				   eg: Telebits */
X    ioctl(f, PIOCSETP, &upd);	/* set phone parameters */
X}
END_OF_FILE
  if test 1136 -ne `wc -c <'phfix.c'`; then
    echo shar: \"'phfix.c'\" unpacked with wrong size!
  fi
  # end of 'phfix.c'
fi
echo shar: End of archive 1 \(of 1\).
cp /dev/null ark1isdone
MISSING=""
for I in 1 ; do
    if test ! -f ark${I}isdone ; then
	MISSING="${MISSING} ${I}"
    fi
done
if test "${MISSING}" = "" ; then
    echo You have the archive.
    rm -f ark[1-9]isdone
else
    echo You still must unpack the following archives:
    echo "        " ${MISSING}
fi
exit 0
-- 
Chris Lewis, Phone: (613) 832-0541, Domain: clewis at ferret.ocunix.on.ca
UUCP: ...!cunews!latour!ecicrl!clewis; Ferret Mailing List:
ferret-request at eci386; Psroff (not Adobe Transcript) enquiries:
psroff-request at eci386 or Canada 416-832-0541.  Psroff 3.0 in c.s.u soon!



More information about the Comp.sys.3b1 mailing list