[fpc-pascal] x86.pp and oldlinux.pp
Holger Bruns
holger.bruns at gmx.net
Wed Nov 4 09:23:54 CET 2009
Gustavo Enrique Jimenez schrieb:
>
> Accessing serial ports in linux could be as simple as to write/read
> to/from /dev/ttySx . You don't need io ports. For a multiplatform
> solution, use synapsis/synaser.
>
Sometimes it is useful to get more information about device drivers.
Searching the internet for that information is pretty difficult, because
there is no detailed description available, as far as I see. The first
hit on google points to a website for "device detectives". If I intend
to use device drivers, I need to know how to access the ports of a
device, which means in my case to a serial port based on the 16550D
Universal Asynchronous Receiver/Transmiter with FIFOs. I need to read
and write every register of that UART as explained in the National
Semiconductor databook, register by register, address by address. No
information on that topic seems to be available, but a whole bunch of
useless idle talk and advertisement.
Hence I cannot use /dev/ttySx for accessing serial devices.
The only way to use serial ports successfully to me, is to use the unit
serial on fpc, if I choose fpc to deal with serial ports. Another
problem results from misleading comments on the implemented procedures
and functions. As explained, seropen would return a zero, if a device
cannot be found. For real, seropen returns a zero, if this device is
found, and -1, if not.
Under the bottom line, it is embarrassing time consuming for a newbie
like me, to work successfully with serial ports on linux.
> ps: Excuse my english. Helping you is very hard: you don't listen.
>
On a mailing list, I can only read and write. ;-)
Best regards, Holger
More information about the fpc-pascal
mailing list