Dealing with Unix character devices?
ned konz
ned at bike-nomad.com
Sat Aug 30 04:07:12 UTC 2003
Aaron J Reichow wrote:
> Ahoy!
>
> I'm rather new to dealing with Unix serial/character devices in Squeak.
> Anyone have any tips to impart? Can I just approach grabbing data via a
> /dev/* file with a regular FileStream, or do I need a) OSProcess or b)
> something else?
>
> All I'm interested in is reading from the device, I don't need to write to
> it. The specific device is /dev/ttyS0, the physical device is the IR
> port, and the purpose of this is to read codes from the IrDA keyboard I
> have. The Qtopia driver doesn't seem to interact well with the Squeak VM,
> so I thought I'd try my hand at writing a driver that has no underlying
> dependencies beyond some serial access.
John McIntosh has done a ground-up version of a Serial Plugin for Unix. However,
it needs to be made to work with Linux (he was concentrating on MacOS/X).
I have started that work, but don't know when I'll get to the rest of it.
The work is simple, and (I think) would be best done by taking a number of
manifest constants that are derived from the termios.h header file and putting
them back into C so we don't have to copy the header into individual methods in
Squeak for every platform.
Also, the API differences will have to be dealt with.
More information about the Squeak-dev
mailing list
|