Board index FlightGear Support Hardware

Joystick Button Configaration

Joysticks, pedals, monitors.

Joystick Button Configaration

Postby Clive2670 » Mon Dec 04, 2017 6:29 pm

Hi all I have just come across a great bit of software to configure your joystick. I have been trying to configure a button for reverse thrust for the 777 by trying (ALWAYS unsuccessfully) to re-write the xml codes. STOP trying guys and download this little bit of software https://sourceforge.net/projects/antimi ... p_redirect . Start it click on any spare button on your joystick then click the highlighted box it will come up with a keyboard click on "delete" key for say reverse thrust on the 777 save the config' and hay presto all done reverse thrust now works on the key you set on your joystick!!!! Better than numerous times (and failing) of trying to re-write and bind keys in the xml codes of your joystick!!! It will save you hours if like me you really aren't too sure about coding, also if you do know how to code it saves you the hassle!!! :D :D :D :D
Thanks Clive aka: G-BLS01, BIGJET1
Can be seen flying the Boeing 777-200LR
Toshiba laptop,
Intel i5 4210U,
16Gb RAM,
AMD R7-M260 graphics 2Gb RAM
User avatar
Clive2670
 
Posts: 577
Joined: Mon Feb 08, 2016 7:11 pm
Location: Anywhere in the World at some point on Flightgear!
Callsign: G-BLS01, BIGJET1
Version: 2018.1.1
OS: Windows 10 64bit

Re: Joystick Button Configaration

Postby sim » Mon Jan 08, 2018 10:15 pm

When it will write code to do as many things that a single button can do, we'll give it a go!
Will it write code to reverse thrust, open speedbrakes or airbrakes, apply brakes and even lock tailwheel (if fitted)
and then reverse all those actions once button is released? 8)
THIS ONE DOES >>
Code: Select all
<button n="5">   <desc>T2  024-ReverseThrust, X_BRAKES           13-Tailwheel, 5-AirBrake, X-CUT:POWER</desc>
 <binding>
 <command>property-assign</command> <property>/controls/gear/brake-left</property> <value type="double">1.0</value> </binding> <binding> <command>property-assign</command> <property>/controls/gear/brake-right</property> <value type="double">1.0</value> </binding> <repeatable type="bool">false</repeatable>
 <binding>
 <command>nasal</command>
      <script>
props.setAll("/controls/engines/engine", "reverser", 1);setprop("/controls/flight/speedbrake", 1);setprop("/controls/gear/tailwheel-lock", 1);</script>
 </binding> <binding>
 <command>nasal</command>
 <script>
props.setAll("/controls/engines/engine", "throttle", -1);</script> </binding>
 <mod-up>
 <binding>
   <command>nasal</command>
 <script>
props.setAll("/controls/engines/engine", "reverser", 0);setprop("/controls/flight/speedbrake", 0);</script>
 </binding>   <binding> <command>property-assign</command> <property>/controls/gear/brake-left</property> <value type="double">0.0</value> </binding> <binding> <command>property-assign</command> <property>/controls/gear/brake-right</property> <value type="double">0.0</value> </binding> 
</mod-up>
</button>
User avatar
sim
 
Posts: 1369
Joined: Tue Jun 30, 2009 2:13 pm
Location: Shropshire England
Callsign: Fly4Fun
Version: 0.9.10 up
OS: 64 Win 10 HD6450

Re: Joystick Button Configaration

Postby Clive2670 » Tue Jan 09, 2018 6:42 pm

Not sure about "all" the actions you quoted as I have had no need to try these but it will "release" the actions that you map from your keyboard by pressing the same button again, also it has the ability to set a delay on any button if it's required so you have to hold that button for say 50ms before it will respond, this saves accidently bringing in say reverse thrust in the air!
Thanks Clive aka: G-BLS01, BIGJET1
Can be seen flying the Boeing 777-200LR
Toshiba laptop,
Intel i5 4210U,
16Gb RAM,
AMD R7-M260 graphics 2Gb RAM
User avatar
Clive2670
 
Posts: 577
Joined: Mon Feb 08, 2016 7:11 pm
Location: Anywhere in the World at some point on Flightgear!
Callsign: G-BLS01, BIGJET1
Version: 2018.1.1
OS: Windows 10 64bit

Re: Joystick Button Configaration

Postby sim » Wed Jan 10, 2018 1:04 pm

I agree as a bit of a fumbly myself having written off several FG planes by accidentally pressing the wrong button, that a button delay might have saved the day! :lol: There is a better way to prevent reversers activating in the air. WOW property can ensure reversers can only be activated when wheels are on the ground.
Even more devastating I recall once setting up a button script setprop(2/controls/engines/engine[1]/rpm",0); to stop Mosquito engines rpm dead in mid air. Now that really was fun! :wink:
Start the video 1:45min in to miss the boring bit.
User avatar
sim
 
Posts: 1369
Joined: Tue Jun 30, 2009 2:13 pm
Location: Shropshire England
Callsign: Fly4Fun
Version: 0.9.10 up
OS: 64 Win 10 HD6450


Return to Hardware

Who is online

Users browsing this forum: No registered users and 3 guests