1
0
Fork 0

Add the Top-Gun-Fox2-Pro USB joystick, modify the Macally iStick USB joystick and update axis bindings to allow the Saitek X45 to work under Max OSX.

This commit is contained in:
ehofman 2004-05-06 16:12:32 +00:00
parent 69b9fad5d5
commit 3654ccb65f
4 changed files with 371 additions and 18 deletions

View file

@ -24,7 +24,12 @@ Layout:
<name>MacALLY USB Joystick </name>
<axis n="0">
<axis>
<number>
<unix>0</unix>
<windows>0</windows>
<mac>0</mac>
</number>
<desc>Aileron</desc>
<dead-band type="double">0.02</dead-band>
<binding>
@ -35,7 +40,12 @@ Layout:
</binding>
</axis>
<axis n="1">
<axis>
<number>
<unix>1</unix>
<windows>1</windows>
<mac>1</mac>
</number>
<desc>Elevator</desc>
<dead-band type="double">0.02</dead-band>
<binding>
@ -46,17 +56,77 @@ Layout:
</binding>
</axis>
<axis n="2">
<axis>
<number>
<unix>2</unix>
<windows>2</windows>
<mac>2</mac>
</number>
<desc>Throttle</desc>
<!--
<binding>
<command>nasal</command>
<script>controls.throttleAxis()</script>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
-->
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[0]/throttle</property>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[1]/throttle</property>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[2]/throttle</property>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[3]/throttle</property>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[4]/throttle</property>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[5]/throttle</property>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[6]/throttle</property>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[7]/throttle</property>
<offset type="double">+0.5</offset>
<factor type="double">-2.0</factor>
</binding>
</axis>
<axis n="3">
<axis>
<number>
<unix>3</unix>
<windows>3</windows>
<mac>3</mac>
</number>
<desc>Rudder</desc>
<dead-band type="double">0.02</dead-band>
<binding>
@ -68,6 +138,25 @@ Layout:
</axis>
<!--
<axis>
<number>
<unix>4</unix>
<windows>4</windows>
<mac>4</mac>
</number>
<desc>Rudder</desc>
<dead-band type="double">0.02</dead-band>
<binding>
<command>property-scale</command>
<property>/controls/flight/rudder</property>
<offset type="double">0.0</offset>
<factor type="double">1.0</factor>
</binding>
</axis>
-->
<button n="0">
<desc>Brakes</desc>
<binding>
@ -95,11 +184,11 @@ Layout:
</button>
<button n="1">
<desc>Elevator trimup</desc>
<desc>Elevator trim up</desc>
<repeatable>true</repeatable>
<binding>
<command>property-adjust</command>
<property>/controls/flight/flaps</property>
<property>/controls/flight/elevator-trim</property>
<step type="double">0.001</step>
</binding>
</button>

View file

@ -10,17 +10,18 @@ Only a few stick controls have been mapped here:
+ Stick button "A": Gear toggle
+ Stick button "C": Reset view (hackish)
Linux/Windows Axis Numbers:
0 Roll (positive == right)
1 Pitch (positive == down/back/nose-up)
2/5 top "rotary dial" on the throttle (positive == CCW)
3 Rocker switch ("rudder" control) on the throttle (positive == right)
4/2 Throttle (positive == back/down/idle)
5/4 Bottom "rotary dial" on the throttle (positive == CW)
6 Lower right hat horizontal axis (positive == right)
7 Lower right hat vertical axis (positive == down)
Linux/Windows/Mac Axis Numbers:
0 Roll (positive == right)
1 Pitch (positive == down/back/nose-up)
2/5/4 top "rotary dial" on the throttle (positive == CCW)
3 Rocker switch ("rudder" control) on the throttle (positive == right)
4/2/2 Throttle (positive == back/down/idle)
5/4/? Bottom "rotary dial" on the throttle (positive == CW)
Strange this axis doesn't seem to exist on Mac OS X!
6/6/5 Lower right hat horizontal axis (positive == right)
7/7/6 Lower right hat vertical axis (positive == down (Mac positive is UP))
Button Numbers (Identical b/w Linux/Windows):
Button Numbers (Identical b/w Linux/Windows/Mac):
0 Trigger
1 Stick top "A" switch
2 Stick top "B" switch
@ -51,6 +52,7 @@ Button Numbers (Identical b/w Linux/Windows):
$Id$
-->
<PropertyList>
<name>Saitek X45</name>
<name>Saitek Saitek X45</name>
<name>Saitek X45 Flight Controller USB</name>
@ -98,6 +100,11 @@ $Id$
<!-- View Direction Hat -->
<axis n="6">
<number>
<unix>6</unix>
<windows>6</windows>
<mac>5</mac>
</number>
<desc>View Direction</desc>
<low>
<repeatable>true</repeatable>
@ -115,8 +122,13 @@ $Id$
</high>
</axis>
<axis n="7">
<axis>
<desc>View Elevation</desc>
<number>
<unix>7</unix>
<windows>7</windows>
<mac>6</mac>
</number>
<low>
<repeatable>true</repeatable>
<binding>
@ -138,6 +150,7 @@ $Id$
<number>
<unix>4</unix>
<windows>2</windows>
<mac>2</mac>
</number>
<binding>
<command>nasal</command>
@ -162,6 +175,7 @@ $Id$
<number>
<unix>5</unix>
<windows>4</windows>
<!-- <mac>???</mac> -->
</number>
<binding>
<command>nasal</command>

View file

@ -0,0 +1,249 @@
<?xml version="1.0"?>
<!--
************************************************************************
*
* Bindings or Thrustmaster Top Gun Fox 2 Pro USB joystick (see joysticks.xml in fgfsbase dir)
*
*
* Axis 0: ailerons
* Axis 1: elevator
* Axis 2: rudder (twistable stick)
* Axis 3: throttle
* Axis 4: Horizontal Hat
* Axis 5: Vertical Hat
*
* Button 0: (Trigger) elevator trim down
* Button 1: (yellow and black button) all brakes
* Button 2: (side button above trigger) gear up/down
* Button 3: (right button, next to yellow and black button) elevator trim up
* Button 4: (outside bottom button) flap up
* Button 5: (middle bottom button) center rudder
* Button 6: (inside bottom button) flap down
* Borrowed heavily from sidewinder.xml
* Thank you, sidewinder.xml!
************************************************************************
-->
<PropertyList>
<name>Top Gun Fox 2 Pro </name>
<axis>
<number>
<unix>0</unix>
<windows>0</windows>
<mac>0</mac>
</number>
<desc>Aileron</desc>
<dead-band type="double">0.02</dead-band>
<binding>
<command>property-scale</command>
<property>/controls/flight/aileron</property>
<offset type="double">+0.0</offset>
<factor type="double">+1.0</factor>
</binding>
</axis>
<axis n="1">
<number>
<unix>1</unix>
<windows>1</windows>
<mac>1</mac>
</number>
<desc>Elevator</desc>
<dead-band type="double">0.02</dead-band>
<binding>
<command>property-scale</command>
<property>/controls/flight/elevator</property>
<offset type="double">+0.0</offset>
<factor type="double">-1.0</factor>
</binding>
</axis>
<axis>
<number>
<unix>2</unix>
<windows>2</windows>
<mac>2</mac>
</number>
<desc>Rudder</desc>
<dead-band type="double">0.02</dead-band>
<binding>
<command>property-scale</command>
<property>/controls/flight/rudder</property>
<offset type="double">0.0</offset>
<factor type="double">1.0</factor>
</binding>
</axis>
<axis >
<number>
<unix>3</unix>
<windows>3</windows>
<mac>3</mac>
</number>
<desc>Throttle</desc>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[0]/throttle</property>
<offset type="double">-1.0</offset>
<factor type="double">-0.5</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[1]/throttle</property>
<offset type="double">-1.0</offset>
<factor type="double">-0.5</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[2]/throttle</property>
<offset type="double">-1.0</offset>
<factor type="double">-0.5</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[3]/throttle</property>
<offset type="double">-1.0</offset>
<factor type="double">-0.5</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[4]/throttle</property>
<offset type="double">-1.0</offset>
<factor type="double">-0.5</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[5]/throttle</property>
<offset type="double">-1.0</offset>
<factor type="double">-0.5</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[6]/throttle</property>
<offset type="double">-1.0</offset>
<factor type="double">-0.5</factor>
</binding>
<binding>
<command>property-scale</command>
<property>/controls/engines/engine[7]/throttle</property>
<offset type="double">-1.0</offset>
<factor type="double">-0.5</factor>
</binding>
</axis>
<axis>
<number>
<unix>2</unix>
<windows>2</windows>
<mac>2</mac>
</number>
<desc>Rudder</desc>
<dead-band type="double">0.02</dead-band>
<binding>
<command>property-scale</command>
<property>/controls/flight/rudder</property>
<offset type="double">0.0</offset>
<factor type="double">1.0</factor>
</binding>
</axis>
<button n="0">
<desc>Elevator trim down</desc>
<repeatable type="bool">true</repeatable>
<binding>
<command>property-adjust</command>
<property>/controls/flight/elevator-trim</property>
<step type="double">-0.001</step>
</binding>
</button>
<button n="1">
<desc>Brakes</desc>
<binding>
<command>property-assign</command>
<property>/controls/gear/wheel[0]/brake</property>
<value type="double">1.0</value>
</binding>
<binding>
<command>property-assign</command>
<property>/controls/gear/wheel[1]/brake</property>
<value type="double">1.0</value>
</binding>
<binding>
<command>property-assign</command>
<property>/controls/gear/wheel[2]/brake</property>
<value type="double">1.0</value>
</binding>
<mod-up>
<binding>
<command>property-assign</command>
<property>/controls/gear/wheel[0]/brake</property>
<value type="double">0.0</value>
</binding>
<binding>
<command>property-assign</command>
<property>/controls/gear/wheel[1]/brake</property>
<value type="double">0.0</value>
</binding>
<binding>
<command>property-assign</command>
<property>/controls/gear/wheel[2]/brake</property>
<value type="double">0.0</value>
</binding>
</mod-up>
</button>
<button n="2">
<repeatable>false</repeatable>
<binding>
<command>property-assign</command>
<property>/controls/gear/gear-down</property>
<value>true</value>
</binding>
</button>
<button n="3">
<desc>Elevator trim up</desc>
<repeatable type="bool">true</repeatable>
<binding>
<command>property-adjust</command>
<property>/controls/flight/elevator-trim</property>
<step type="double">0.001</step>
</binding>
</button>
<button n="4">
<desc>Flaps up</desc>
<repeatable>false</repeatable>
<binding>
<command>property-adjust</command>
<property>/controls/flight/flaps</property>
<step type="double">0.34</step>
</binding>
</button>
<button n="5">
<desc>Center rudder</desc>
<repeatable>false</repeatable>
<binding>
<command>property-adjust</command>
<property>/controls/flight/rudder</property>
<step type="double">0.0</step>
</binding>
</button>
<button n="6">
<desc>Flaps down</desc>
<repeatable>false</repeatable>
<binding>
<command>property-adjust</command>
<property>/controls/flight/flaps</property>
<step type="double">-0.34</step>
</binding>
</button>
</PropertyList>
<!-- end of TGF2PROUSB.xml -->

View file

@ -45,6 +45,7 @@ Joystick binding definitions.
<js-named include="Input/Joysticks/ThrustMaster/FCS.xml"/>
<js-named include="Input/Joysticks/ThrustMaster/Attack-Throttle.xml"/>
<js-named include="Input/Joysticks/ThrustMaster/Top-Gun-Afterburner.xml"/>
<js-named include="Input/Joysticks/ThrustMaster/Top-Gun-Fox2-Pro-USB.xml"/>
<!-- Lew Engineering RCJOY device for various RC transmitters. http://www.leweng.com -->
<js-named include="Input/Joysticks/LewEngineering/RC-transmitter-hitecLaser4.xml"/>