Andy,

thanks, I'll see if I can get support from Apple. Actually my usb joystick HAS calibration both horizontal and vertical, but it simply sets the middle point of the handle. It is two dials (much like the throttle axes), and I've centered the stick using the HUD's indicators.


ima.sudonim wrote:
 > Calibration error?  Is this a problem internal to the joystick? In
 > the way plib or fg processes the joystick info?

It is a problem with your joystick.  Analog sticks have, since the
beginning of time, varied widely in the voltages they report to the
gameport.  So DOS games always had a "calibrate joystick" option to
figure out what dynamic range really is.  Modern drivers still have
this option, although I haven't personally seen a USB stick that
required any calibration (others swear they have, though).

The bottom line is that this is a driver/OS issue.  While you can fix
it in FlightGear by mucking with the XML, you really shouldn't have
to.

But if I CAN fix it with XML, why isn't the XML code in the file being accepted and having any effect in FG? What part of FG/SG processes the xml file and sets the properties for the joystick?


When I browse FG internal properties for the joystick, it has the following for:

 /input/joysticks/js/axis/binding/
command[0] = 'property-scale' (unspecified)
property[0] = '/controls/flight/aileron' (unspecified)
squared[0] = 'true' (bool)

 /input/joysticks/js/axis[1]/binding/
command[0] = 'property-scale' (unspecified)
factor[0] = '-1.000000' (double)
property[0] = '/controls/flight/elevator' (unspecified)
squared[0] = 'true' (bool)

/input/joysticks/js/axis[2]/binding/
command[0] = 'nasal' (unspecified)
script[0] = 'controls.throttleAxis()' (unspecified)

So why is the above nothing like the XML file which reads:
 <axis n="0">
  <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>    <!-- 0.0 -->
   <factor type="double">+2.0</factor>    <!-- 1.0 -->
  </binding>
 </axis>

 <axis n="1">
  <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>    <!-- 0.0 -->
   <factor type="double">2.0</factor>     <!-- 1.0 -->
  </binding>
 </axis>

  <axis n="2">
  <desc>Throttle</desc>
  <binding>
   <command>property-scale</command>
   <property>/controls/engines/engine/throttle</property>
   <offset type="double">+0.5</offset>   <!-- -1.0 -->
   <factor type="double">+2.0</factor>   <!-- -0.5 -->
  </binding>

And why is the rudder axis missing? I'm sure that I'm missing something obvious here, but I just can't see it! Argh!

It is the job of the operating system to tell you what the
physical position of the stick is in correct units.  Hunt for a
joystick preferences or control applet somewhere.

I can't find prefs or applet for the joystick nor even a generic one for usb (using mac os x (10.3)).


Nuts, ANOTHER usb problem 8-)

Thanks,

Ima

Andy






_______________________________________________
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel

Reply via email to