Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Introducing: MalaOri for Mala and rotating monitors.  (Read 1542 times)

0 Members and 1 Guest are viewing this topic.

DaOld Man

  • Trade Count: (+4)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5140
  • Last login:May 20, 2024, 06:16:01 pm
  • Wheres my coffee?
    • Skenny's Outpost
Introducing: MalaOri for Mala and rotating monitors.
« on: October 11, 2009, 12:19:54 am »
If you have a rotating monitor rig that uses the printer port to turn the monitor, and you use Mala, then you need this program: MalaOri.
I got this idea from Loadman, with his plugin called monori.
Monori turns your mala screen to match your monitor position, based on switches that are connected to your printer port.
I didnt like monori, because the Mala splash screen always appears in the orientation that was last used. So I wrote a small app to set up the Mala ini file before Mala starts.
I call it MalaOri.
This app will be good even if you use a manual setup to rotate your monitor. Just tie two switches back to your printer port to tell MalaOri the current orientation of the monitor.
Here are some screen shots and a little tutorial on using MalaOri.
When you first run MalaOri, you should receive this message:

Just click ok, then you should see this message:

Click Ok, and you should see the main setup screen:

First, click on the browse button beside "Path to Mala.exe"
You should see a browse function where you can pick out the Mala.exe file you are using:

After clicking OK, you should go back to the main screen, where you can now browse to the mala.ini file. (should be in same folder as mala.exe):

Click OK, you should be returned to the main setup screen. Now your paths should be set.
Next, set your correct printer port address.
Also you can see the inputs.
You can assign what printer port inputs your monitor orientation switches are connected to by clicking on "Inputs" button on main screen. Clicking on this button will open this screen:

Here you can assign which switch connects to which printer port pin. If you are not using any of the 4 orientations, just check "Dont use" checkbox for that orientation.
You can also pick if the inputs go low when made, or if they go high when made.
Closing this screen takes you back to the main screen.
After you have set the correct paths to mala.exe and mala.ini, you will see a button called "INI Commands".
Clicking this button will take you to this screen:

Here you can set the commands that are written to the mala.ini file, based on orientation inputs.
You can also test each position, to see how it looks. Mala should start in the selected orientation.
Also on this screen, you can pick which orientation will be default, should no inputs be made, or more than one.
Closing this screen takes you back to the main screen, where you can click on the options button to get this screen:

On this screen, you can choose actions to take if no switches are made, or if more than one is made.
You can also select to start MalaOri when windows starts.
An entry for MalaOri will be placed in the MSconfig startup programs list.
MalaOri will start next time Windows starts.
You dont need to select Mala to start with windows if you use this.
Also, dont select this if you shell into MalaOri.
You can also choose MalaOri to turn off all printer port outputs when started. Not sure if this has any usable function, but I thought, why not?
You can also select to keep MalaOri open until Mala ends.
If this is selected, MalaOri wont close until Mala ends. If this is not selected, then MalaOri ends as soon as Mala starts.
This can be useful if you are running MalaOri from another program, such as The Launcher.
You can also choose if MalaOri keeps a log, for debugging purposes.
If selected, MalaOri will keep 3 log text files of the last 3 times it ran.
You can also delete the logfiles from here.
Closing the Options Screen takes you back to the main screen.
If you click on the About MalaOri button, you should see this screen:

Closing the main screen closes the setup mode, and a malaori.ini file is written. Here is a screen shot of my malaori.ini file:

Next time Malaori runs, it will setup Mala's orientation based on the inputs.
Then it runs Mala.
MalaOri should be quick and pretty much behind the scenes.
You must have your printer port address set up correctly, and the paths to mala.exe and mala.ini have to be right.
You will also need a copy of inpout32.dll placed in windows\System32 folder.
Hope you enjoy.

DaOld Man

  • Trade Count: (+4)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5140
  • Last login:May 20, 2024, 06:16:01 pm
  • Wheres my coffee?
    • Skenny's Outpost
Re: Introducing: MalaOri for Mala and rotating monitors.
« Reply #1 on: October 11, 2009, 12:45:31 am »
Malaori has been uploaded to the file repository in the misc section, awaiting validation.

I might add that you can run Malaori setup at anytime by changing the first line in the malaori.ini file to "run setup = yes", then saving the ini file and running malaori.
Next time the line will be changed back to "run setup = no".
You can also run the setup mode from command line by entering malaori.exe setup.
I created a desktop shortcut to malaori and added setup to the target line of the shortcut's properties.
Example:
"C:\Arcade\Mala\malaori.exe" setup
If I want check MalaOri's setting, I just run the shortcut, which opens MalaOri in setup mode.
It should not be necessary to run setup mode once you have everything set correctly, unless something changes. (such as paths to mala, new version of mala added, etc).
You can also make any changes in the malaori.ini file itself, but I highly suggest you run the setup mode, it is just a lot easier, trust me.