Last active
August 18, 2020 11:51
-
-
Save alexrudnick/8079313 to your computer and use it in GitHub Desktop.
Shell script to get a HitBox fightstick to talk work on Linux. Works for me on Ubuntu. Modified slightly from this script here: http://pastebin.com/mkbuyYdR
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Polls Toodles PC/PS3 Cthulhu controller, preventing it from entering XBox 360 | |
# mode. Run this script as root, then plug in the controller. | |
DEV_DIR=/dev/input/by-id | |
DEV_NAME=usb-Toodles_2008_HitBox_Edition_Cthulhu+-event-joystick | |
echo "Please connect PC/PS3 Cthulhu now." | |
# Loop indefinitely until Cthulhu controller is detected | |
until [ -a $DEV_DIR/$DEV_NAME ]; do | |
DO_NOTHING="" | |
done | |
echo " - PC/PS3 Cthulhu detected. Ensuring connection..." | |
# Have Cthulhu scream into the void for a couple of seconds to ensure connection | |
cat $DEV_DIR/$DEV_NAME > /dev/null & CAT=$! | |
sleep 2 | |
kill $CAT | |
echo " - PC/PS3 Cthulhu connected!" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment