The NEW Build Your Own Arcade Controls

Main => Software Forum => Topic started by: CNC_Tech on May 10, 2015, 11:23:22 am

Title: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: CNC_Tech on May 10, 2015, 11:23:22 am
I finally started playing around with MAME about a month and a half ago after seeing it in the early days in the 90's and just never getting around to it.  One of the many decisions I wrestled with was monitor orientation.  I ended up deciding the best solution was to build an automated monitor spinner which I'll get posted in the Automated thread in the next week or two.  I'm using an Arduino to monitor and control a stepper motor.  I'm a decent machinist and dance pretty well with silicon and wires, but I'm not the best bit wrangler around.  I need help with getting this interfaced with Hyperspin.   

Does anyone know of a way to have HS trigger a port on an IPAC Ultimate depending on orientation that I could easily pick off with the micro?  Sniffing around I've seen a couple of solutions but they are dependent on hardware that I don't have.  If there's no known way of triggering an IPAC, then that would leave me with standard I/O ports.  I won't have a parallel port and chances are there won't be an RS232 port either. I was thinking I could use a USB to RS232 adapter that supports the hardware flow control lines and pick off those.

Any help or ideas would be greatly appreciated.
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: bfauska on May 11, 2015, 02:56:42 pm
Welcome to the forum, I look forward to seeing your progress, the automation type threads are always interesting and based on your screen name I suspect you can do some clean work.
In a half-ignoring-your-question response I'll go ahead and ask what you want the LED to accomplish? Assuming that your monitor will always be in one of two positions couldn't you use a physical switch to change which LED is illuminated based on the position of the monitor? You could still control the LED with the PC you just wouldn't have to deal with another level of IO. I'm sure there are grander plans for your project than something that could be handled that simply but sometimes it doesn't hurt to make sure the simple approach wasn't being overlooked.
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: CNC_Tech on May 12, 2015, 12:51:21 am
Thank you for your response.  To clarify, I want the monitor to automatically rotate to the correct orientation for the game.  The idea behind using IPAC isn't to light an LED for display, but rather light an opto-coupler LED which would trigger an input on the micro to rotate the monitor to that direction.  Every implementation I've seen is using the COM or parallel ports or some other board.  It makes a lot more sense to use the IPAC I already have but sniffing around the Internet I haven't been able to find any solutions, just some other folks asking the same thing.  Due to the lack of response to the others and my question, I'm assuming that there's not an easy way to accomplish this  :(. 
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: Howard_Casto on May 12, 2015, 12:16:47 pm
Well there are "easy" ways, but they are all overkill.  It's like attempting to attack an ant hill with a battletank. 

Mamehooker reports monitor orientation (or at least it used to and still does afaik, mame changes so rapidly these days), so you could use it.  Hyperspin has nothing to do with the problem.... think about it, you don't want your monitor rotating every time you select a game, you want it to rotate after you've launched the game. 
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: bfauska on May 12, 2015, 04:31:49 pm
Continuing with my questionably useful input... Is there a solution using LEDBlinky? It can handle joystick orientation/restriction output, does it do monitor too?
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: headkaze on May 12, 2015, 08:03:01 pm
I wrote a plugin for GameEx that can handle hardware rotation using LPT or LED hardware. You can see it in action here (http://headsoft.com.au/index.php?category=gameex&page=pluginrotate)
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: CNC_Tech on May 13, 2015, 09:07:19 am
...Mamehooker reports monitor orientation (or at least it used to and still does afaik, mame changes so rapidly these days), so you could use it.  Hyperspin has nothing to do with the problem.... think about it, you don't want your monitor rotating every time you select a game, you want it to rotate after you've launched the game. 
Howard, thank you for the heads up.  I took a quick look at it and it appears to be exactly what I was looking for.  It looks simple enough to set up that a software hack such as myself may actually be able to get it to work.

I wrote a plugin for GameEx that can handle hardware rotation using LPT or LED hardware. You can see it in action here (http://headsoft.com.au/index.php?category=gameex&page=pluginrotate)
I appreciate you pointing this out.  If I'm too stupid to figure out Mamehooker (likely), I'll take a look at your solution.
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: CNC_Tech on May 13, 2015, 11:16:43 am
...Mamehooker reports monitor orientation...
Howard,

I got Mamehooker installed but ran into a problem.  When I 'Show Supported Devices' the only thing that comes up is:

Force Feedback Devices
-------------------------

I'm using an Ultimarc Ultimate I/O board.  It is functioning correctly in Windows, Hyperspin, and Mame.  I power cycled the computer after install and it had no effect.  Is the UIO board supported?  If not, I think I saw that Mamehooker can drive a COM port so I can always toss a USB COM port in the machine and do it that way.  I appreciate any insight you can offer.

Marc -
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: Howard_Casto on May 13, 2015, 12:51:57 pm
Honestly I can't keep up with the ultimarc naming schemes.... he seems to be constantly coming up with something.  Ignore show supported devices and try testing it.... if none of the ultimarc commands do anything then I guess it's not supported. 

Sorry to give you such an iffy answer but honestly I haven't worked on mamehooker in quite some time and even when I did, I don't have any ultimarc boards to test with, so testing things was always an exercise in tedium via email tag with someone that does have a device. 
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: headkaze on May 13, 2015, 06:11:55 pm
Honestly I can't keep up with the ultimarc naming schemes.... he seems to be constantly coming up with something.  Ignore show supported devices and try testing it.... if none of the ultimarc commands do anything then I guess it's not supported. 

Sorry to give you such an iffy answer but honestly I haven't worked on mamehooker in quite some time and even when I did, I don't have any ultimarc boards to test with, so testing things was always an exercise in tedium via email tag with someone that does have a device.

I updated PacDrive.dll to support the PacLED64, Ultimate I/O and Nano-LED devices a while ago. The dll has been split into two (PacDrive32.dll / PacDrive64.dll) for 32-bit and 64-bit machines respectively. Since you use the 32-bit version you may just be able to rename PacDrive32.dll to PacDrive.dll for it to work. The Pac64 commands support all three devices (more info is provided in the SDK's ReadMe.pdf file). You can download the latest PacDrive SDK from here (http://www.ultimarc.com/PacDriveSDK.zip).
Title: Re: Lighting LED with IPAC in Hyperspin based on Monitor Orientation
Post by: Howard_Casto on May 13, 2015, 10:17:32 pm
If they still use the same commands then it'll most likely still work.