Re: Unix equivalent of Dos commands

From: Bill Campbell (bill_at_celestial.com)
Date: 06/25/03


Date: Wed, 25 Jun 2003 18:43:31 GMT
To: Sco Mailing List <scomsc@xenitec.on.ca>

On Wed, Jun 25, 2003 at 12:19:51PM -0600, justin wrote:
>
>-snip-
>
>> Writing directly to a user's tty device may work, but probably won't on a
>> properly configured system since it has many security implications.
>
>I am just trying to write a string of data to an output only device
>connected via a serial port.
...
>However, since this is just a customer display for a cash register, I don't
>think there is anything to worry about. ;)

Writing to a serial port compilicates things a bit since one has
to insure that it's parameters are set correctly (e.g. baud rate,
parity, etc.) -- something like:

        stty 9600 cs8 -onlcr clocal < /dev/tty1a

The stty command allows you to set how the end-of-line stuff is
handled as well, and can be used to automatically supply CRLF.

Bill

--
INTERNET:   bill@Celestial.COM  Bill Campbell; Celestial Software LLC
UUCP:               camco!bill  PO Box 820; 6641 E. Mercer Way
FAX:            (206) 232-9186  Mercer Island, WA 98040-0820; (206) 236-1676
URL: http://www.celestial.com/
Government is actually the worst failure of civilized man. There has
never been a really good one, and even those that are most tolerable
are arbitrary, cruel, grasping and unintelligent.
        -- H. L. Mencken


Relevant Pages

  • Re: Interesting problem with Serial Port
    ... >no data is waiting to be read on a file associated with a tty device ... So it would seem that the radio receiver is not sending data. ... I then hooked up the serial port of the NetBSD device to the serial ...
    (comp.unix.programmer)
  • Re: Unix equivalent of Dos commands
    ... >> Writing directly to a user's tty device may work, ... >> properly configured system since it has many security implications. ... >>(how would you like to be running as root and have your F1 key ... This is why even on SCO systems I change root's home directory ...
    (comp.unix.sco.misc)