Add support for the 'Microsoft SideWinder 3D Pro' joystick
[fg:toms-fgdata.git] / Input / Joysticks / Microsoft / sidewinder-3d-pro.xml
1 <?xml version="1.0"?>
2
3 <!--
4 ************************************************************************
5 * Bindings for Microsoft SideWinder Force Feed joystick.
6 *
7 *
8 * Axis 0: ailerons
9 * Axis 1: elevator
10 * Axis 2 (twist): rudder
11 * Axis 3: throttle
12 * Axes 6 and 7 (hat): view direction
13 *
14 * Button 0: all brakes
15 * Button 1: elevator trim up
16 * Button 2: elevator trim down
17 * Button 3: center view
18 * Button 4: flap up
19 * Button 5: flap down
20 * Button 6: right brake only
21 * Button 7: left brake only
22 ************************************************************************
23 -->
24
25 <PropertyList>
26
27  <name>Microsoft SideWinder 3D Pro</name>
28
29  <axis n="0">
30   <desc>Aileron</desc>
31   <binding>
32    <command>property-scale</command>
33    <property>/controls/flight/aileron</property>
34    <squared type="bool">true</squared>
35   </binding>
36  </axis>
37
38  <axis n="1">
39   <desc>Elevator</desc>
40   <binding>
41    <command>property-scale</command>
42    <property>/controls/flight/elevator</property>
43    <factor type="double">-1.0</factor>
44    <squared type="bool">true</squared>
45   </binding>
46  </axis>
47
48  <axis n="2">
49   <desc>Rudder</desc>
50   <binding>
51    <command>property-scale</command>
52    <property>/controls/flight/rudder</property>
53    <factor type="double">1.0</factor>
54   </binding>
55  </axis>
56
57  <axis n="3">
58   <desc>Throttle</desc>
59   <binding>
60    <command>property-scale</command>
61    <property>/controls/engines/engine[0]/throttle</property>
62    <offset type="double">-1.0</offset>
63    <factor type="double">-0.5</factor>
64   </binding>
65   <binding>
66    <command>property-scale</command>
67    <property>/controls/engines/engine[1]/throttle</property>
68    <offset type="double">-1.0</offset>
69    <factor type="double">-0.5</factor>
70   </binding>
71   <binding>
72    <command>property-scale</command>
73    <property>/controls/engines/engine[2]/throttle</property>
74    <offset type="double">-1.0</offset>
75    <factor type="double">-0.5</factor>
76   </binding>
77   <binding>
78    <command>property-scale</command>
79    <property>/controls/engines/engine[3]/throttle</property>
80    <offset type="double">-1.0</offset>
81    <factor type="double">-0.5</factor>
82   </binding>
83   <binding>
84    <command>property-scale</command>
85    <property>/controls/engines/engine[4]/throttle</property>
86    <offset type="double">-1.0</offset>
87    <factor type="double">-0.5</factor>
88   </binding>
89   <binding>
90    <command>property-scale</command>
91    <property>/controls/engines/engine[5]/throttle</property>
92    <offset type="double">-1.0</offset>
93    <factor type="double">-0.5</factor>
94   </binding>
95   <binding>
96    <command>property-scale</command>
97    <property>/controls/engines/engine[6]/throttle</property>
98    <offset type="double">-1.0</offset>
99    <factor type="double">-0.5</factor>
100   </binding>
101   <binding>
102    <command>property-scale</command>
103    <property>/controls/engines/engine[7]/throttle</property>
104    <offset type="double">-1.0</offset>
105    <factor type="double">-0.5</factor>
106   </binding>
107  </axis>
108
109   <axis n="4">
110    <desc>View Direction</desc>
111    <low>
112     <repeatable>true</repeatable>
113     <binding>
114      <command>property-adjust</command>
115      <property>/sim/current-view/goal-heading-offset-deg</property>
116      <step type="double">1.0</step>
117     </binding>
118    </low>
119    <high>
120     <repeatable>true</repeatable>
121     <binding>
122      <command>property-adjust</command>
123      <property>/sim/current-view/goal-heading-offset-deg</property>
124      <step type="double">-1.0</step>
125     </binding>
126    </high>
127   </axis>
128
129   <axis n="5">
130    <desc>View Elevation</desc>
131    <low>
132     <repeatable>true</repeatable>
133     <binding>
134      <command>property-adjust</command>
135      <property>/sim/current-view/goal-pitch-offset-deg</property>
136      <step type="double">1.0</step>
137     </binding>
138    </low>
139    <high>
140     <repeatable>true</repeatable>
141     <binding>
142      <command>property-adjust</command>
143      <property>/sim/current-view/goal-pitch-offset-deg</property>
144      <step type="double">-1.0</step>
145     </binding>
146    </high>
147   </axis>
148
149  <button n="0">
150   <desc>Brakes</desc>
151   <binding>
152    <command>property-assign</command>
153    <property>/controls/gear/wheel[0]/brake</property>
154    <value type="double">1.0</value>
155   </binding>
156   <binding>
157    <command>property-assign</command>
158    <property>/controls/gear/wheel[1]/brake</property>
159    <value type="double">1.0</value>
160   </binding>
161   <binding>
162    <command>property-assign</command>
163    <property>/controls/gear/wheel[2]/brake</property>
164    <value type="double">1.0</value>
165   </binding>
166   <mod-up>
167    <binding>
168     <command>property-assign</command>
169     <property>/controls/gear/wheel[0]/brake</property>
170     <value type="double">0.0</value>
171    </binding>
172    <binding>
173     <command>property-assign</command>
174     <property>/controls/gear/wheel[1]/brake</property>
175     <value type="double">0.0</value>
176    </binding>
177    <binding>
178     <command>property-assign</command>
179     <property>/controls/gear/wheel[2]/brake</property>
180     <value type="double">0.0</value>
181    </binding>
182   </mod-up>
183  </button>
184
185  <button n="1">
186   <desc>Elevator trim up</desc>
187   <repeatable type="bool">true</repeatable>
188   <binding>
189    <command>property-adjust</command>
190    <property>/controls/flight/elevator-trim</property>
191    <step type="double">0.001</step>
192   </binding>
193  </button>
194
195  <button n="2">
196   <desc>Elevator trim down</desc>
197   <repeatable type="bool">true</repeatable>
198   <binding>
199    <command>property-adjust</command>
200    <property>/controls/flight/elevator-trim</property>
201    <step type="double">-0.001</step>
202   </binding>
203  </button>
204
205  <button n="3">
206   <desc>Center View</desc>
207   <repeatable type="bool">false</repeatable>
208   <binding>
209    <command>property-assign</command>
210    <property>/sim/current-view/goal-heading-offset-deg</property>
211    <value type="double">0.0</value>
212   </binding>
213   <binding>
214    <command>property-assign</command>
215    <property>/sim/current-view/goal-pitch-offset-deg</property>
216    <value type="double">0.0</value>
217   </binding>
218  </button>
219
220  <button n="4">
221   <desc>Flaps down</desc>
222   <repeatable>false</repeatable>
223   <binding>
224    <command>property-adjust</command>
225    <property>/controls/flight/flaps</property>
226    <step type="double">-0.34</step>
227   </binding>
228  </button>
229
230  <button n="5">
231   <desc>Flaps up</desc>
232   <repeatable>false</repeatable>
233   <binding>
234    <command>property-adjust</command>
235    <property>/controls/flight/flaps</property>
236    <step type="double">0.34</step>
237   </binding>
238  </button>
239
240  <button n="6">
241   <desc>Right brake</desc>
242   <binding>
243    <command>property-assign</command>
244    <property>/controls/gear/wheel[1]/brake</property>
245    <value type="double">1.0</value>
246   </binding>
247   <mod-up>
248    <binding>
249     <command>property-assign</command>
250     <property>/controls/gear/wheel[1]/brake</property>
251     <value type="double">0.0</value>
252    </binding>
253   </mod-up>
254  </button>
255
256  <button n="7">
257   <desc>Left brake</desc>
258   <binding>
259    <command>property-assign</command>
260    <property>/controls/gear/wheel[0]/brake</property>
261    <value type="double">1.0</value>
262   </binding>
263   <mod-up>
264    <binding>
265     <command>property-assign</command>
266     <property>/controls/gear/wheel[0]/brake</property>
267     <value type="double">0.0</value>
268    </binding>
269   </mod-up>
270  </button>
271
272 </PropertyList>