windows port access

Chris Gonnerman chris.gonnerman at newcenturycomputers.net
Mon Jul 16 15:12:58 CEST 2001


----- Original Message -----
From: "Peter Hansen" <peter at engcorp.com>


> If you look back through the last two days' worth of postings for subject
> "parallel port?!?" you should find something to help.  Yes, it is
possible,
> no the result is not compatible (but you could always write a higher level
> wrapper to make it so).

Unfortunately what Bryan is asking is not what you are answering.  He wants
to access the I/O port 0x280, which he states is assigned to a "custom ISA
card" which (I assume) is not using the standard parallel port interface,
nor
serial, etc. and for which he evidently has no driver.

Under Linux, this can be done in C by following the instructions in the
"IO Port Programming mini-HOWTO" (check any Linux portal, i.e. linux.com,
for this document).  Doing it in Python using the first method given
(routines
in <asm/io.h>) would require writing a custom module in C.  The second
method
given (using /dev/port) is doable in a pure-Python implementation.

What Bryan hasn't told us is whether or not he needs interrupt support and
whether or not the interface protocol is time-sensitive; user-space access
to such a device is doomed to failure in most cases, and a kernel driver is
required instead.

Under Win32 I'm not sure what the procedure is, but I suspect a VxD file
will
be needed.

Bryan, please tell us a bit more about the device you are trying to control,
and perhaps we can help you.

> Bryan Brannigan wrote:
> >
> > I am looking for a way to send data to certain ports on a custom ISA
card.
> > The card is addressed as 280h.  Is this possible with Python?  Is the
code
> > compatible with Linux as well?
> >
> > Bryan
>
> --
> ----------------------
> Peter Hansen, P.Eng.
> peter at engcorp.com
> --
> http://mail.python.org/mailman/listinfo/python-list
>
>





More information about the Python-list mailing list