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: Connecting a USB Arcade Analog Gun with 5k Pots to PC  (Read 1933 times)

0 Members and 1 Guest are viewing this topic.

codeena

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 222
  • Last login:December 03, 2023, 06:23:54 pm
  • This site is cool
Connecting a USB Arcade Analog Gun with 5k Pots to PC
« on: September 08, 2020, 09:12:41 pm »
Hi, I have purchased a USB arcade analog positional/mounted gun to use on my PC. I've interfaced T2 guns using 1up's Dual Strike hack before but this USB gun actually reads as an analog gun in Windows. However, the cursor movement is somewhat jerky/erratic. Besides an issue with the potentiometers, is this normal behavior of using 5k pots on a PC? The guns were connected to the arcade game's PC so I wasn't sure.

If so, I am interested in getting Ultimarc's a-pac to resolve the issue, rather than hacking.

Thanks in advance!

Howard_Casto

  • Idiot Police
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19400
  • Last login:April 21, 2024, 11:59:54 pm
  • Your Post's Soul is MINE!!! .......Again??
    • The Dragon King
Re: Connecting a USB Arcade Analog Gun with 5k Pots to PC
« Reply #1 on: September 08, 2020, 10:54:14 pm »
You do know that in mame and many other emulators, there is a joystick deadzone and you probably need to either reduce that or turn it off completely in the settings.  Other than that your movement should be relatively smooth in game. 

PL1

  • Global Moderator
  • Trade Count: (+1)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 9402
  • Last login:Yesterday at 09:46:22 pm
  • Designated spam hunter
Re: Connecting a USB Arcade Analog Gun with 5k Pots to PC
« Reply #2 on: September 08, 2020, 11:01:39 pm »
the cursor movement is somewhat jerky/erratic. Besides an issue with the potentiometers, is this normal behavior of using 5k pots on a PC?
No, that is not normal behavior.

It is probably caused by bad pots or bad wiring/grounding causing interference or an unstable 5v supply or a bad encoder.

If you have an analog meter or an oscilloscope try testing things like this:
(A digital meter can easily miss the voltage/resistance changes associated with the jerky/erratic motion you describe.)

1. Verify that the voltage between the outer tabs on each pot is a stable 5v.  Red lead on 5v and black lead on ground.
- The needle should be perfectly stable.

2. Leave the black lead on ground and connect the red lead to the wiper (center tab) and see if the voltage responds smoothly as you move the pot.
- If it does, the pot is OK and the problem is with the wiring or encoder.  Skip to step 4.
- If not, continue to step 3.

3. Desolder the wires from the pot and test the pot again to see if the voltage responds smoothly as you move the pot.
- If it responds smoothly, the problem is with the wiring or encoder.
- If not, the pot is bad.  Replace it and start testing again from the beginning.

4. Remove power, ohm out the wires, and check the ground connections.

5. If the wires and grounds are all good, that leaves the encoder.


Scott

Howard_Casto

  • Idiot Police
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19400
  • Last login:April 21, 2024, 11:59:54 pm
  • Your Post's Soul is MINE!!! .......Again??
    • The Dragon King
Re: Connecting a USB Arcade Analog Gun with 5k Pots to PC
« Reply #3 on: September 09, 2020, 01:52:18 am »
All good stuff to check, but I mentioned that it should be smooth in-game because the windows joystick properties often display far more jitter than they should.  I can plug in a brand new joystick and see the cross-hairs dance ever so slightly in joystick properties but it's fine in game.  The dead zone also throws people off for some reason. 

codeena

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 222
  • Last login:December 03, 2023, 06:23:54 pm
  • This site is cool
Re: Connecting a USB Arcade Analog Gun with 5k Pots to PC
« Reply #4 on: September 11, 2020, 01:30:01 am »
Many thanks for the replies!  :cheers: Hope I get it working perfectly soon.

codeena

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 222
  • Last login:December 03, 2023, 06:23:54 pm
  • This site is cool
Re: Connecting a USB Arcade Analog Gun with 5k Pots to PC
« Reply #5 on: September 11, 2020, 06:50:18 pm »
Another question: is it odd that these guns only use two wires per 5k pot (instead of three wires)? thanks

PL1

  • Global Moderator
  • Trade Count: (+1)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 9402
  • Last login:Yesterday at 09:46:22 pm
  • Designated spam hunter
Re: Connecting a USB Arcade Analog Gun with 5k Pots to PC
« Reply #6 on: September 12, 2020, 01:37:23 am »
Another question: is it odd that these guns only use two wires per 5k pot (instead of three wires)? thanks
Two wires per pot indicates that they are currently wired as variable resistors, similar to Atari 2600 paddles.
- An encoder for this setup (i.e. your current encoder) translates the measured resistance into a digital position.
- It's slightly more difficult to calibrate for a smooth, full range of motion with this setup.

If possible, it's better to use a three wire potentiometer setup that acts as a voltage divider.
- An encoder for this setup (i.e. an A-Pac encoder) translates the measured voltage into a digital position.

If you plan to use an A-Pac encoder, you need to use the three wire configuration so the A-Pac can auto-sense the pots when it boots up.


Scott

BadMouth

  • Trade Count: (+6)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 9226
  • Last login:Yesterday at 09:54:06 am
  • ...
Re: Connecting a USB Arcade Analog Gun with 5k Pots to PC
« Reply #7 on: September 12, 2020, 06:08:20 am »
I've had similar issues using original 5k pots with generic interfaces.  Replacing them with 100k pots fixed the issue, but that may not work if you are only using 2 wires (going off resistance instead of voltage).
The cursor would move in chunks, as if the 5k pot didn't offer enough resolution for the interface.

Supposedly it's not an issue with the A-Pac, but I don't have any first hand experience with it.

Here are some comments about tweaking MAME that I've posted elsewhere: (when will forum search function be fixed?!)
1.  Calibrate the positional gun in windows by pointing it along the edges of the screen.
2.  In mame.ini set the dead zone to zero.
3.  In mame.ini set the saturation to 1 (100%)
4.  Calibrate the gun in the game's service menu
5.  Adjust the sensitivity under analogue controls in MAME's in-game menu until the crosshairs don't lag behind the gun movement.
    (there is only ONE sensetivity setting, ignore all settings that include the word DIGITAL)

codeena

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 222
  • Last login:December 03, 2023, 06:23:54 pm
  • This site is cool
Re: Connecting a USB Arcade Analog Gun with 5k Pots to PC
« Reply #8 on: September 12, 2020, 12:34:13 pm »
Thanks again for the replies. In my limited experience with using the MS Dual Strike hack in 5k pots (six different controllers), this is the first time I came across only two wires per pot but I thought they should work fine with the encoder card since these Global VR guns were connected to a standard PC in the original game. Maybe these USB guns require additional power?

Either way, I did actually order an A-Pac the other day. I did prefer to use the gun's encoder card to save money and time, but mostly so I can keep the LED that displays the bullets and eventually figure out how to power the recoil. However, I tested that the LED still works independently when using a different controller in game.