Port Access

Scott Amspoker scott at bbxsda.UUCP
Thu Jan 4 03:41:45 AEST 1990


In article <12720 at cbnews.ATT.COM> knt at cbnews.ATT.COM (kirk.n.trost,59473,cb,1k238,614 860 4225) writes:
>
>Is there an easy way to access 386 ports using C 
>under UNIX.
>
>For example:
>
>     x = input (portno)
>         output (portno, value)

I would be very surprised if UNIX system allowed a user process to access
ports directly.  If you are writing a driver or kernal routine in C,
procedures like the ones in your example could be used.  Turbo C,
for example, will generate in-line code for inport() and outport()
calls.  However, there is no standard here.  You may write your own
in assembler or see if your C library already has them.


-- 
Scott Amspoker
Basis International, Albuquerque, NM
(505) 345-5232
unmvax.cs.unm.edu!bbx!bbxsda!scott



More information about the Comp.lang.c mailing list