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: Wiring 4-way stick & trackball buttons  (Read 2180 times)

0 Members and 1 Guest are viewing this topic.

clhug

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 179
  • Last login:April 04, 2024, 10:49:58 pm
Wiring 4-way stick & trackball buttons
« on: November 21, 2008, 10:51:42 pm »
Couple questions on wiring in extra stuff on the control panel.

I want to add a 4-way stick on my control panel.  What's the best way to wire this in and why?  I'm thinking just wire it in parallel to the same inputs to the conroller as the normal Player 1 Joystick.  Is there any reason to wire it into it's own joystick inputs?

I'm also adding a trackball.  I already have a trackball with USB interface.  No issues with the trackball itself.  The question is whether I should bother to wire in pushbuttons specifically for the "mouse" buttons on the trackball or not.  Why would I specifically need "mouse" buttons?  Why can't I still just use the normal Player 1 buttons that I would use with the joystick?

Thanks!

clhug

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 179
  • Last login:April 04, 2024, 10:49:58 pm
Re: Wiring 4-way stick & trackball buttons
« Reply #1 on: November 27, 2008, 12:34:04 am »
bump

surface tension

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 323
  • Last login:July 01, 2018, 08:45:48 am
  • feel the tension...
    • surface tension tables
Re: Wiring 4-way stick & trackball buttons
« Reply #2 on: November 27, 2008, 03:26:33 am »
Joystick... sure, just wire the 4-way in with your normal player 1 joystick. They will just both work, but no problem.

Mouse buttons... not sure what you are asking. Do you want a reason to use mouse buttons? Only wire up mouse buttons if you need mouse buttons, like if you wanted to have windows navigation capability from the control panel.

Just for example, my player 1 buttons 5 and 6 are wired to the minipac as L and R mouse, and configured appropriately in MAME. They are there as mouse buttons (along side the trackball) if that's what you want.

clhug

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 179
  • Last login:April 04, 2024, 10:49:58 pm
Re: Wiring 4-way stick & trackball buttons
« Reply #3 on: November 28, 2008, 09:56:26 pm »
Thanks!

I think you got the general jist of my questions on the mouse buttons, but you did raise a bit more of a question on my part.

The basic original question was more, do I specifically need "mouse" buttons with the trackball for anything, particularly in MAME.  Or, does MAME even used mouse button inputs for any controls.  (I don't care about Windows navigation.)

The USB controller for the track ball has inputs on it to wire buttons to for the left, middle, and right mouse buttons, but is there any reason to wire them in?  If MAME actually uses mouse button inputs for anything then I should wire these in.  I don't have any other way to wire in actual "mouse" buttons.

My thought was more, I've already got 6 buttons there for each player.  Does MAME just use those for trackball games or does it actually expect separate "mouse" buttons?  Why wouldn't it just reuse the same Player 1 buttons that are already there instead of requiring separate actual mouse buttons?

I know what I want to ask but I'm having a hard time trying to word it exactly.

Oh, just had this idea.  Let me sum up in 2 additional questons.

1. Does MAME use actual "mouse" buttons for anything as it's default config? (and could you give an example, or does any game that uses a trackball expect to use the "mouse" buttons as button inputs for those games?)

2. If the answer to 1 is "yes", is there any reason I couldn't just remap in MAME whatever controls map to the "mouse" buttons by default to the same keys as the Player 1 buttons instead (ctrl, alt, and space which are the default mappings for the player 1  buttons 1 through 3)?

Thanks again!

surface tension

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 323
  • Last login:July 01, 2018, 08:45:48 am
  • feel the tension...
    • surface tension tables
Re: Wiring 4-way stick & trackball buttons
« Reply #4 on: December 01, 2008, 07:43:24 am »
If you haven't wired in the mouse buttons and don't want to use them, then don't.

MAME isn't pre-configured to use mouse buttons, they are just assignable if you want to. What I mean is that it's just an assignable input just like 'a' or 'Lctrl' is. Not mouse-button specific.

I hope this gets the point across!

u_rebelscum

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3633
  • Last login:April 21, 2010, 03:06:26 pm
  • You rebel scum
    • Mame:Analog+
Re: Wiring 4-way stick & trackball buttons
« Reply #5 on: December 01, 2008, 06:40:55 pm »
st got it, but my two cents/more info...

1. Mame does use the mouse buttons, but "sort of" not be default.  First, mame defaults not to use the mouse (-mouse 0), so no inputs from the mouse are used.  Okay, so you enable mice; mame input map defaults include the mouse buttons.  "Include" is the word; there is no input in mame with only mouse buttons mapped to it and all inputs that a mouse button is mapped to also is mapped to keyboard (and joystick) buttons. 
Example: player one button one has the following mapped by default: keyboard1 LCtrl, OR joy 1 button 1, OR mouse 1 button 1, OR lightgun 1 button 1.  Notice the "OR"s; if any of these are pressed, mame sends the game that player 1 button 1 was pressed.

2. Yes.  Any input* in mame can be remapped to any input device and button/key.  Mame can map ORs like the example above, and ANDs (combos where all ANDed inputs need to be pressed at the same time), and NOTs (compare reset vs soft reset: the former is F3 + LShift, while the latter is F3 if and only if LShift is not pressed at same time).  But you don't need to remap.
(* hardcoded debug inputs can't be remapped in software, but they are rare, and removed as the game is better emu'ed.)


So for mame you don't need mouse buttons.  Windows, Front Ends, other emus, other games, other apps might, though, so look at them and see if any you're going to use needs it.
Robin
Knowledge is Power

clhug

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 179
  • Last login:April 04, 2024, 10:49:58 pm
Re: Wiring 4-way stick & trackball buttons
« Reply #6 on: December 01, 2008, 08:24:05 pm »
Thanks folks!  That tells me exactly what I wanted to know.