Skip to content

Commit

Permalink
Added parallel port driver for Windows 64Bit systems.
Browse files Browse the repository at this point in the history
  • Loading branch information
venthur committed Apr 27, 2011
1 parent 47244b6 commit 66c5e1d
Show file tree
Hide file tree
Showing 12 changed files with 113 additions and 3 deletions.
16 changes: 13 additions & 3 deletions tools/README
@@ -1,10 +1,20 @@
inpout32.dll
============

Windows 32 Bit (inpout32.dll)
=============================

Use this file to use the parallel port on Windows. Copy this file to
Windows\System, a restart is not needed.

Sources and Binaries are from
Sources and Binaries are from:
http://logix4u.net/Legacy_Ports/Parallel_Port/Inpout32.dll_for_Windows_98/2000/NT/XP.html


Windows 64 Bit (x64)
====================

Apparently you have to execute the installer in x64/Win32/InstallDriver.exe
with administrator rights and that's it.

Binaries are from:
http://www.highrez.co.uk/Downloads/InpOut32/default.htm

12 changes: 12 additions & 0 deletions tools/x64/DLPortIO.txt
@@ -0,0 +1,12 @@
From Verison 1.0.0.7, InpOut provides basic DLPortIO compatibility, for use with LCDSmartie etc.

It is however, not fully tested as my development machines (DFI motherboard) does not have a parallel port!!!
To use with LCD smartie, take the 32bit DLL (in \Win32) and rename it to DLPortIO.dll

Copy this DLL to your LCD Smartie folder and then give LCDSmartie a go.
I know that LCD Smartie loads the DLL and talks to it properly - I'm just unsure if it reads/writes the port.

Let me know if you have any problems.

Thanks,
Phil (Phil@Highrez.co.uk)
24 changes: 24 additions & 0 deletions tools/x64/ReadMe.txt
@@ -0,0 +1,24 @@
InpOut32Drv Driver Interface DLL
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Modified for x64 compatibility and built by Phillip Gibbons (Phil@highrez.co.uk).
See http://www.highrez.co.uk/Downloads/InpOut32 or the Highrez Forums (http://forums.highrez.co.uk) for information.
Many thanks to Red Fox UK for supporting the community and providing Driver signatures allowing Vista/7 x64 compatibility.



Based on the original written by Logix4U (www.logix4u.net).


Notes:

The InpOut32 device driver supports writing to "old fashioned" hardware port addresses.
It does NOT support USB devices such as USB Parallel ports or even PCI parallel ports (as I am lead to believe).


The device driver is installed at runtime. To do this however needs administrator privileges.
On Vista & later, using UAC, you can run the InstallDriver.exe in the \Win32 folder to install the driver
appropriate for your OS. Doing so will request elevation and ask for your permission (or for the administrator
password). Once the driver is installed for the first time, it can then be used by any user *without*
administrator privileges

Binary file added tools/x64/Win32/InstallDriver.exe
Binary file not shown.
Binary file added tools/x64/Win32/inpout32.dll
Binary file not shown.
32 changes: 32 additions & 0 deletions tools/x64/Win32/inpout32.h
@@ -0,0 +1,32 @@
#pragma once

//Functions exported from DLL.
//For easy inclusion is user projects.
//Original InpOut32 function support
void _stdcall Out32(short PortAddress, short data);
short _stdcall Inp32(short PortAddress);

//My extra functions for making life easy
BOOL _stdcall IsInpOutDriverOpen(); //Returns TRUE if the InpOut driver was opened successfully
BOOL _stdcall IsXP64Bit(); //Returns TRUE if the OS is 64bit (x64) Windows.

//DLLPortIO function support
UCHAR _stdcall DlPortReadPortUchar (USHORT port);
void _stdcall DlPortWritePortUchar(USHORT port, UCHAR Value);

USHORT _stdcall DlPortReadPortUshort (USHORT port);
void _stdcall DlPortWritePortUshort(USHORT port, USHORT Value);

ULONG _stdcall DlPortReadPortUlong(ULONG port);
void _stdcall DlPortWritePortUlong(ULONG port, ULONG Value);

//WinIO function support (Untested and probably does NOT work - esp. on x64!)
PBYTE _stdcall MapPhysToLin(PBYTE pbPhysAddr, DWORD dwPhysSize, HANDLE *pPhysicalMemoryHandle);
BOOL _stdcall UnmapPhysicalMemory(HANDLE PhysicalMemoryHandle, PBYTE pbLinAddr);
BOOL _stdcall GetPhysLong(PBYTE pbPhysAddr, PDWORD pdwPhysVal);
BOOL _stdcall SetPhysLong(PBYTE pbPhysAddr, DWORD dwPhysVal);





Binary file added tools/x64/Win32/inpout32.lib
Binary file not shown.
Binary file added tools/x64/Win32/vssver2.scc
Binary file not shown.
32 changes: 32 additions & 0 deletions tools/x64/x64/inpout32.h
@@ -0,0 +1,32 @@
#pragma once

//Functions exported from DLL.
//For easy inclusion is user projects.
//Original InpOut32 function support
void _stdcall Out32(short PortAddress, short data);
short _stdcall Inp32(short PortAddress);

//My extra functions for making life easy
BOOL _stdcall IsInpOutDriverOpen(); //Returns TRUE if the InpOut driver was opened successfully
BOOL _stdcall IsXP64Bit(); //Returns TRUE if the OS is 64bit (x64) Windows.

//DLLPortIO function support
UCHAR _stdcall DlPortReadPortUchar (USHORT port);
void _stdcall DlPortWritePortUchar(USHORT port, UCHAR Value);

USHORT _stdcall DlPortReadPortUshort (USHORT port);
void _stdcall DlPortWritePortUshort(USHORT port, USHORT Value);

ULONG _stdcall DlPortReadPortUlong(ULONG port);
void _stdcall DlPortWritePortUlong(ULONG port, ULONG Value);

//WinIO function support (Untested and probably does NOT work - esp. on x64!)
PBYTE _stdcall MapPhysToLin(PBYTE pbPhysAddr, DWORD dwPhysSize, HANDLE *pPhysicalMemoryHandle);
BOOL _stdcall UnmapPhysicalMemory(HANDLE PhysicalMemoryHandle, PBYTE pbLinAddr);
BOOL _stdcall GetPhysLong(PBYTE pbPhysAddr, PDWORD pdwPhysVal);
BOOL _stdcall SetPhysLong(PBYTE pbPhysAddr, DWORD dwPhysVal);





Binary file added tools/x64/x64/inpoutx64.dll
Binary file not shown.
Binary file added tools/x64/x64/inpoutx64.lib
Binary file not shown.
Binary file added tools/x64/x64/vssver2.scc
Binary file not shown.

0 comments on commit 66c5e1d

Please sign in to comment.