* Donn Washburn -- 9/9/2006 4:25 PM: > I suspect a joystick default is the source of the problem > Also please note that joystick.xml in /data/ has mention of a directory > /Local/ which is not there nor is the file.xml. fgfs scans the $FG_ROOT/Input/Joysticks/ directory and all subdirectories for joystick driver files. These are recognized by the xml extension, at least one <name>, and one <axis> or <button> entry. All of them are currently loaded into the property tree under /input/joysticks/js-named[1000++]. Then fgfs searches the nodes in reverse order (highest index first). It checks all <name> entries and compares them with the joystick's hardware id. (That's the one that's also listed by the js_demo(.exe) application.) If fgfs finds one or more matching <name>s then it picks the *last* found joystick definitions (that is, the ones from the /input/joysticks/js-named[] branch with the lowest index) and copies them to the respective /input/joysticks/js[*] branch. It deletes all others. If no matching <name> is found, then it picks the *last* found driver definitions with a <name>default</name> entry. It doesn't matter if this was loaded from $FG_ROOT/Input/Joysticks/Default/, or any other directory. File and directory names are not considered at all. You can add your own files and your own directories as you please. One obvious place would be $FG_ROOT/Input/Joysticks/Local/, as "local" is a typical dir name for user added stuff on Unix file systems. MS Windows users usually prefer baby language and file names with spaces, so they may use $FG_ROOT/Input/Joysticks/My\ First\ Joystick/ or whatever. :-}
If you want to force fgfs to use a particular joystick, then you can pre-load the driver file to a node with index <1000, as described in $FG_ROOT/joysticks.xml. Remember: fgfs picks the last found definitions. If you don't want fgfs to compare ids with <name>s at all, then you can as well load a driver to the final place right away: /input/joysticks/js[0] etc., as described in $FG_ROOT/joysticks.xml.You can also do that from the command line via --config= option (in which case you have to add <input><joysticks><js n="0">... </js></joysticks></input> around the definitions.) If you run into problems, then you have two ways to investigate what fgfs thinks it's doing: (A) call it with --log-level=info or --log-level=debug (more info) and, if possible, filter the joystick messages out: $ fgfs --log-level=debug 2>&1|grep joystick (B) start fgfs normally, open the property browser (Menu->File->Browse Internal Properties), navigate to /input/joysticks/js[0]/ and check the <id>, <name>, and <source> entries. <id> is the hardware id (as found in the js_demo(.exe) output), the <name>s are from the driver file, and <source> contains the full file path of the used driver file. In most cases <id> should match one of the <name>s. If it doesn't, then it's either a --config= loaded driver, or there simply was no driver file with a matching name. Note that a <name> tag must match the joystick's hardware id *exactly*, including typos, weird capitalization, doubled or trailing spaces and binary garbage. m. ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Flightgear-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/flightgear-users
