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: Auto joystick 4/8 way switching, no reason not to do it  (Read 6255 times)

0 Members and 1 Guest are viewing this topic.

darthpaul

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 447
  • Last login:November 23, 2022, 07:34:53 pm
  • Join, It's your duty
Auto joystick 4/8 way switching, no reason not to do it
« on: July 23, 2011, 12:30:51 pm »
Anyone who is using the Ultimarc Mag-stik joystick now has no reason not to convert these to automatic switching between 4 and 8 way. If you had the ability to construct a cabinet this should be a breeze.
Below is how I did it, I’m by no means an expert on any of this, so if anyone has any questions, I’ll do my best to answer them.  
The first thing you need to do is construct the linkage for the servo, these are the servos I used http://cgi.ebay.com/4x-MG995-Digital-Metal-Gear-Servo-FUTABA-JR-RC-Car-/290495785226?_trksid=p5197.m7&_trkparms=algo%3DLVI%26itu%3DUCI%26otn%3D4%26po%3DLVI%26ps%3D63%26clkid%3D1434434537286449732 to attach to the Ultimarc Mag-stik http://www.ultimarc.com/controls.html .Anyone who has one of these may notice the lever to change the stick from 4 to 8 way has some resistance to it. I took the stick apart and filed down the plastic hump that creates the resistance(sorry no pictures), don’t worry; the servo will prevent anything from moving. I used some flat 1/16” x ½” aluminum bar stock for the linkage, in addition to filing the hump down I also had to drill a hole through the switching lever to attach the linkage to, you can’t test the linkage until you get the servo working, which is the next step.
Next you are going to need a controller to control the servos, this is what I used http://www.pololu.com/catalog/category/12 , I used the 6 channel one.
Once you have your servos, you need to know their power requirements, the ones I used, require up to 6v, I had an old pencil sharpener that used a 6v power source but a 5v power source should work as well, it should be rated for a minimum of 1 amp.
Follow the directions when hooking up the power to the controller, there are only two wires to solder, the positive and negative and you will need a USB cable to attach the controller to your PC, all this is on the POLOLU website.
Now that you have constructed your linkage and attached it to your joystick and servo you have to figure out how much the servo must turn in order to move the lever from 4 to 8 way and back. Attach the usb cable to the servo controller and your PC and plug in your power source and plug in your servo to the controller, you may hear the servo react when you do this. Open up the Maestro Control Center, now it’s just a matter of trial and error setting the min and max setting which is done on the Channel Setting page. Then go to the Status page, move the sliders to see how far the servo is turning, the settings I used are in the pictures below but I promise yours will be different, if you hear the servo chattering that means you have gone a little too far and need to back off a little, it takes a little while but it’s not hard to figure out.
I didn’t write a Script like someone else had done thanks to DaOld Man’s new Joychoose Plug-in, all I had to do was write two batch files using the usccmd command. The usccmd is part of the Maestro Control Center download, it allows you to issue simple commands to the servo, like moving the servos.
These are the batch files I created;
First 4way
@echo off
usccmd --servo 1, 1000
usccmd --servo 2, 1000
usccmd --servo 3, 1000

8way
@echo off
usccmd --servo 1, 10000
usccmd --servo 2, 10000
usccmd --servo 3, 10000

The one thing you have to remember when using this command is, you have to multiply whatever you entered as your min and max values in the Maestro Control Center by 4. The nice thing I found out is, you don’t need to use the exact amount, the servo won’t go past whatever you entered in the Control Center, so you could use a small number for you min value and a very large number for you max value.
To create a batch file open notebook and enter the usccmd commands like my example, you may have to change the servo number(s)(I used servos 1, 2 and 3) and the amount you want the servo to move.
There should be a space after usccmd and 2 dash lines before servo. Save the file as All Files and add .bat to the name, mine are 4way.bat and 8way.bat. If you try and run these files and the servo moves, you got it right.
I would like to thank Ken "DaOld Man", for all his assistance, without his help and new plug-in, I wouldn't have been able to do this.
« Last Edit: August 04, 2011, 09:54:25 pm by darthpaul »
"You don't know the power of the Dark Side"
Automated Cabinet
Nintendo Pi
PiCubed

Bender

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1919
  • Last login:November 28, 2016, 08:12:21 pm
    • Happ to Tron Conversion tutorial
Re: Auto joystick 4/8 way switching, no reason not to do it
« Reply #1 on: July 23, 2011, 06:47:38 pm »
could you post some Pics or video or even better make a tutorial
This is a great idea and I'm sure a lot of people would benefit from seeing how you did it
Thanks!

mgb

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3499
  • Last login:February 21, 2024, 06:18:13 pm
  • North East, US
Re: Auto joystick 4/8 way switching, no reason not to do it
« Reply #2 on: July 24, 2011, 09:48:42 pm »
Darthpaul, thanks for the info. I've been loosely following the other thread about auto switching the sticks. I kinda didn't want get into doing it but I'm really leaning toward doing it. I'm using Sanwa JLWs and this would definately make it better.
If you are able to post some pics and videos, that would be awesome.
thanks

danny_galaga

  • Grand high prophet of the holy noodle.
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 8437
  • Last login:Today at 10:23:15 pm
  • because the mail never stops
    • dans cocktail lounge
Re: Auto joystick 4/8 way switching, no reason not to do it
« Reply #3 on: July 25, 2011, 03:15:54 am »
Anyone who is using the Ultimarc Mag-stik joystick now has no reason not to convert these to automatic switching between 4 and 8 way. If you had the ability to construct a cabinet this should be a breeze.


No, you are wrong. there are a number of us who are good with our hands, but if we see something like 'batch file' our eyes just glaze over...

Good work though. Thanks for posting  :)


ROUGHING UP THE SUSPECT SINCE 1981

BobA

  • Trade Count: (+14)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5943
  • Last login:July 11, 2018, 09:52:14 pm
  • What Me Worry?
Re: Auto joystick 4/8 way switching, no reason not to do it
« Reply #4 on: July 25, 2011, 09:22:08 am »
Can you explain why there are 3 servos?   Are you changing the 4/8 on 3 joysticks?

darthpaul

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 447
  • Last login:November 23, 2022, 07:34:53 pm
  • Join, It's your duty
Re: Auto joystick 4/8 way switching, no reason not to do it
« Reply #5 on: July 31, 2011, 03:19:03 pm »
I am using three servos because I have rotating control panels and one panel is for a single player and the other panel is for two players.
"You don't know the power of the Dark Side"
Automated Cabinet
Nintendo Pi
PiCubed

darthpaul

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 447
  • Last login:November 23, 2022, 07:34:53 pm
  • Join, It's your duty
Re: Auto joystick 4/8 way switching, no reason not to do it
« Reply #6 on: July 31, 2011, 03:27:00 pm »


No, you are wrong. there are a number of us who are good with our hands, but if we see something like 'batch file' our eyes just glaze over...

Good work though. Thanks for posting  :)
[/quote]
Trust me, I never wrote a batch file in my life until I did this and they don't get any simpler than the ones I created, just use DaOld Man's plugin and follow what I wrote and your biggest problem will be creating the linkage.
"You don't know the power of the Dark Side"
Automated Cabinet
Nintendo Pi
PiCubed

darthpaul

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 447
  • Last login:November 23, 2022, 07:34:53 pm
  • Join, It's your duty
Re: Auto joystick 4/8 way switching, no reason not to do it
« Reply #7 on: July 31, 2011, 03:40:10 pm »
Darthpaul, thanks for the info. I've been loosely following the other thread about auto switching the sticks. I kinda didn't want get into doing it but I'm really leaning toward doing it. I'm using Sanwa JLWs and this would definately make it better.
If you are able to post some pics and videos, that would be awesome.
thanks
I'll see what I can do about some pics but the pics in this thread couldn't be clearer. http://forum.arcadecontrols.com/index.php?topic=104762.40
Trust me, this is the way to go, especially if you are not going to be the only one playing. My goal is to have an almost completely automated cabinet. In addition to the joysticks, I also have an automated rotating monitor using DaOld Man's Startcom plugin and am currently working to automate my rotating control panels, which has turned into a major project and headache. 
"You don't know the power of the Dark Side"
Automated Cabinet
Nintendo Pi
PiCubed