the NT series blocks direct access to h/w ports , u need drivers for them, beyondlogic and sysinternal have some tools and utils.search for inpout32.dl
Do a search fpr INPOUT32.DLL Free and easy access to LPT. Jan Axleson has one but it is for VB. Samples are for DOS but it works in Windows.
P.S. Check all of the inlude files.