Monday, October 24, 2016

HOW TO: PIUIO with Stepmania 5 or OpenITG in Linux and Windows



Please follow this guide to install PIUIO before continuing...

Once you have installed the drivers for PIUIO on your system, you will need the software to be able to interact with your PIU drivers.


In Windows

1. Download and install IO2Key here:
https://mega.nz/#!INFUDBqa!Br-zZexEgOaVCDNqUzPQmoVi3jg0X5X4ZNSKxm-P1GQ
Video Help: https://www.youtube.com/watch?v=xo5m9dlNFfY

IO2Key maps the inputs from PIUIO to standard keyboard keys. You can then easily map the keyboard keys in Stepmania or OpenITG.



Linux - Stepmania 5

1. Open the following file:

Preferences.ini
(Located in the users home directory. NOTE: Stepmania needs to be ran for the first time for these files to appear!)

TIP: Make sure Static.ini does NOT contain this line as it'll override the setting if so. Alternatively, you can place the following in static.ini to override this. Your choice!

2. Find the line that begins with: "InputDrivers=". Modify this line so that the value is empty (auto-probe).

I.e.
"InputDrivers=XXXXXXX" should now read:
"InputDrivers=". (No spaces and case sensitive)


3. Still within this file, find the line that begins with: "LightsDriver=" Modify this line so that it begins with PIUIO_Leds after the equal sign.

I.e.
"LightsDriver=" should now read:
"LightsDriver=PIUIO_Leds". (No spaces and case sensitive)


This tells Stepmania that we want to use PIUIO to manage the lights for the arcade cabinet.


Linux - OpenITG

As OpenITG supports PIUIO out of the box, the complete setup is rather simple...

1. Open the following file:


Stepmania.ini (Located in the Data folder)

TIP: Make sure Static.ini does NOT contain this line as it'll override the setting if so. Alternatively, you can place the following in static.ini to override this. Your choice!

2. Find the line that begins with: "InputDrivers=". Modify this line so that it includes PIUIO.

I.e.
"InputDrivers=x11" should now read:
"InputDrivers=x11,PIUIO". (No spaces and case sensitive)

This tells OpenITG that we want to add PIUIO as an optional input driver IN ADDITION to x11 (A standard linux keyboard) 

3. Still within this file, find the line that begins with: "LightsDriver=" Modify this line so that it begins with PIUIO after the equal sign.

I.e.
"LightsDriver=" should now read:
"LightsDriver=PIUIO". (No spaces and case sensitive)

This tells OpenITG that we want to use PIUIO to manage the lights for the arcade cabinet.



BONUS ANNOYANCE: Disable Floor Panels from Selecting Songs in the Song Menu Screen

1. Open the following file depending on your engine:
OpenITG - Stepmania.ini (Located in the Data folder)
Stepmania 5 - Preferences.ini (Located in AppData for the current user)

TIP: Make sure Static.ini does NOT contain this line as it'll override the setting if so. Alternatively, you can place the following in static.ini to override this. Your choice!

2. Find the line that begins with: "OnlyDedicatedMenuButtons="

Modify this line so that it reads: "OnlyDedicatedMenuButtons=1"

Installing PIUIO Drivers for Windows


Need to install on Linux instead? Click here: http://s34nvideo.blogspot.com/2018/01/howto-install-piuio-drivers-in-linux.html




If you're building an MK6/MK9 for Pump It Up, or, OpenITG for In The Groove, or, simply a Stepmania setup... You may have opted for using a PIUIO to communicate with your arcade cabinet. If running a distribution of Linux, then installing PIUIO is a very simple task. However, if your are running Windows, you will need to build the driver yourself using Libusb.

Installing PIUIO on Windows
1. Download libusb-win32 here: http://sourceforge.net/projects/libusb-win32/ libusb-win32 is a port of the USB library libusb-0.1 (http://sf.net/projects/libusb/) for 32/64bit Windows (2k, XP, 2003, Vista, Win7, 2008; 98SE/ME for v0.1.12.2). The library allows user space applications to access many USB device on Windows.

2. Unzip libusb-win32 and run inf-wizard.exe (This will build a Windows driver for PIUIO).

3. Connect your PIUIO to your computer via USB (The fake PCI slot on the PIUIO is merely to sit it in a desktop computer properly, it does not communicate with a PC via PCI in any way at all.). To power the PIUIO, it will need power via Molex cable. If using a laptop, then you can use an old PC ATX power supply to power the PIUIO board via the molex connector. You will need to jump a couple of pins in the ATX connector to start the power supply once it's plugged in (This acts like a power switch on a desktop computer to start the power supply! More info: http://www.instructables.com/id/How-to-power-up-an-ATX-Power-Supply-without-a-PC/).

4. Hit next in inf-wizard.exe. Within the list, you are looking for a USB device called EZ-USB FX2... This is the PIUIO! Select it in the list, then hit next twice. We can now build a windows driver! Choose where you want to save the driver to (The driver is an INF file).

5. You can then install the PIUIO driver via inf-wizard.exe on the last screen, or, within Device Manager.


Getting PIUIO to detect within Stepmania 5 or OpenITG
Click here to learn how to use PIUIO with Stepmania 5 / OpenITG.