[fpc-pascal] Linux serial interface
Johann Glaser
Johann.Glaser at gmx.at
Tue Dec 26 14:32:58 CET 2006
Hi!
Am Dienstag, den 26.12.2006, 15:38 +0100 schrieb Rainer Stratmann:
> Am Dienstag, 26. Dezember 2006 14:07 schrieb Michael Van Canneyt:
> > On Tue, 26 Dec 2006, Rainer Stratmann wrote:
> > > How to open correct the serial interface ('/dev/ttyS0')
> >
> > As far as I know, this is a terminal, so the terminal emulator will mess up
> > the IO. You should open the raw device.
>
> Isn't tty1 (without S) a terminal?
The ttySx devices also do a lot of terminal emulation stuff internally
(see e.g. stty(1) for how many things are possible, in your program you
have to do these with ioctl()).
Especially I have made the observation that flow control often is in
your way when you "just want to transmit data". Switch off flow control
completely (neither hardware nor software/XON/XOFF). Probably your
USB-serial converter has different default values for this and this is
why your program works with it.
Bye
Hansi
More information about the fpc-pascal
mailing list