Code for interfacing with a gamepad/joystick to get axis values