Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

Parallel Port I/O Access Under Win2K?

Cliff posted about 13 years ago | from the dealing-with-funky-access-permissions dept.

Microsoft 10

stumped-by-MS asks: "I'm having a tough time accessing my parallel port under Win 2K. I'm working off of a Dell Precision P4 workstation, and using Microsoft ASseMbler to run simple programs involving IN and OUT commands. Initially I read about 2K's strict I/O control, and found the PortTalk driver to get around it. This driver, when coupled with the supplied allowio.exe, is supposed to give any program User level 0 to any specified port. Using the program (syntax: allowio test.exe 0x378 ) allows access to the base address just fine, however with base+1 (0x379), the input port, is still unresponsive. Using allowio to specifically give access to that port also fails, as well as giving my program access to all ports, which I would rather not do in the first place. " Is there some hidden set of permissions a program must have before they are allowed access to certain I/O ports under Windows 2000?

"Am I missing some concept here? As I understand it, allowing access to base=0378H should give access beyond 0x380! If anyone knows what I am doing wrong, or the location of some software that does things right, it would help me a lot."

Sorry! There are no comments related to the filter you selected.

use a real OS. (-1, Troll)

Anonymous Coward | about 13 years ago | (#2431226)

DOS or linux will allow stuff like that rather nicely. windows is not built for it.

DLPortIO (4, Informative)

discoinferno (137207) | about 13 years ago | (#2431313)

Do a search for DLPortIO. (

It has all the answers to your question, and you would have run across it had you really done a search.

Hardware access is restricted. (4, Informative)

eric2hill (33085) | about 13 years ago | (#2432316)

On a Windows 2K/XP box, all hardware-level access is prohibited for user-space programs. Drivers are the only thing that are allowed to talk to hardware.

Go pick up a generic driver that you communicate with to do what you want. See the following...

There are many components available for Delphi (with source) to talk to hardware. Port to [insert language here] as necessary. Just remember to use standard calling conventions when calling the DLL.

You are posting this on Slashdot????? (1, Troll)

duffbeer703 (177751) | about 13 years ago | (#2433031)

Not only are you using Windows 2000, but you are also using the evil (tm) Pentium 4 chip....

What has Ask Slashdot stooped to now?

Re:You are posting this on Slashdot????? (0)

Anonymous Coward | about 13 years ago | (#2434898)

Be nice to those on the left side of the bell curve.

They may be slow, but they could catch up some day.

HeRvoPort (2, Informative)

roryi (84742) | about 13 years ago | (#2435395)

HeRvoPort ( ) does exactly what you need, and is available for Win NT3.1-4.0 on MIPS, Alpha an x86, and for Win2000 on both IA32 and IA64.

An earlier version provides the same control for OS/2

It was developed origingally by Dave Brucken, who came up with the originial FOSSIL (Fido/Opus/SeaDog Standard Interface Layer) serial spec for FidoNet, and it's since been expanded to manage all port access for Windows.

They used to sell a parallel break-out box, and a strange sort of music synth to go with it, but i think that's fallen by the wayside. cool stuff, anyhow.

Re:HeRvoPort (0)

Anonymous Coward | about 13 years ago | (#2436231)

what's up with that website? it only works two out of every three (or thereabouts) times for me.

but yes, thanks for the tip. I remember using Brucken's WinFOSSIL under Windows for Workgroups many years ago - I hadn't realised it'd branched out into other areas.

Make sure I/O range is available (1)

RadioheadKid (461411) | about 13 years ago | (#2437744)

If another driver has already registered that I/O address, you won't be able to get to it, so I think you have to disable the Parallel Port driver or I believe there are functions in the API to make calls through the parallel port driver to get to the hardware. I remember playing around with this a while ago and having problems due to the parallel port driver. Hope that helps.


Just do it the preferred way. (1)

ferret007 (442361) | about 13 years ago | (#2447272)

If you use the CreateFile API with the path "\\\\.\\LPT1" you can use ReadFile and WriteFile on the port. No need to make it harder than it really is.

Re:Just do it the preferred way. (1)

EMIce (30092) | about 13 years ago | (#2447863)

I think what he wants is direct access to the bits that contol the port. ReadFile and WriteFile will stream data in and out of the parallel port using the standard protocol, but won't allow control at the pin level.
Check for New Comments
Slashdot Login

Need an Account?

Forgot your password?