Hello, We need to read the status of joystick inputs to all connected
joysticks in the sim. Prepar3D offers ‘SimConnect_RequestJoystickDeviceInfo()’
which returns a structure with complete information on each connected
joystick. If this cannot be implemented, is there any alternative way to
receive this info?
Hello @simfan You can take a look at the sample
JoystickInput
and adapt it to yours needs. Regards, Boris
Hello @Boris I understand (and of course, I have looked at this before) - the
question was regarding the enumeration of joysticks currently connected to the
sim - in other words, how can we know what HID device the joystick: part
belongs to. This should be exposed properly to match the proper hardware. I
hope this is clear enough now.
Hello @simfan , In this case, no, there is no way at the moment to get the
enumeration of the devices connected to the sim. Regards, Boris
Hi @Boris would you therefore agree that the JoystickInput sample (and all
the mappings of joystick controls) are a bit useless if we don’t know in
advance what joystick maps where? Most of hardware-using customers are not
just using a single joystick, they usually add rudder pedals or thrust levers
or whatnot, so the order these appear is not known in advance. As a result, we
cannot really know what events will get assigned to what joystick. I would say
that this is a shortcoming that needs addressing sooner rather than later -
would you agree with me? Regards,
Hello @simfan , If you think you need this to be added, you can make a new
IDEA post about it Regards,
Boris
Hi @Boris - can you please explain how the sample JoystickInput is supposed
to work? Which joystick corresponds to position :0 if I have two joysticks
connected? Will it always be detected a certain way? What if I connect another
joystick while MSFS is running? At the moment, the sim detects and asks the
user what they want to do with the inputs - how does the sample handle that?
Is joystick:0 changed? does it always stay the same?