def getJoystickAxisType(self, stick: int, axis: int) -> int: """Returns the types of Axes on a given joystick port. :param stick: The joystick port number :param axis: The target axis :returns: An integer that reports type of axis the axis is reporting to be """ if stick < 0 or stick >= self.kJoystickPorts: raise IndexError("Joystick index is out of range, should be 0-%s" % self.kJoystickPorts) with self.cacheDataMutex: return hal.getJoystickAxisType(stick, axis)
def getJoystickAxisType(self, stick: int, axis: int) -> int: """Returns the types of Axes on a given joystick port. :param stick: The joystick port number :param axis: The target axis :returns: An integer that reports type of axis the axis is reporting to be """ if stick < 0 or stick >= self.kJoystickPorts: raise IndexError( "Joystick index is out of range, should be 0-%s" % self.kJoystickPorts ) return hal.getJoystickAxisType(stick, axis)