2001-06-04 19:48:08 +00:00
|
|
|
<?xml version="1.0"?>
|
|
|
|
<!--
|
|
|
|
Joystick binding definitions.
|
|
|
|
|
|
|
|
This file is included by preferences.xml, and uses the context of its
|
|
|
|
inclusion point; that means that you need to prepend "/input/joysticks"
|
|
|
|
to all property names.
|
|
|
|
|
|
|
|
This file defines primary flight-control bindings for a simple
|
|
|
|
three-axis, three-button joystick, as follow:
|
|
|
|
|
|
|
|
axis 0 (left-right): aileron
|
|
|
|
axis 1 (forward-backward): elevator
|
|
|
|
axis 2 (slider): throttle
|
|
|
|
button 0 (trigger): brakes
|
|
|
|
button 1: trim up
|
|
|
|
button 2: trim down
|
|
|
|
|
|
|
|
If you have a more sophisticated joystick, there might be more axes
|
|
|
|
available; on my joystick, axis 2 is actually a twist axis (usually
|
|
|
|
for the rudder), while axis 3 is the throttle. There are also two
|
|
|
|
axes for the hat switch, and several more buttons.
|
|
|
|
-->
|
|
|
|
|
|
|
|
<PropertyList>
|
|
|
|
|
|
|
|
<js>
|
|
|
|
|
|
|
|
<axis n="0">
|
|
|
|
<desc>Aileron</desc>
|
|
|
|
<binding>
|
|
|
|
<command>property-scale</command>
|
|
|
|
<property>/controls/aileron</property>
|
|
|
|
</binding>
|
|
|
|
</axis>
|
|
|
|
|
|
|
|
<axis n="1">
|
|
|
|
<desc>Elevator</desc>
|
|
|
|
<binding>
|
|
|
|
<command>property-scale</command>
|
|
|
|
<property>/controls/elevator</property>
|
|
|
|
<factor type="double">-1.0</factor>
|
|
|
|
</binding>
|
|
|
|
</axis>
|
|
|
|
|
|
|
|
<axis n="2">
|
|
|
|
<desc>Throttle</desc>
|
|
|
|
<binding>
|
|
|
|
<command>property-scale</command>
|
|
|
|
<property>/controls/throttle</property>
|
|
|
|
<offset type="double">-1.0</offset>
|
|
|
|
<factor type="double">-0.5</factor>
|
|
|
|
</binding>
|
|
|
|
</axis>
|
|
|
|
|
|
|
|
<button n="0">
|
|
|
|
<desc>Brakes</desc>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/brakes[0]</property>
|
|
|
|
<value type="double">1.0</value>
|
|
|
|
</binding>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/brakes[1]</property>
|
|
|
|
<value type="double">1.0</value>
|
|
|
|
</binding>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/brakes[2]</property>
|
|
|
|
<value type="double">1.0</value>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/brakes[0]</property>
|
|
|
|
<value type="double">0.0</value>
|
|
|
|
</binding>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/brakes[1]</property>
|
|
|
|
<value type="double">0.0</value>
|
|
|
|
</binding>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/brakes[2]</property>
|
|
|
|
<value type="double">0.0</value>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="1">
|
|
|
|
<desc>Elevator trim up</desc>
|
|
|
|
<repeatable>true</repeatable>
|
|
|
|
<binding>
|
|
|
|
<command>property-adjust</command>
|
|
|
|
<property>/controls/elevator-trim</property>
|
2001-06-04 20:08:24 +00:00
|
|
|
<step type="double">0.001</step>
|
2001-06-04 19:48:08 +00:00
|
|
|
</binding>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="2">
|
|
|
|
<desc>Elevator trim down</desc>
|
|
|
|
<repeatable>true</repeatable>
|
|
|
|
<binding>
|
|
|
|
<command>property-adjust</command>
|
|
|
|
<property>/controls/elevator-trim</property>
|
2001-06-04 20:08:24 +00:00
|
|
|
<step type="double">-0.001</step>
|
2001-06-04 19:48:08 +00:00
|
|
|
</binding>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
</js>
|
|
|
|
|
|
|
|
</PropertyList>
|
|
|
|
|
|
|
|
<!-- end of joysticks.xml -->
|