Board index FlightGear Support Hardware

Is the TCA Airbus edition Compatible with Flightgear ?

Joysticks, pedals, monitors.

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby jetsurfer » Fri Feb 12, 2021 1:37 pm

Mohamed you're a genius! All the buttons are working! Thank you!

Well, I'm still struggling with the detends/power settings and the reversers and a very funny behaviour of those ENG master switches: as soon as I enter the joysticks menu in FG their orientation changes by 180 degrees and the engines are switching themselves off.
jetsurfer
 
Posts: 28
Joined: Thu Jan 28, 2021 1:39 pm

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Mohamed » Fri Feb 12, 2021 1:39 pm

wait ima give you what i did for the detents

and for the eng master try not to refresh the joystick that's why they reset and if they are not on the correct position just click on them on the sim so they can match the eng master irl
Last edited by Mohamed on Fri Feb 12, 2021 2:42 pm, edited 2 times in total.
Mohamed
 
Posts: 76
Joined: Tue Aug 25, 2020 5:04 pm
Location: Casablanca, Morocco
Version: 2020.3.6

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Mohamed » Fri Feb 12, 2021 1:43 pm

so add this to the TCA Q-Eng 1&2 file in the button part

Code: Select all
  <button n="9">
    <desc type="string">Custom</desc>
    <repeatable type="string">true</repeatable>
    <binding>
      <command type="string">property-assign</command>
      <property type="string">/controls/engines/engine[0]/throttle</property>
      <value type="string">0.80</value>
      <offset type="double">1</offset>
    </binding>
  </button>
  <button n="10">
    <desc type="string">Custom</desc>
    <repeatable type="string">true</repeatable>
    <binding>
      <command type="string">property-assign</command>
      <property type="string">/controls/engines/engine[0]/throttle</property>
      <value type="string">0.62</value>
      <offset type="double">1</offset>
    </binding>
  </button>
  <button n="13">
    <desc type="string">Custom</desc>
    <repeatable type="string">true</repeatable>
    <binding>
      <command type="string">property-assign</command>
      <property type="string">/controls/engines/engine[1]/throttle</property>
      <value type="string">0.80</value>
      <offset type="double">1</offset>
    </binding>
  </button>
  <button n="14">
    <desc type="string">Custom</desc>
    <repeatable type="string">true</repeatable>
    <binding>
      <command type="string">property-assign</command>
      <property type="string">/controls/engines/engine[1]/throttle</property>
      <value type="string">0.62</value>
      <offset type="double">1</offset>
    </binding>
  </button>
    <button n="15">
    <desc type="string">Custom</desc>
    <repeatable type="string">false</repeatable>
    <binding>
   <command>nasal</command>
   <script>
   if (pts.Systems.Thrust.state[1].getValue() == "IDLE" and pts.Controls.Engines.Engine.reverser[1].getValue() == 0 and pts.Gear.wow[1].getValue() == 1 and pts.Gear.wow[2].getValue() == 1) {
      if (pts.Sim.Input.Selected.engine[1].getBoolValue()) {
         interpolate("/engines/engine[1]/reverser-pos-norm", 1, 1.4);
         pts.Controls.Engines.Engine.reverser[1].setValue(1);
         pts.Controls.Engines.Engine.throttleRev[1].setValue(0.65);
         pts.Fdm.JSBsim.Propulsion.Engine.reverserAngle[1].setValue(3.14);
      }
   } else if (pts.Controls.Engines.Engine.reverser[1].getValue() == 1) {
      interpolate("/engines/engine[1]/reverser-pos-norm", 0, 1.0);
      pts.Controls.Engines.Engine.throttleRev[1].setValue(0);
      pts.Fdm.JSBsim.Propulsion.Engine.reverserAngle[1].setValue(0);
      pts.Controls.Engines.Engine.reverser[1].setValue(0);
   }
   </script>
    </binding>
   <mod-up>
       <binding>
         <command>nasal</command>
         <script>
   if (pts.Systems.Thrust.state[1].getValue() == "IDLE" and pts.Controls.Engines.Engine.reverser[1].getValue() == 0 and pts.Gear.wow[1].getValue() == 1 and pts.Gear.wow[2].getValue() == 1) {
      if (pts.Sim.Input.Selected.engine[1].getBoolValue()) {
         interpolate("/engines/engine[1]/reverser-pos-norm", 1, 1.4);
         pts.Controls.Engines.Engine.reverser[1].setValue(1);
         pts.Controls.Engines.Engine.throttleRev[1].setValue(0.65);
         pts.Fdm.JSBsim.Propulsion.Engine.reverserAngle[1].setValue(3.14);
      }
   } else if (pts.Controls.Engines.Engine.reverser[1].getValue() == 1) {
      interpolate("/engines/engine[1]/reverser-pos-norm", 0, 1.0);
      pts.Controls.Engines.Engine.throttleRev[1].setValue(0);
      pts.Fdm.JSBsim.Propulsion.Engine.reverserAngle[1].setValue(0);
      pts.Controls.Engines.Engine.reverser[1].setValue(0);
   }
         </script>
    </binding>
   </mod-up>
  </button>
      <button n="11">
    <desc type="string">Custom</desc>
    <repeatable type="string">false</repeatable>
    <binding>
   <command>nasal</command>
   <script>
if (pts.Systems.Thrust.state[0].getValue() == "IDLE" and pts.Controls.Engines.Engine.reverser[0].getValue() == 0 and pts.Gear.wow[1].getValue() == 1 and pts.Gear.wow[2].getValue() == 1) {
      if (pts.Sim.Input.Selected.engine[0].getBoolValue()) {
         interpolate("/engines/engine[0]/reverser-pos-norm", 1, 1.4);
         pts.Controls.Engines.Engine.reverser[0].setValue(1);
         pts.Controls.Engines.Engine.throttleRev[0].setValue(0.65);
         pts.Fdm.JSBsim.Propulsion.Engine.reverserAngle[0].setValue(3.14);
      }
   } else if (pts.Controls.Engines.Engine.reverser[0].getValue() == 1) {
      interpolate("/engines/engine[0]/reverser-pos-norm", 0, 1.0);
      pts.Controls.Engines.Engine.throttleRev[0].setValue(0);
      pts.Fdm.JSBsim.Propulsion.Engine.reverserAngle[0].setValue(0);
      pts.Controls.Engines.Engine.reverser[0].setValue(0);
   }
   </script>
    </binding>
   <mod-up>
       <binding>
         <command>nasal</command>
         <script>
if (pts.Systems.Thrust.state[0].getValue() == "IDLE" and pts.Controls.Engines.Engine.reverser[0].getValue() == 0 and pts.Gear.wow[1].getValue() == 1 and pts.Gear.wow[2].getValue() == 1) {
      if (pts.Sim.Input.Selected.engine[0].getBoolValue()) {
         interpolate("/engines/engine[0]/reverser-pos-norm", 1, 1.4);
         pts.Controls.Engines.Engine.reverser[0].setValue(1);
         pts.Controls.Engines.Engine.throttleRev[0].setValue(0.65);
         pts.Fdm.JSBsim.Propulsion.Engine.reverserAngle[0].setValue(3.14);
      }
   } else if (pts.Controls.Engines.Engine.reverser[0].getValue() == 1) {
      interpolate("/engines/engine[0]/reverser-pos-norm", 0, 1.0);
      pts.Controls.Engines.Engine.throttleRev[0].setValue(0);
      pts.Fdm.JSBsim.Propulsion.Engine.reverserAngle[0].setValue(0);
      pts.Controls.Engines.Engine.reverser[0].setValue(0);
   }
         </script>
    </binding>
   </mod-up>
  </button>


then go to the axis part. you will see the throttle axis

change the offset to -0.43
and the factor to -1
for both of them

i hope it will work for u
the throttle is not 100% perfect but it's playable
Mohamed
 
Posts: 76
Joined: Tue Aug 25, 2020 5:04 pm
Location: Casablanca, Morocco
Version: 2020.3.6

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby jetsurfer » Fri Feb 12, 2021 2:21 pm

Cool thanks!
jetsurfer
 
Posts: 28
Joined: Thu Jan 28, 2021 1:39 pm

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Mohamed » Fri Feb 12, 2021 2:39 pm

did it work ?
Mohamed
 
Posts: 76
Joined: Tue Aug 25, 2020 5:04 pm
Location: Casablanca, Morocco
Version: 2020.3.6

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby jetsurfer » Fri Feb 12, 2021 3:11 pm

The levers are very nice now! Close to perfect ;) Reverse also works. I just can't convince the ap disconnect to work.
jetsurfer
 
Posts: 28
Joined: Thu Jan 28, 2021 1:39 pm

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby jetsurfer » Fri Feb 12, 2021 3:21 pm

Is there a way to slightly enlarge the range for lever asymmetry? It comes on very easily on my levers.
jetsurfer
 
Posts: 28
Joined: Thu Jan 28, 2021 1:39 pm

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Mohamed » Fri Feb 12, 2021 3:41 pm

-i am working on ap it was working but now it's not

-and i don't think so

i never coded before i am new so i hope my code is good
Mohamed
 
Posts: 76
Joined: Tue Aug 25, 2020 5:04 pm
Location: Casablanca, Morocco
Version: 2020.3.6

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Mohamed » Sun Feb 14, 2021 10:35 am

try this for the autopilot: (in the TA320 file
when pressed for the first time
    Ap will disconnect
    A single cavalry charge aural warning
    The master warning flashing for several seconds
    an AP OFF red message appearing in the rght column of the uper ecam

pressing it again will stop all these warnings

Code: Select all
               <button n="3">
  <desc type="string">Custom</desc>   
                    <binding>
            <condition>
            <and>
               <greater-than-equals>
                  <property>systems/electrical/bus/dc-ess</property>
                  <value>25</value>
               </greater-than-equals>
            <equals>
               <property>it-autoflight/output/ap1</property>
               <value>0</value>
            </equals>
                        <equals>
               <property>it-autoflight/output/ap2</property>
               <value>0</value>
            </equals>
               </and>
            </condition>
            <command>nasal</command>
            <script>
               if (getprop("it-autoflight/output/ap-warning") == 1) {
                  setprop("it-autoflight/output/ap-warning", 0);
               }
               if (getprop("it-autoflight/sound/apoffsound") == 1 or getprop("it-autoflight/sound/apoffsound2") == 1) {
                  setprop("it-autoflight/sound/apoffsound", 0);
                  setprop("it-autoflight/sound/apoffsound2", 0);
               }
            </script>
         </binding>
         <binding>
            <condition>
            <and>
               <greater-than-equals>
                  <property>systems/electrical/bus/dc-ess</property>
                  <value>25</value>
               </greater-than-equals>
            <equals>
               <property>it-autoflight/output/ap1</property>
               <value>0</value>
            </equals>
                        <equals>
               <property>it-autoflight/output/ap2</property>
               <value>0</value>
            </equals>
               </and>
            </condition>
            <command>property-assign</command>
            <property>ECAM/warnings/master-warning-light</property>
            <value>0</value>
         </binding>
         <binding>
               <condition>
               <or>
            <equals>
               <property>it-autoflight/output/ap1</property>
               <value>1</value>
            </equals>
                        <equals>
               <property>it-autoflight/output/ap2</property>
               <value>1</value>
            </equals>
            </or>
      </condition>
               <command>nasal</command>
               <script>
                  fcu.FCUController.APDisc();
                  setprop("/sim/sounde/apdiscbtn", 1);
               </script>
         </binding>
     <repeatable type="double">0</repeatable>
     </button>


Autothrottle: (add this in TCA Q-Eng 1&2)
press for the 1st time will disconnect autothrust
-you will here the A/THR Disc sound
-Master caution will turn on for several seconds then turn back off
-an A/THR OFF orange message will appear in the right column of the Upper Ecam
Code: Select all
  <button>
    <desc type="string">Custom</desc>
               <binding>
            <condition>
               <and>
               <greater-than-equals>
                  <property>systems/electrical/bus/dc-ess</property>
                  <value>25</value>
               </greater-than-equals>
               <equals>
               <property>it-autoflight/output/athr</property>
               <value>0</value>
            </equals>
            </and>
            </condition>
            <command>nasal</command>
            <script>
               if (getprop("it-autoflight/output/athr-warning") == 1) {
                  setprop("it-autoflight/output/athr-warning", 0);
               }
            </script>
         </binding>
                           <binding>
            <condition>
               <and>
               <greater-than-equals>
                  <property>systems/electrical/bus/dc-ess</property>
                  <value>25</value>
               </greater-than-equals>
               <equals>
               <property>it-autoflight/output/athr</property>
               <value>0</value>
            </equals>
            </and>
            </condition>
            <command>property-assign</command>
            <property>ECAM/warnings/master-caution-light</property>
            <value>0</value>
         </binding>
    <binding>
            <condition>
               <and>
               <greater-than-equals>
                  <property>systems/electrical/bus/dc-ess</property>
                  <value>25</value>
               </greater-than-equals>
               <equals>
               <property>it-autoflight/output/athr</property>
               <value>1</value>
            </equals>
            </and>
            </condition>
      <command type="string">nasal</command>
      <script type="string">
   fcu.FCUController.ATDisc();
   </script>
    </binding>
    <repeatable type="double">1</repeatable>
  </button>
  <button n="1">
    <desc type="string">Custom</desc>
               <binding>
            <condition>
               <and>
               <greater-than-equals>
                  <property>systems/electrical/bus/dc-ess</property>
                  <value>25</value>
               </greater-than-equals>
               <equals>
               <property>it-autoflight/output/athr</property>
               <value>0</value>
            </equals>
            </and>
            </condition>
            <command>nasal</command>
            <script>
               if (getprop("it-autoflight/output/athr-warning") == 1) {
                  setprop("it-autoflight/output/athr-warning", 0);
               }
            </script>
         </binding>
                  <binding>
            <condition>
               <and>
               <greater-than-equals>
                  <property>systems/electrical/bus/dc-ess</property>
                  <value>25</value>
               </greater-than-equals>
               <equals>
               <property>it-autoflight/output/athr</property>
               <value>0</value>
            </equals>
            </and>
            </condition>
            <command>property-assign</command>
            <property>ECAM/warnings/master-caution-light</property>
            <value>0</value>
         </binding>
    <binding>
            <condition>
               <and>
               <greater-than-equals>
                  <property>systems/electrical/bus/dc-ess</property>
                  <value>25</value>
               </greater-than-equals>
               <equals>
               <property>it-autoflight/output/athr</property>
               <value>1</value>
            </equals>
            </and>
            </condition>
      <command type="string">nasal</command>
      <script type="string">
   fcu.FCUController.ATDisc();
   </script>
    </binding>
    <repeatable type="double">1</repeatable>
  </button>


tell me if it works as i described it
Mohamed
 
Posts: 76
Joined: Tue Aug 25, 2020 5:04 pm
Location: Casablanca, Morocco
Version: 2020.3.6

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby jetsurfer » Mon Feb 15, 2021 2:02 am

Looks like it is working! Great work Mohamed! Did you know the original values for A/THR disconnect (Single chime, Master Caution light for 3s and A/THR OFF amber message for 9s)?

Did you ever try the GA function? Does it work in your sim? In mine, the FD bars do not command any pitch up when pushing the levers into TOGA.
jetsurfer
 
Posts: 28
Joined: Thu Jan 28, 2021 1:39 pm

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Mohamed » Mon Feb 15, 2021 10:18 am

jetsurfer wrote in Mon Feb 15, 2021 2:02 am:Did you ever try the GA function? Does it work in your sim? In mine, the FD bars do not command any pitch up when pushing the levers into TOGA.


yes it works normally, i think you should like activate something in the GA section of the MCDU maybe it will work
Mohamed
 
Posts: 76
Joined: Tue Aug 25, 2020 5:04 pm
Location: Casablanca, Morocco
Version: 2020.3.6

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Mohamed » Mon Feb 15, 2021 11:48 am

jetsurfer wrote in Fri Feb 12, 2021 1:37 pm:a very funny behaviour of those ENG master switches: as soon as I enter the joysticks menu in FG their orientation changes by 180 degrees and the engines are switching themselves off.


i found the solution: (it was my mistake sorry)

go back to the TCA Q-Eng 1&2
and replace button 2 and 3 code by
Code: Select all
  <button n="2">
    <desc type="string">Custom</desc>
    <repeatable type="string">false</repeatable>
    <binding>
      <command type="string">property-assign</command>
      <property type="string">/controls/engines/engine[0]/cutoff-switch</property>
      <value type="string">0</value>
    </binding>
    <mod-up>
      <binding>
        <command type="string">property-assign</command>
        <property type="string">/controls/engines/engine[0]/cutoff-switch</property>
        <value type="string">1</value>
      </binding>
    </mod-up>
  </button>
  <button n="3">
    <desc type="string">Custom</desc>
    <repeatable type="string">false</repeatable>
    <binding>
      <command type="string">property-assign</command>
      <property type="string">/controls/engines/engine[1]/cutoff-switch</property>
      <value type="string">0</value>
    </binding>
    <mod-up>
      <binding>
        <command type="string">property-assign</command>
        <property type="string">/controls/engines/engine[1]/cutoff-switch</property>
        <value type="string">1</value>
      </binding>
    </mod-up>
  </button>


it should work now
Mohamed
 
Posts: 76
Joined: Tue Aug 25, 2020 5:04 pm
Location: Casablanca, Morocco
Version: 2020.3.6

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby jetsurfer » Mon Feb 15, 2021 4:31 pm

Everything seems to work just fine now ;) Even GA ist working (triggers SRS and HDG). Very cool! Thanks again to Mohamed!
jetsurfer
 
Posts: 28
Joined: Thu Jan 28, 2021 1:39 pm

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Mohamed » Mon Feb 15, 2021 4:55 pm

no problem
i'm happy it worked for you
Mohamed
 
Posts: 76
Joined: Tue Aug 25, 2020 5:04 pm
Location: Casablanca, Morocco
Version: 2020.3.6

Re: Is the TCA Airbus edition Compatible with Flightgear ?

Postby Steward Airborn » Mon Feb 22, 2021 7:28 am

Hi, I’ve bought the TCA Joystick for my Mac. It was “plug and play” for FlightGear 2018 on OSX intel Mac, but FG version 2020 with OS Big sur with a M1 chip won’t work.
Steward Airborn
 
Posts: 7
Joined: Sun Feb 21, 2021 12:30 am

PreviousNext

Return to Hardware

Who is online

Users browsing this forum: No registered users and 4 guests