News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

port programming

Started by anuradha, March 20, 2008, 03:11:00 AM

Previous topic - Next topic

anuradha

hi people
I'm trying to learn port programming.
I'm currently using interfacing-with-c-programming-real-world-applications it a  E-book.
but Its codes doesn't work properly.gives me strange errors.it users inportb() and outportb() to input and output
all I can come up with this problem is that User mode applications can not write or read directly to port.

so how can I do this??
why is this restrictions??
is their any good reference  on this???

thanks

Tedd

Yes, ports are protected in 'protected mode' (i.e. win32) - so you can't just write to any you choose. It would be a major security hazard to allow that: direct control over a device; for a disk this means you could bypass any filesystem protections/access-rights.

That said, there is a direct-i/o driver available that gives you port access from a protected-mode application. You'll have to search for it though :P
No snowflake in an avalanche feels responsible.