Board index FlightGear Support Hardware

Thrustmaster T-rudder

Joysticks, pedals, monitors.

Thrustmaster T-rudder

Postby Steward Airborn » Sat Jan 15, 2022 10:39 am

Hi everyone,

I see there are some troubles with the Thrustmaster T-rudder with the brakes.
Here is a .xml that fix it.

Have fun.

Code: Select all
<?xml version="1.0"?>

<PropertyList>
  <name type="string">T-Rudder</name>
  <axis>
    <desc type="string">Brake Right</desc>
    <binding>
      <command type="string">property-scale</command>
      <property type="string">/controls/gear/brake-right</property>
      <factor type="double">-0.5</factor>
      <offset type="double">-1</offset>
      <power type="double">1</power>
    </binding>
  </axis>
  <axis n="1">
    <desc type="string">Brake Left</desc>
    <binding>
      <command type="string">property-scale</command>
      <property type="string">/controls/gear/brake-left</property>
      <factor type="double">-0.5</factor>
      <offset type="double">-1</offset>
      <power type="double">1</power>
    </binding>
  </axis>
  <axis n="2">
    <desc type="string">Rudder</desc>
    <binding>
      <command type="string">property-scale</command>
      <property type="string">/controls/flight/rudder</property>
      <factor type="double">1</factor>
      <offset type="double">0</offset>
      <power type="double">5</power>
    </binding>
  </axis>
  <button>
    <desc type="string">Brakes</desc>
    <repeatable type="string">false</repeatable>
    <binding>
      <command type="string">nasal</command>
      <script type="string">controls.applyBrakes(1);</script>
    </binding>
    <mod-up>
      <binding>
        <command type="string">nasal</command>
        <script type="string">controls.applyBrakes(0);</script>
      </binding>
    </mod-up>
  </button>
  <button n="1">
    <desc type="string">Elevator Trim Down</desc>
    <binding>
      <command type="string">nasal</command>
      <script type="string">controls.elevatorTrim(1);</script>
    </binding>
    <repeatable type="double">1</repeatable>
  </button>
  <button n="2">
    <desc type="string">Elevator Trim Up</desc>
    <binding>
      <command type="string">nasal</command>
      <script type="string">controls.elevatorTrim(-1);</script>
    </binding>
    <repeatable type="double">1</repeatable>
  </button>
</PropertyList>
Steward Airborn
 
Posts: 7
Joined: Sun Feb 21, 2021 12:30 am

Re: Thrustmaster T-rudder

Postby Styx » Thu Feb 03, 2022 4:43 pm

Thanks for the time investment.

My problem is that after I drop the xml file in Input —> Joysticks it’s replaced by the original, faulty xml file as soon as I start a simulation.

Flightgear is importing the faulty configuration from somewhere but after several hours searching I still have no idea where.

I don’t particularly need pedal brakes but I sure wish I had the option.

Any suggestions would be so appreciated!

Styx
Styx
 
Posts: 4
Joined: Wed Feb 02, 2022 6:01 pm

Re: Thrustmaster T-rudder

Postby wkitty42 » Thu Feb 03, 2022 8:32 pm

you need to make sure the device ID in your XML file is the one that FG is finding and using from the other file...
this line from the above XML code:
Code: Select all
<name type="string">T-Rudder</name>

it should match what the device manager and FG use...
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 9146
Joined: Fri Feb 20, 2015 4:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 20.04

Re: Thrustmaster T-rudder

Postby Styx » Sat Feb 05, 2022 4:27 pm

Right, well that makes sense, but both files are named “T-Rudder”, so it seems to me it’s a directory path issue, not a file name issue.

I would think I need to know the directory path of the default configuration file that FG imports at the beginning of every sim so I can alter the program xml code.

Or else locate the file (xml?) that keep’s calling up the old configuration so I can change the directory path of the target configuration.

I’ve checked out dozens of xml files trying to find the source, but no joy.
Styx
 
Posts: 4
Joined: Wed Feb 02, 2022 6:01 pm

Re: Thrustmaster T-rudder

Postby Styx » Sat Feb 05, 2022 8:06 pm

I’ve made some progress so that a sim starts with correct configuration, although the configurations default to the original faulty settings as soon as I alter an instrument setting.

I’ll keep trying and post some code after more progress.
Styx
 
Posts: 4
Joined: Wed Feb 02, 2022 6:01 pm

Re: Thrustmaster T-rudder

Postby wkitty42 » Sat Feb 05, 2022 9:50 pm

if you use the in-sim joystick configurator, you will loose all your custom joystick work... do not use the in-sim configurator at all once you have your's working...
always be sure to keep a backup copy of what you are working on, too, so you can update and replace it as you get each axis and button working as desired...

the original joystick files are in your FGData directory in the same tree you find your edited one in...

on linux, for example:
my edited ones are here: $HOME/.fgfs/Input/Joysticks
the default ones are here: $INSTALLDIR/flightgear/fgdata/Input/Joysticks

it is not recommended at all to edit or change files in FGData... it can lead to problems down the road...
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 9146
Joined: Fri Feb 20, 2015 4:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 20.04

Re: Thrustmaster T-rudder

Postby Styx » Sat Feb 05, 2022 11:05 pm

Okay, that explains it then.

Thanks so much for the assistance, it really is appreciated!
Styx
 
Posts: 4
Joined: Wed Feb 02, 2022 6:01 pm

Re: Thrustmaster T-rudder

Postby wkitty42 » Sun Feb 06, 2022 11:16 am

not a problem...

it is also possible that once you get a working XML file, it may be submitted for inclusion in FG so it can be used by everyone else having this particular controller... this depends on how things have been done in the XML, though... a pure XML file is much preferred over ones with nasal code in them...
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 9146
Joined: Fri Feb 20, 2015 4:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 20.04


Return to Hardware

Who is online

Users browsing this forum: No registered users and 5 guests