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: joytokey problems with mame  (Read 7355 times)

0 Members and 1 Guest are viewing this topic.

severdhed

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2975
  • Last login:December 14, 2024, 05:01:52 pm
  • RIP Dinosaur Hippo
joytokey problems with mame
« on: June 20, 2007, 09:28:59 am »
hey guys, i really need some help with this one...i searched the forums, but couldnt find an answer to this problem..so here it goes.

my cabinet runs mame, using MALA as a front end.   my coin doors are wired to an old PC gamepad, and i use joytokey to make them work with mame.  this works fine when using explorer as my shell, because i can either manually start joytokey, or have it in the startup folder, which also works fine. 

however, i use MALA as my shell, so the desktop doesnt load.  the problem with this is, the windows startup folders are not processed this way, so i cannot automate the start of joytokey.  I cannot seem to find a startup location in windows that will load this app without first loading explorer.

i looked through the wiki in the "hiding windows" section, where there is listed a program called xynt service, which is supposed to allow you to install an application as a windows service, so it will launch like i want it to.  i downloaded and installed this, set it up for joytokey and that works fine.  it loads right at startup when mala loads...but if this service is running, mame will not run any games.  it just flashes the starting screen, then quits.

to make sure it wasnt a mala problem..i set my shell back to explorer, and had the joytokey service load.  even if i try to launch a game directly via mame command line, it will not work if that service is running.  it gives me an error: osd_init failed.  as soon as I stop the joytokey service, it works just fine.

i uninstalled that service, and used srvany from the windows resource kit to create a joytokey service.  however this service loads, but never seems to actually work.  from what I can tell, it loads joytokey, but comes up with the original configuration, which i cannot change, instead of the mame config that i created.

I am getting ready to redo my control panel, and i dont really have enough inputs on my encoder to use for the coin slots, so the pc gamepad is pretty much my only choice.

so, is there:

- a way i can get joytokey to load at startup even though explorer isnt loading?

- another program that will give me the functionality of joytokey, that i can maybe run as a service and have mame still work?

- a way to configure mame to use gamepad/joystick buttons for coins? (i remember trying to get this to work along time ago without much luck)

- another option that I am not thinking about?

i temporarly have a 3button combination to act as coin inputs on my panel until i get this workign, but that is not a permanent fix.  i want the real arcade feel, and for that i need working coin doors.


please help

just for the record, my cabinet is running windows xp sp2.  i have tried several different versions of mame, including the most current one, but they all give me the same "osd_init failed" error when the joytokey service is running.

Current Projects:      Zak-Man | TMNT Pedestal | SNES Pi | N64 Odroid
Former Projects:     4 Player Showcase | Donkey Kong | iCade

Green Giant

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1124
  • Last login:September 29, 2016, 06:50:57 pm
Re: joytokey problems with mame
« Reply #1 on: June 20, 2007, 09:58:12 am »
Which version of joytokey are you using.  I think I am using 3.79 on my cab.  I have it setup to just emulate a few specific key presses for special emulators. 

Why can't you use the gamepad in mala as a joystick.  Seems as though windows would see it as a joystick and allow you to set it up to control mame and mala.  I am using GPWIZ49's which are seen as joysticks with 23 buttons attached.  I just setup mala to use joysticks and mapped mame to the joystick buttons.

But back to the problem at hand.  When you have joytokey load at startup, are you trying to load a special config file for it.  I haven't shelled mala, just setup windows to load to a black desktop with no start menu, but I do run joytokey on the startup.  It loads the default config file which saves to my documents I think.  All I did was edit this config with the inputs I needed.  I think mainly exit to esc and two other buttons to some letters.  Not sure if this helps or not.  Let me know if you need 3.79 and I can send it.

As for the other questions, joytokey is the best I have seen at mapping button presses.  I tried autohotkey, but there was a lag in the presses being read on some games and emulators.

Configuring the joystick for coins is easy.  Just open up any mame game, press tab, select general inputs, select coin, and press the button for the coin.  I think mine is mapped to joyinput22.  To double check just open up the control panel and see if windows recognizes your gamepad as a joystick.  If it does and button clicks respond on the joystick setup window, then you shouldn't even need joytokey.  You can look at my default config file to see what I mean.

            <port type="COIN1">
                <newseq type="standard">
                    J1_BUTTON_22
                </newseq>
            </port>
"He lives down there in his valley,
The cat stands tall and green,
Well, he ain't no prize, and there's no women his size,
And that's why the cat's so mean"
Toxic Arcade, my first build

severdhed

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2975
  • Last login:December 14, 2024, 05:01:52 pm
  • RIP Dinosaur Hippo
Re: joytokey problems with mame
« Reply #2 on: June 20, 2007, 06:45:19 pm »
thank you!!!   i have this tendency to over complicate things.  assigning coin 1 and 2 to joy 1 and 2 within mame works just like i need it to.  and now i dont have to worry about joytokey.  thank you very much

Current Projects:      Zak-Man | TMNT Pedestal | SNES Pi | N64 Odroid
Former Projects:     4 Player Showcase | Donkey Kong | iCade

severdhed

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2975
  • Last login:December 14, 2024, 05:01:52 pm
  • RIP Dinosaur Hippo
Re: joytokey problems with mame
« Reply #3 on: June 20, 2007, 11:35:33 pm »
now i know why i didn't do this before.  i have the coin slots wired up to the gamepad and mame set to use the joystick buttons, which for the most part works...but there are some games that do not work this way. 

for instance, Rastan.  it just doesn't recognize the gamepad.  i didnt try all of the games on my cabinet, but i picked like 10 and tested them, all of them work fine this way, except rastan.  it isnt that big of a deal, because i can map a coin button within that game's config, but it is just weird.  i thought i had problems setting this up in the past, and now that I think about it, when i first tried to use the joypad buttons as coin buttons, the game i was playing alot, and using for testing was rastan.

Current Projects:      Zak-Man | TMNT Pedestal | SNES Pi | N64 Odroid
Former Projects:     4 Player Showcase | Donkey Kong | iCade