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: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'  (Read 4389 times)

0 Members and 1 Guest are viewing this topic.

dmworking247

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 305
  • Last login:July 14, 2024, 01:30:59 pm
First of all let me say that I love the feature in Mala to rotate the orientation/layout between vertical and horizontal, and the option to edit the MAME.ini file so that MAME launches in whatever the orientation of the front-end is. Its great.

I used this feature in a bartop I made with a rotating screen, and used a pushbutton on the side to switch it.

I'm now about to do another project which (roughly explained) is a square unit like a picture frame. I will be putting in either a mechanical or electronic switch that will 'sense' the orientation of the box, and send a pulse (ie momentary close circuit) to the encoder.

My feature request for MALA is that I need a seperate button for "Rotate to vertical" and "Rotate to horizontal", instead of (or rather, in addition to) the options to simply 'switch orientation'.

If the front-end is already in horizontal orientation and the horizontal button/input is pressed, it should do nothing (not even play a sound).

The reason I'm requesting this is that I suspect there will be times where (without this feature) the system will get 'confused', ie the 'rotate' switch will get triggered accidentally when it is horizontal (displaying vertical) and when I rotate the box it will then be vertical (displaying horizontal).

I hope that makes sense, is this possible?

Thanks again for a great frontend.

loadman

  • Moderator
  • Trade Count: (+3)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 4306
  • Last login:May 26, 2024, 05:14:32 am
  • Cocktail Cab owner and MaLa FE developer
    • MaLa
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #1 on: January 22, 2009, 10:13:05 am »
You could make a plugin to do this I think....


csa3d

  • Trade Count: (+2)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 872
  • Last login:March 07, 2011, 08:16:35 am
  • Will game for food
    • Galaxian Mame Conversion
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #2 on: January 22, 2009, 10:26:59 am »
I think you can set a hotkey to Mala's "Switch Orientation" funtion.  This KIND of does what you want, but it's a single toggle type button instead of two separate buttons.  Don't know if it would also help you or not, but there's a plugin called MonOri which looks at a parallel port input and when you start Mala with this plugin installed, it detects (from the printer port) if your screen is horizontal/vertical and turns the layout to match.

Just some ideas.  If you have the skills.. code up the plugin suggested.  I can see desire for this.

-csa

DaOld Man

  • Trade Count: (+4)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5158
  • Last login:May 24, 2025, 09:57:44 pm
  • Wheres my coffee?
    • Skenny's Outpost
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #3 on: January 22, 2009, 08:05:02 pm »
Hmmm, what do you think Loadman? Sound familiar?

dmworking247

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 305
  • Last login:July 14, 2024, 01:30:59 pm
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #4 on: January 22, 2009, 08:40:05 pm »
Thanks for the quick responses guys.

Alas, I do not have any skills to do a plugin.

I'm aware of the singular 'switch orientation button' and as mentioned I've used that previously... but in this particular case I'm looking for seperate commands for 'switch horizontal' and 'switch vertical' that ignore the command if the FE is already in that orientation.

The parallel port is an idea, but it seems a little out of reach for the average cab builder who (increasingly it seems) is trying their hand at rotating setups. We also need to consider that parallel ports seem to be dissapearing from boards.

I'm not afraid of doing a parallel port design if I found out how, but unfortunately its not feasible for this project. I am using a 15" touch screen 'all in one' POS setup, whereby the motherboard/CPU is actually mounted in the back of the LCD. In other words, I don't have the space for cables hanging out of the printer port.


If its technically too complicated I understand, but I would have thought having distinct commands for horizontal/vertical would be desireable to quite a few users?  DaOldMan: You mentioned this sounds familiar, has it come up before? I couldn't find any similar threads.

system01

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 283
  • Last login:March 04, 2023, 08:06:55 pm
  • System Idle Processes are the Devil's Playthings
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #5 on: January 22, 2009, 09:03:33 pm »
How do you make that work currently?  I looked through the mala options but didnt see it.

I may have a hardware solution in mind... but prolly not. :-\

dmworking247

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 305
  • Last login:July 14, 2024, 01:30:59 pm
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #6 on: January 22, 2009, 09:22:46 pm »
Well currently there's a command in Mala to switch orientation (vertical to horizontal, horizontal to vertical). It doesn't care which mode its already in, it just changes to the other. I think its in controls>advanced of mala properties.

So on my last bartop project I had a button on the side. I would rotate the screen, then press the button to suit.

This time, I want to build a square box that has a sliding switch attached to a pulse circuit that triggers a keypress in Mala. If I use the existing command, and for some reason its already horizontal when I rotate the monitor, it will switch into vertical. I'll have to 'shake it' (to trigger the mechanism again) or install a standalone 'override' switch to compensate.

system01

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 283
  • Last login:March 04, 2023, 08:06:55 pm
  • System Idle Processes are the Devil's Playthings
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #7 on: January 23, 2009, 12:19:22 am »
Gotcha.  Going for an iTouch approach.

I was thinking of a) a hall effect sensor (looks like a transistor) that would switch when the rotating magnet swept by, or b) a mercury or tilt switch that would close only in one position.

Unfortunately these would still use the same single keypress.  So if someone turned it off vertical and started it in horizontal, youd be stuck crooked.

...unless you build in some poke-yoke where they have to turn if on/off in the same position, like small buttons for both left and right index finger, pressed at once.  I guess like the shoulders of a PS controller?

Otherwise, yeah, you could benefit from two commands.

Sorry.

Blanka

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2248
  • Last login:January 25, 2018, 03:19:28 pm
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #8 on: January 23, 2009, 01:13:36 am »
These switches are the easiest/cheapest approach to sensor orientation:
http://nl.rs-online.com/web/search/searchBrowseAction.html?method=getProduct&R=361-5093

DaOld Man

  • Trade Count: (+4)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5158
  • Last login:May 24, 2025, 09:57:44 pm
  • Wheres my coffee?
    • Skenny's Outpost
Re: Requirement/Request: Seperate buttons for 'switch horizontal/vertical'
« Reply #9 on: January 23, 2009, 07:19:39 am »
Loadman wrote a plugin for me called monori.
Its purpose was to check monitor position on mala startup (this was for my roatating monitor project that used two limit switches that stopped the motor when it reached full horz or vert.)
Im trying to remember how it worked, but it used these switches to tell mala to turn horz or vert.
But it only worked on mala startup.
That way if someone turned the monitor manually to a position, mala would always start up correctly.
You might could use one switch to indicate if monitor is horizontal or not for start up, and another button mapped to the keyboard encoder to flip mala while the arcade is up and running.


Connecting to the printer port is not really hard, you just need to know how to solder and have a little patience.
In my two juke box projects, I used just two wires going to a printer plug. These attached to a switch that I can turn on before i turn on the juke. If I turn on this switch Windows starts up, if the switch is off, Xlobby starts up.
So for what you want to do, you should only need 3 wires, 1 for each switch and a ground for both.
In other words, you dont need to use a bulky printer cable if you only have a couple of switches.