Main > Software Forum

Warlords 4 LED (start button) support

<< < (3/7) > >>

Howard_Casto:
cool.... could you send it over to me?

I might be willing to write a generic i/o funciton for the parallel port into mame if someone else were to take it the extra mile and start modifying the individual drivers. 

SirPoonga:
Man, I have to find the cd I burned it too.... that could take awhile.

Anyway, it just used standard outp() function calls.  In VB you have to use the dll.  But mame uses C.  Is there a version of mame that uses the parallel port for something, I thought there was.  I'm not sure how to make mingw compiler see outp() for windows. I don't see outp implemented for mingw :(

Found a C++ example
http://www.logix4u.net/parallelport1.htm
Note the note at bottom, it should work with 98.
But  yeah, if you want to use direct access in nt based you need a dll.


Neat, found VB code from microsoft!
http://support.microsoft.com/kb/q154078/
The kb article doesn't say if it will work with what OS.
But the article was written in 2004.

Edit: Nevermind on the kb article, read all the way through the article.  It doesn't give you DIRECT direct access as you can't control individual data pins :(


Tons of info here
http://www.lvr.com/parport.htm


Edit:
outp would be in conio.h for whatever compiler.
MingW's conio.h does not have it.
conio.h in \Microsoft Visual Studio .NET 2003\Vc7\include doesn't
conio.h in \Microsoft Visual Studio .NET 2003\Vc7\crt\src does
conio.h in \Microsoft Visual Studio\VC98\Include does

But that's just  aheader file, need to know which lib it is implemented in to see if I cna use that outp().

SirPoonga:
I might be able to access the port directly using assembly.
Found this mingw sample
http://my.execpc.com/~geezer/osd/pnp/pnp.c

I will have to see if I have some LEDs laying around.  However, I don't know if this will work with xp as I don't have 98 installed anywhere.

Edit:
Shhhh, downloaded mingw at work and tried compiling.  It compiled, have no way of testing it though :(
When I get home I will put it in the centiped.c driver (which is where warlords is). 
Shhh again, slow day at work :)  Downloaded mame source.

-----------------------------------------------------
Exception at EIP=01591ED7: PRIVILEGED INSTRUCTION
-----------------------------------------------------
EAX=00000008 EBX=00000008 ECX=77C418BF EDX=00000378
ESI=00000003 EDI=0000012E EBP=0022EC30 ESP=0022EBC0

So yeah, it's privileged.  Need the dll.  Not sure how to do dlls in mingw.


How is one of those LED drivers accessing the parallel port?

2600:
Hence the reason I said wait till the HW and SW for those is done. Don't think the SW is currently released, and there is no reason to reinvent the wheel.  ;)

That being said from my understanding, Buddabing is using the same dll as Daphne.  You could take a quick glance how Daphne is using it.  I think PinMAME-HW is using the same dll as well, but don' t quote me on that.

Howard_Casto:
Yeah... the problem with that dll is, since it's windows specific, the mame devs won't accept any code that uses it afaik.  This needs to get in an official build of mame.  (Newer games tend to use i/o more than older ones, so a consistantly updated build is required.)  The low level inp / outp that sirp is suggesting, along with an optional "port opener" for 2k/xp is the preferred solution.  I beleive it even works in linux and mac os.  (Initilization is sketchy but other than that.)

There used to be a tsr that ran in xp which you told it the exe name, and what port you needed opened, and it told xp to give the app permissions.  I don't remember the name though.  Anyone know?

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version