Possible installation problem

My x64 port of InpOut32
Post Reply
harry6217
New User
Posts: 4
Joined: Wed Feb 13, 2013 7:40 pm

Possible installation problem

Post by harry6217 »

I have been using Port95NT (dlportio.dll) in my app for about 14 years. Most recently with VB6. Now I need to run the app on Win 7 x64 (as a 32bit app). Of course Port95NT will not install. I thought I would test InpOut32 first in Win XP since I know that dlportio.dll works there. When I run with dlportio.dll I get return values that are not -1 or 0 but normal values. With InpOut32 I consistently get -1.

I saw this happen with Port95NT if, after a fresh install of XP, I did not use the Port95NT install program but just placed the DLL in the System32 folder. When I would run the following message would come up:
DLPORTIO.SYS device driver not loaded.
Port I/O will have no effect.

If I Ok'd the message and let the program continue it will return -1 just like InpOut32.

I did notice that when I placed InpOut32.dll in the System32 folder and ran for the first time InpOut32.sys was created in the System32\Drivers folder. There were also some entries in the registry for InpOut32.sys.

At this point I am dazed and confused. Any help would be appreciated.

Thanks,
Harry
User avatar
phil
Site Admin
Posts: 7627
Joined: Sun Apr 06, 2003 11:12 pm

Re: Possible installation problem

Post by phil »

Firstly the DLL does not need to be in the system32 folder. It should be in the application folder. The DLL itself has the driver (.sys) embedded inside it. On opening, it extracts and installs the driver.

Of course, to do this, you need admin privileges so maybe thats your problem?
There is an "InstallDriver.exe" but that is for VVists/7/8 because it forces elevation to admin mode - this wont work on XP.

However if it has put the driver .sys file into the System32\drivers I would expect its got enough permissions!
Is it 32bit or 64bit XP?

Is there anything in the event log relating to inpout32 driver installation or error?

In device manager, if you show hidden/legacy devices, do you see InpOut32 in there? Is it started?

What version of InpOut32.dll are you using?

Thanks,
Phil
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9/G604/M720/MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, AMD Ryzen 5900x, MSI x570 Tomahawk, 32GB DDR4,
nVidia RTX 2070s, Evo 970 1Tb NVME, 2x2TB WD Black (RAID1)
harry6217
New User
Posts: 4
Joined: Wed Feb 13, 2013 7:40 pm

Re: Possible installation problem

Post by harry6217 »

I tried the DLL in both the application folder and System32 with no success.

I am logged with Administrative rights.

It is 32 bit XP.

I did see the following three events. I don't know what to attribute them to:

-The inpout32 service was successfully sent a start control.

-The inpout32 service failed to start due to the following error:
The system cannot find the file specified.

-The inpout32 service was successfully sent a start control.

In device manager inpout32 does show as started. If I manually Stop it, when I run my program it shows as started again.

Inpout32.dll version is 1.5.0.0.

Thanks,
Harry
harry6217
New User
Posts: 4
Joined: Wed Feb 13, 2013 7:40 pm

Re: Possible installation problem

Post by harry6217 »

Thought you might want to see the Declare statements for the 2 calls I am making:

Public Declare Function DlPortReadPortUlong Lib "inpout32.dll" (ByVal Port As Long) As Long
Public Declare Sub DlPortWritePortUlong Lib "inpout32.dll" (ByVal Port As Long, ByVal Value As Long)

These are the same as the ones I use for DLportIO.dll.
User avatar
phil
Site Admin
Posts: 7627
Joined: Sun Apr 06, 2003 11:12 pm

Re: Possible installation problem

Post by phil »

Ahhh I think there may be a problem with the DlPortReadPortUlong and DlPortWritePortUlong calls.
Can you try the inp / out calls?

I think someone else reported that the DLPortIO long calls were not working :(
Unfortunately I never actually used/tested them - I just put them in in the hope that it might make InpOut32 compatible with DLPortI for others. I only ever used the BYTE in and out from DLPortIO.

Thanks,
Phil
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9/G604/M720/MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, AMD Ryzen 5900x, MSI x570 Tomahawk, 32GB DDR4,
nVidia RTX 2070s, Evo 970 1Tb NVME, 2x2TB WD Black (RAID1)
harry6217
New User
Posts: 4
Joined: Wed Feb 13, 2013 7:40 pm

Re: Possible installation problem

Post by harry6217 »

Are these the Declares you are talking about?
Public Declare Function Inp Lib "inpout32.dll" Alias "Inp32" (ByVal PortAddress As Integer) As Integer

Public Declare Sub Out Lib "inpout32.dll" Alias "Out32" (ByVal PortAddress As Integer, ByVal Value As Integer)

I need to pass a Long number.

Harry
User avatar
phil
Site Admin
Posts: 7627
Joined: Sun Apr 06, 2003 11:12 pm

Re: Possible installation problem

Post by phil »

yes I know those work. If you need thelong you might be out of luck with my DLL :(
The source is there for the driver and DLL so you can always have a look and see - as I said, its not something I've ever used.

The problem is, for Win 7 etc, the driver needs to be signed, so I cant easily change it (it was signed for me by a nice user - I cant afford, nor buy a certificate as you have to be a registered business to do so :( )
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9/G604/M720/MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, AMD Ryzen 5900x, MSI x570 Tomahawk, 32GB DDR4,
nVidia RTX 2070s, Evo 970 1Tb NVME, 2x2TB WD Black (RAID1)
Post Reply