Path: utzoo!utgpu!cunews!bnrgate!brtph3!brchh104!brchs1!bnr.ca!rice.edu!sun-spots-request From: number1!perl%step@uunet.uu.net (Robert Perlberg) Newsgroups: comp.sys.sun Subject: Re: Serial Port Programming for a SUN 3/80 Keywords: Miscellaneous Message-ID: <1672@brchh104.bnr.ca> Date: 18 Feb 91 18:43:00 GMT Sender: news@brchh104.bnr.ca Organization: Sun-Spots Lines: 16 Approved: Sun-Spots@rice.edu X-Original-Date: 8 Feb 91 20:42:04 GMT X-Refs: Original: v10n35 X-Sun-Spots-Digest: Volume 10, Issue 41, message 3 X-Note: Submissions: sun-spots@rice.edu, Admin: sun-spots-request@rice.edu You should look at the manual pages for stty(1), ioctl(2), and termio(4). Termio(4) will explain all about how to use the ioctl() function to set baud rate, parity, and a bunch of other parameters on tty ports. The stty command can be used to make these same settings from a shell prompt or within a shell script (or even with a C program using system(3), if you are so inclined, but ioctl is the preferred method). If you want to set the tty settings from within the lpr spooler, use the `ms' capability in the printcap. You pass it a set of arguments to be used with stty(1), e.g.: :ms=parenb -parodd cs7 -cstopb: Robert Perlberg Dean Witter Reynolds Inc., New York {murphy | philabs | chuo}!step!perl