inpout32.dll (1.5.0.1) win7 and QB64 works with issues

My x64 port of InpOut32
User avatar
phil
Site Admin
Posts: 7810
Joined: Sun Apr 06, 2003 11:12 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by phil »

ftbrady,

Firstly, Apologies if my hijacking the thread comment came across worse than I intended - it just cause a little confusion maybe only for me :).

When it says run installdriver in the \win32 folder, its means run the exe that is in the win32 folder inside the zip file. it does not matter where you put it on your PC, so long as InpOut32.dll is in the same location. Usually I would put these files alongside (with) the software that uses it - i.e, in the same folder as your application.

If you intend to distribute the application, you may want to create your own installer that loads the driver (or calls InstallDriver.exe) so the user does not have to worry about that! The source code for the DLL and InstallDriver.exe is available on my website also!

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)
ftbrady
Member
Posts: 16
Joined: Mon Mar 07, 2016 9:48 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by ftbrady »

OK Phil
Exactly as I hoped - I just got hung up on the "\Win32" went right over my head (I hadn't seen yet that it was the name of the folder he used. This isn't for distribution - I'd have to be a lot sharper if that were the case. Thanks for the help and all that you've done for a lot of folks.
Best of luck to you.
ftbrady
ftbrady
Member
Posts: 16
Joined: Mon Mar 07, 2016 9:48 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by ftbrady »

Phil -
Big P.S. - I just saw my notes that said to ask how I determine the port that I will address for output?
Tx
ftbrady
User avatar
phil
Site Admin
Posts: 7810
Joined: Sun Apr 06, 2003 11:12 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by phil »

Im not sure I can answer that one, especially as I dont know what port your trying to control.
If its parallel, then LPT1 used to be on 0x378 I think. Serial, com1 would be 0x3F8 but you have to poke other ports around that to control BAUD and all that (to be honest, for serial, one wouldn't usually use Inpout32 unless you wanted to do some pretty unusual things to the COM port! because serial IO is there in Windows anyway - or is in most proper languages - maybe not QB64!).

Bear in mind that Inpout32 does not work with USB devices. It does work with some PCI and PCIe devices but not all of them. It was designed (not by me) to work with legacy hardware like onboard parallel/serial ports and "bios" port registers.

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)
ftbrady
Member
Posts: 16
Joined: Mon Mar 07, 2016 9:48 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by ftbrady »

Phil
This has nothing to do with serial port - I have that working fine. Just controlling some relays with the parallel port pins. I know the suspicions about USB parallel adapters and I made sure that the adapter is "100%" IEEE parallel standard compliant - the software shouldn't be able to tell it from a 'real' parallel port.. If that turns out to be a problem, I'll definitely be looking for answers elsewhere.

I'll dig around to determine the hardware port - thanks again
ftbrady
ftbrady
Member
Posts: 16
Joined: Mon Mar 07, 2016 9:48 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by ftbrady »

Phil
My 78 year old memory 'forgot' that I had ordered a PC card to provide the port - but I've been calling it an adapter so long that I forgot - you were right, none of the "adapters" are IEEE compliant.
I used msconfig to find the port address(es) they range from 378 through 37F.
Now all I have to do is sit by the mailbox till the card arrives.
As usual - many thanks
ftbrady
User avatar
phil
Site Admin
Posts: 7810
Joined: Sun Apr 06, 2003 11:12 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by phil »

Jolly good.

For what its worth, I use a USB device from velleman, http://www.velleman.eu/products/view/?c ... &id=351346 for all my PC IO needs now, there are also cheaper usb relay boards on EBay that I have used. No special drivers required, most appear as virtual com ports or something (the velleman is a HID device IIRC) but very easy to code against in .NET.

Thats why I dont use InpOut myself anymore.
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)
ftbrady
Member
Posts: 16
Joined: Mon Mar 07, 2016 9:48 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by ftbrady »

That's good new Phil - I've always felt a little vulnerable with only one way to drive my relays. I'm pasting your comments into my Relay I/O reference history just in case.
Seeya
ftbrady
danube
New User
Posts: 7
Joined: Thu Mar 03, 2016 11:12 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by danube »

Hi ftbrady,

I'm reviving my quest to get a serial port working on a Win7 machine using QB64. I will try as you had suggested earlier to check on the MSDN forums and see if I can get any traction there. Thanks for your help.

I was reading back some of my messages and realize in the perspective of hindsight that I may have seemed a little glib in refusing your help with regard to serial ports on Visual Basic. I just wanted to let you know that the offer is appreciated, but I am really only interested in trying this with QB64 or VBa. As I mentioned, those are IDE's I am familiar with.

As far as VBa goes, there is a nice tutorial (and code) to get a serial port working here:
http://dev.emcelettronica.com/serial-po ... -excel-vba

I have tried it and it works on an XP machine, AND a Win7 machine running Office 2003.. I also added "PtrSafe" after all the DECLAREs and with that modification it works fine on a Win7 machine running Office 2010. So this is a nice development which will get me running quickly with my equipment, at least using Excel. I'd still like to nail down QB64.

Thanks again,

Dan
ftbrady
Member
Posts: 16
Joined: Mon Mar 07, 2016 9:48 pm

Re: inpout32.dll (1.5.0.1) win7 and QB64 works with issues

Post by ftbrady »

Dan
Glad to hear you're making progress - sorry I have no experience with QB or VBA - Good luck.
Post Reply