Jump to content
Unfortunately we had to take download section back offline temporarily. We should have it working normally soon.

Controller advice - XBox360 (for Windows?)... X-Arcade... and how to use both?


needles

Recommended Posts

  • Replies 69
  • Created
  • Last Reply

Ok, so I loaded up hyperspin with the 4 controllers on and plugged in and the arcade stick plugged in.  With the Xbox controllers above the Arcade stick on my device manager here is how they work with Hyperspin and Mame--

 

For Hyperspin, with ghutches script active, my Xbox controller #2 controls the hyperspin front end.  With this controller I can navigate the wheel, enter and exit menues and select games.  Controller #1 let's me navigate the wheel only-- buttons do not work.

 

For Mame, it looks like all the controllers are active within it but there are all going to different players--- For example, I loaded the TMNT arcade game, and controls assign as follows:

 

XBox Controller #1 is Joy4

XBox Controller #2 is Joy1

XBox Controller #3 is Joy3

Xbox Controller #4 is Joy5 (I do believe I used a different xbox controller previously that was labeled as Joy4)

Arcade Stick Player 1 is keyboard controls (Up is Up, Down is Down, etc)

Arcade Stick Player 2 is keyboard controls (Up is R, Down is S, etc)

Link to comment
Share on other sites

Ah, OK. I was afraid of something like this.

 

Can you work out what is taking the place of Joy2?

 

Also, do the Arcade Sticks always emulate keyboard controls, or just in MAME? If they are always set up as keyboards, then you should be OK to just ignore them for the time being as they won't interfere with the other controllers in that case.

 

To fix the order, we are going to have to delete them from device manager (don't worry, not completely). First, turn off your controllers. Open up device manager again and find your controllers (you will have to set "show hidden devices" in order to see ones that are no longer plugged in or have moved ports.) One-by-one, right click on them and delete them. If it asks you to remove the drivers, you can say no.

 

Once you are sure that the controllers are all deleted, you can start to turn them on again in the order you want. This should hopefully get them in the right order. If not, then it seems something else is afoot.

Link to comment
Share on other sites

Hmmm, ok, I tried what you said---

Turned off my controllers, uninstalled (deleted) each xbox wireless controller one at a time.  Then I turned them on 1 at a time and they installed.

Loaded up Hyperspin. The good news is, controller #1 is now in control of my hyperspin wheel! That was a nice victory!

Then I loaded up Mame... so, I did the same procedure with TMNT again--- here is what those controllers are coming up as:

Controller #1 is JoyID 2

Controller #2 is JoyID 3

Controller #3 is JoyID 4

Controller #4 is JoyID 5

 

Joy #2 is back but now there is no Joy #1.  In the game I get players 2, 3, and 4 active and no one controller player #1. 

 

A while ago I had turned on another Xbox controller I had in the room by mistake-- which is where I'm thinking this mysterious JoyID 5 came into play--- wondering how to reverse time and wish I had never turned on that 5th controller :ermm:

Link to comment
Share on other sites

Haha, thanks damaginc86--- I'm trying here! :teehee: Thanks to Tomkun's patience though, I think I may have just figured it out-- I unplugged my arcade stick which seemed to be acting as my Joy1-- when I did that the controllers returned to Joy 1, 2, 3, 4, exactly where they were supposed to be-- when I plugged the arcade stick back in, they all got bumped again.  So, I did what you said for the xbox controllers and unplugged the arcade stick, and deleted it from my device manager-- when I replugged it in after that, it appears to have taken the spot of Joy5, and my xbox wireless are now, at least at this time, stapled to Joy 1-4. I guess the remaining questions are how do I keep it that way --is this sort of arrangement fickle where if I turn everything off and turn it back on in the morning, controllers are going to be all over the place again, or do you think I'm in a good place now? Any tips to keeping it that way?  Should I be worried about unplugging? I'll experiment over the week and make sure everything is hunky dory but, as it is now I'm totally excited to be online and ready to play! I appreciate you help immensely and your willingness to help out a newb :D This process also gave me a better understand of how these things function. Maybe this exchange will help someone else down the line with the same questions! I really appreciate it :))

Link to comment
Share on other sites

You can try a few reboots and just see how it goes. Try turning things on and off in the different orders. If they stay in the right order, then you are good to go. If you find that they change, then we can try to get a batch file working for you to automate it.

 

Oh and I'm very glad you got it working.

Link to comment
Share on other sites

Awesome, sounds great! I'll give it the next few days and try a bunch of things-- see how it holds up and if everything sticks, I'm overjoyed :) You made the process painless and extremely easy to follow. Many thanks!

Link to comment
Share on other sites

You can try a few reboots and just see how it goes. Try turning things on and off in the different orders. If they stay in the right order, then you are good to go. If you find that they change, then we can try to get a batch file working for you to automate it.

 

Oh and I'm very glad you got it working.

Hello Tomkun,

 

So I have a bit of an update.  Controllers have been working in their respective spots  -- arcade stick has stuck with Joy5 and xbox controllers with Joy 1-4.  I tried turning them on in different orders and whichever one I turn on first will take the Joy1 spot, and the others will follow.  In MAME, the controllers still act as Joy 1-4 even though, say the "Silver" controller is now Joy1 instead of the "black" controller -- I'm assuming that is normal and how it usually works...

If so, everything has been working great -- today though, I tested a reboot and it seems like that threw a wretch into the configuration. Controllers went back to being Joy 2-5 and the Arcade stick took the Joy 1 spot.  I returned the controllers to their working joy #'s by doing the original procedure that you taught me-- uninstalling controllers, unplugging the arcade stick and uninstalling that and replugging in.  Things are back to normal--- now I know at least a reboot won't work without having to reconfiguring everything.  You had mentioned doing a batch file that the computer could automate when it is rebooted--  do you think that would solve the problem?  Is it an easy thing to set up? Thanks so much, Tomkun.

Link to comment
Share on other sites

Yeah, this is a similar situation to mine. Basically, every time the computer reboots it initialises the device drivers in a specific order. If that order is not what you want, you get the situation we have now.

 

So what we need to do is write a batch that will:

 

1. Remove the device manager entries for your Arcade Sticks.

2. Tell device manager to scan for new devices.

 

First of all, you are going to have to get hold of Devcon. It's a free download from Microsoft, but the version you use will depend on your OS. I can either be a single download, or part of the Windows Driver Kit. I'll leave that part up to you.

 

Secondly, you will need to find the device ID of your arcade sticks. To do this, find them in device manager, open up their properties. Go to the details tab and find "Hardware IDs" in the pulldown tab. They will look something like: "USB\VID_XXXX&PID_XXXX". Write it down.

 

The format of the script will be thus:

To remove the devices:

"path to devcon\devcon.exe" remove "USB\VID_XXXX&PID_XXXX"

To scan for new devices:

"path to devcon\devcon.exe" rescan

 

Now your controllers should be in the correct order again.

To get this working seamlessly, I'd first recommend writing a windows batch file and trying it manually. When you are sure it's working, you can use Task Scheduler to automate it silently on boot. You will need to run this with Administrator privileges, but Task Scheduler can take care of that for you.

Link to comment
Share on other sites

Ah, thank you Tomkun! As before you've made the instruction crystal clear and easy to follow-- just a couple follow-up questions, and please excuse my ignorance--

 

--in writing a script-- is this done in notepad or a txt program?  So the two lines you listed as the examples will go on two seperate lines?

--I will locate devcon this evening and download it.  Once I do, should I run/install it? Anything I should watch for in regards to the program?

--once the script is written and saved-- how do I run it? 

 

Thank you again! I will experiment with this tonight and let you know how things turn out!

Link to comment
Share on other sites

A windows batch file is just a text file with commands in it renamed with a .bat extension. If you need help writing a batch file, there are many tutorials on the internet, but you can basically just copy and paste the commands I gave you before, changing the relevant parts and it should work.

 

If you get devcon as a standalone executable, you don't need to install it. You can run it from anywhere. If however you get it from the Windows Driver Kit, like I did you will have to install that. Once it's installed though, you can copy it and run it from anywhere you like.

 

To save some time, here is a sample batch file. Just copy it, replace the Hardware ID and save it as "controllerfix.bat". Put it and devcon in the same folder and run it as administrator.

start %~dp0devcon.exe remove "USB\VID_XXXX&PID_XXXX"
start %~dp0devcon.exe rescan

If you are wondering, the "%~dp0" part is a batch file shortcut for the current directory. It's a lot cleaner than typing the full path and allows you to move it to a different folder if you so desire.

Link to comment
Share on other sites

Ok, I got a good part of the way I believe, but I haven't had much luck getting the batch to execute successfully--- let me tell you what I've done:

 

1. Downloaded devcon.exe -- i got the 64x version and I am using windows 8.1.

 

2. I created a txt file that looks like this currently: 

start %~dp0devcon.exe remove "HID\VID_D209&PID_0440&REV_001>&MI_00"
start %~dp0devcon.exe rescan
 
3. renamed the txt file: controllerfix.bat
 
4. put the .bat file in a folder along with devcon.exe
 
5. ran the batch file as administrator
 
After that a quick dialogue box opens and closes.  I loaded hyperspin and I'm still in the same configuration as when I reboot... 
 
How does all of that sound so far?  One thing I might be getting wrong--- under the device manager, when I navigate to the controllers hardware ID it says a number of things: 
HID\VID_D209&PID_0440&REV_001>&MI_00
HID\VID_D209&PID_0440&MI_00
HID_DEVICE_SYSTEM_GAME
HID_DEVICE_UP:0001_U:0004
HID_DEVICE
 
I wasn't sure which of these to use so I used the first one-- then I attempted all of them but wasn't sure to to write it out exactly... if you have any thoughts, please share :)  Thanks for your help!
 
 
 
Link to comment
Share on other sites

Not sure what the problem is exactly. The first thing I'd try though is removing everything after the PID.

i.e:

start %~dp0devcon.exe remove "HID\VID_D209&PID_0440"
start %~dp0devcon.exe rescan

Also, when trying to debug batch files, it's easier to run them from a command prompt so the dialogue box doesn't close afterwards.

Link to comment
Share on other sites

Hmm, I tried the lines you specified and still don't seem to be getting much change from the batch file.  I tried to run it from the command prompt but not quite sure what I'm doing there...  when I try to run the commands from my c:\Users root it gives me a "windows cannot find the file %~dp0devcon.exe"

Not sure if I'm going about this right.  I have the devcon.exe and controllerfix.bat files in a folder on my desktop.  Does it matter where they are?

 

I'll experiment more this weekend and report any progress I might make.  If you have any other thoughts, I'm all ears -- I'll try any kind of experimenting! It's kind of fun -- especially when it leads to a success :D  Thanks for all of your help, TomKun.

 

 
 

Link to comment
Share on other sites

You could try wrapping the command in quotes, in case it is having trouble with a space in your filename. Also, while we are there, let's add a 5 second wait so that it doesn't trip up doing things too quickly.

start "%~dp0devcon.exe" remove "HID\VID_D209&PID_0440"
TIMEOUT /T 5
start "%~dp0devcon.exe" rescan
Link to comment
Share on other sites

Hi Tomkun,

 

Finally back on task and think I've made some headway-- at least I've gotten DevCon and the script to work-- but I have a new dilemna -- curious if your set-up had this same issues and how you overcame them.  This is a bit of an oversight from my first description of what happens when I reboot--- I thought the xbox controllers stayed in place and that the arcade stick took over the top position-- well, part of that is true-- the arcade stick does take the first position, but my xbox controllers reassign themselves to different JoyIDs-- it seems to change with every reboot-- which is maddening!  haha--- I guess the only fix I've found is to turn on the xbox controllers after a reboot-- uninstall each one, uninstall the hub, uninstall the arcade stick-- and then install the hub and turn the controllers on in the order that I want them in. Then it works! But that is not much fun after every reboot. My question is, is there a batch script that can do that?  Is that how it works for your system?  The possible problem I'm wondering is if the individual xbox controllers get different hardware IDs everytime they are reinstalled so would writing a script work? And would the controllers need to be turned on every reboot to run the script and actually have it do anything.  Like, is it possible to unistall a device that is that on.  If you get a moment, let me know your thoughts.  Thanks again for all your help through this process.  It has been helping a lot-- I'm getting closer I think!

Link to comment
Share on other sites

I have never had that problem, so I haven't come up with a solution for it. On my system, the xbox controllers stay in the same place even after reboots, unless they are bumped out of the way by another controller. They don't move by themselves, so I am wondering what is going on there. When you say JoyID, what do you mean exactly? The number they are assigned by Windows or by MAME? If it's the former, you could perhaps try setting them manually by using the JoyID program and seeing if it will stick.

 

The only things that can be done by devcon that I think are relevant are:

 

remove a device

disable a device

enable a device

scan for new devices

 

There is no way to install devices one at a time via a script. However, you could 'fake' it by changing the drivers. Or uninstall and then rescan after each individual device. I don't think you should have to do that though, so I won't explain it yet. Hardware IDs should not change at all, so you should be OK in that regard. 

Link to comment
Share on other sites

I suppose I mean MAME but it seems like the controllers change position in Hyperspin as well-- like the controller labeled controller 2 (with the light in the upper right on the xbox controller) will all of a sudden by JOY1 in mame--- but it will also become my primary controller for controlling Hyperspin-- while, before a reboot-- Controller #1 controlled Hyperspin and was also labeled Joy1 in Mame.  This changes every reboot-- sometimes Controller 3 controls hyperspin (and is joy1 in mame) sometimes controller #4.  I can't seem to peg down what might make it consistent-- other than me uninstalling and installing everything each time. Then things stick. 

 

I experimented around with a different combo of things and so far, this seems like it might work-- I did these all with separate scripts using devcon--

1. Reboot

2. Remove xbox hub (using a script to remove it)

3. scan for devices to find xbox wireless hub (using script)

4. turn on the xbox controllers in the order I want them.

5. Remove arcade stick (using script)

6. Scan again for devices (using script) to get it in the right place (joy5!)

 

Anyway to make those all into one script? Or, I guess I'd need two in order to turn on the controllers. That may be the winning combo! haha,,, god help me. :D

Your patience is an inspiration-- thanks for sticking with me through this!

 

TV

Link to comment
Share on other sites

2,3,5, and 6 are all doable via a single script, but not connecting the controllers one-by-one.

 

Let's take the arcade sticks out of the equation for the time being. The most important thing to do is get the Xbox controllers working. Unplug the arcade sticks and use device manager to remove the entries. Now reboot and see what is happening.

 

Can you see any sort of pattern? With everything else out of the way, the Xbox controllers should always connect in order and be seen in that order in MAME. In your case they aren't, so we have to work out why...

 

Just to eliminate everything else, are you sure that your MAME controller configs are correct, and are you connecting the controllers before starting MAME?

Link to comment
Share on other sites

I ran a few experiments tonight and here is what I discovered-- my system really wants my controllers to be a particular order that it has chosen.  Ok, here is what I did--

 

1. Unplugged the arcade stick and uninstalled it from device manager.  Took it out of the equation-!

 

2. I removed the xbox hub, and installed it again, turning my controllers on in the order I wanted them in.  In mame and hyperspin they worked in that order:

Controller 1 came up as joy1 in MAME and controlled my Hyperspin front end. Controller 2 was joy2, controller 3 was joy3, controller 4 was joy4 -- nice! 

 

3. I exited hyperspin, powered down the controllers, and reboot -- the order remained as it was before the reboot! Another success!

 

4. I exited hyperspin again, powered down the controllers and reboot again---

 

5. Upon start up, I turned the controllers on in the proper order, fired up hyperspin but this time-- it seems they all rearranged themselves--

in mame, Controller#1 was now joy2, Controller#2 was now joy4, Controller#3 was now joy1, and controller#4 was now 3.  Hyperspin was now controller by controller#3.

 

6. I powered down again 2 more times with the same procedure-- the good news is the didn't rearrange anymore-- the bad news is, they stuck as:

Controller#1 as joy2, Controller#2 as joy4, Controller#3 as joy1, and controller#4 as 3.

 

7. I did another reboot again as a test without turning the controllers off this time --- the controllers themselves changed which one was which (now my silver controller was #1, etc) , but the joy assignments remained the same--

Controller#1 as joy2, Controller#2 as joy4, Controller#3 as joy1, and controller#4 as 3.

 

8. and I did a final reboot where I turned the controllers off first, reboot, then turned them on in a different order after the reboot-- the joy assignments remained the same.

 

So what I found out  in doing these tests, is that my system really loves to assign Controller#1 as joy2, Controller#2 as joy4, Controller#3 as joy1, and controller#4 as 3-- and doesn't so much like have them be in the order that they are lighted up to be on the actual controller...

 

All of this was done without the arcade stick in play.  I checked my mame settings and do have player 1 set to joy 1, player 2 set to joy 2, etc--- it looks like everything is right there. 

 

Now I can still get a working order with the arcade stick in the right place by uninstalling the xbox hub upon start up-- scanning for new devices-- turning them on in the order I want them in-- uninstalling the arcade stick-- and scanning again for new devices--- but so far that seems to be the only thing that works...

Link to comment
Share on other sites

ok, well in that case I am stumped too. The Xbox controllers should be detected in the order that you turn them on, regardless of model or colour. I wonder if your silver one has a different hardware ID and that's throwing it off somehow? Are you using the latest drivers for the controllers, or the ones that came with windows?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.


×
×
  • Create New...