Add NWS switch

This commit is contained in:
legoboyvdlp R 2019-03-23 13:36:04 +00:00
parent 08e4deb14b
commit 23d3576bf5
5 changed files with 83 additions and 4 deletions

View file

@ -625,6 +625,7 @@
<brake-parking type="bool">0</brake-parking>
<tiller-cmd-norm type="double">0</tiller-cmd-norm>
<tiller-enabled type="bool">0</tiller-enabled>
<nws-switch type="double">1</nws-switch>
</gear>
<lighting>
<DU>

View file

@ -852,6 +852,45 @@
</action>
</animation>
<animation>
<type>rotate</type>
<object-name>land_sw</object-name>
<property>controls/gear/nws-switch</property>
<interpolation>
<entry><ind>0</ind><dep>35</dep></entry>
<entry><ind>1</ind><dep> 0</dep></entry>
</interpolation>
<axis>
<x>0</x>
<y>1</y>
<z>0</z>
</axis>
<center>
<x-m>-0.562289</x-m>
<y-m>0.259382</y-m>
<z-m>0.253933</z-m>
</center>
</animation>
<animation>
<type>pick</type>
<object-name>land_sw</object-name>
<action>
<button>0</button>
<button>3</button>
<repeatable>false</repeatable>
<binding>
<command>property-cycle</command>
<property>controls/gear/nws-switch</property>
<value>0</value>
<value>1</value>
</binding>
<binding>
<command>nasal</command>
<script>setprop("/sim/sounde/switch1", 1);</script>
</binding>
</action>
</animation>
<!-- Dimmer Panel Left -->
<animation>
<type>pick</type>

View file

@ -384,7 +384,7 @@ var messages_right_memo = func {
rat.colour = "g";
}
if (getprop("/sim/model/pushback/enabled") == 1) {
if (getprop("/sim/model/pushback/enabled") == 1) { # this message is only on when towing - not when disc with switch
nw_strg_disc.active = 1;
} else {
nw_strg_disc.active = 0;

View file

@ -2022,6 +2022,36 @@
</test>
</switch>
<switch name="hydraulics/tiller/hyd-pwr">
<default value="0"/>
<test logic="AND" value="1">
position/wow eq 1
hydraulics/tiller/elec-pwr eq 1
/systems/hydraulic/yellow-psi ge 1500
/sim/model/pushback/connected eq 0
/controls/gear/nws-switch eq 1
/engines/engine[0]/state eq 3
</test>
<test logic="AND" value="1">
position/wow eq 1
hydraulics/tiller/elec-pwr eq 1
/systems/hydraulic/yellow-psi ge 1500
/sim/model/pushback/connected eq 0
/controls/gear/nws-switch eq 1
/engines/engine[1]/state eq 3
</test>
</switch>
<switch name="hydraulics/tiller/elec-pwr">
<default value="0"/>
<test logic="OR" value="1">
/systems/electrical/bus/ac1 ge 110
/systems/electrical/bus/ac2 ge 110
/systems/electrical/bus/dc1 ge 25
/systems/electrical/bus/dc2 ge 25
</test>
</switch>
<fcs_function name="hydraulics/tiller/function">
<function>
<ifthen>
@ -2049,9 +2079,18 @@
</function>
</fcs_function>
<switch name="fcs/steer-rate">
<default value="0"/>
<test logic="OR" value="75">
hydraulics/tiller/hyd-pwr eq 1
/sim/model/pushback/connected eq 1
/systems/acconfig/autoconfig-running eq 1
</test>
</switch>
<actuator name="fcs/steer-deg">
<input>hydraulics/tiller/function</input>
<rate_limit>75</rate_limit>
<rate_limit>fcs/steer-rate</rate_limit>
<output>fcs/steer-pos-deg[0]</output>
</actuator>

View file

@ -1 +1 @@
4784
4785