fixed the PFD VOR2 pointer to point to nav[1] vor heading ... and var-ified
This commit is contained in:
parent
89467fe9ca
commit
6f1b020d68
7 changed files with 289 additions and 85 deletions
|
@ -4,7 +4,7 @@ MATERIAL "illum" rgb 1 1 1 amb 0 0 0 emis 0.7 0.7 0.7 spec 0 0 0 shi 0 trans 0
|
|||
MATERIAL "gloss" rgb 1 1 1 amb 0 0 0 emis 0 0 0 spec 0.504136 0.504136 0.504136 shi 32 trans 0
|
||||
MATERIAL "DefaultWhite.002" rgb 1 1 1 amb 1 1 1 emis 0 0 0 spec 0.5 0.5 0.5 shi 64 trans 0
|
||||
OBJECT world
|
||||
kids 5
|
||||
kids 7
|
||||
OBJECT group
|
||||
name "AP-on"
|
||||
kids 2
|
||||
|
@ -129,6 +129,59 @@ refs 4
|
|||
7 0.00160938501358 0.9972884655
|
||||
kids 0
|
||||
OBJECT poly
|
||||
name "Low-on"
|
||||
data 9
|
||||
Plane.039
|
||||
texture "AP.rgb"
|
||||
texrep 1 1
|
||||
crease 30.000000
|
||||
numvert 8
|
||||
0.002695 0.019113 0.006486
|
||||
0.002695 0.010804 0.006486
|
||||
0.002695 0.010804 0.022623
|
||||
0.002695 0.019113 0.022623
|
||||
0.002532 0.019113 0.006486
|
||||
0.002532 0.019113 0.022623
|
||||
0.002532 0.010804 0.022623
|
||||
0.002532 0.010804 0.006486
|
||||
numsurf 5
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
0 0.26472094655 0.150764152408
|
||||
3 0.164366453886 0.150764152408
|
||||
2 0.164366453886 0.0454634986818
|
||||
1 0.26472094655 0.0454634986818
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
3 0.26472094655 0.150764152408
|
||||
0 0.164366453886 0.150764152408
|
||||
4 0.164366453886 0.0454634986818
|
||||
5 0.26472094655 0.0454634986818
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
2 0.26472094655 0.150764152408
|
||||
3 0.164366453886 0.150764152408
|
||||
5 0.164366453886 0.0454634986818
|
||||
6 0.26472094655 0.0454634986818
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
1 0.26472094655 0.150764152408
|
||||
2 0.164366453886 0.150764152408
|
||||
6 0.164366453886 0.0454634986818
|
||||
7 0.26472094655 0.0454634986818
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
0 0.26472094655 0.150764152408
|
||||
1 0.164366453886 0.150764152408
|
||||
7 0.164366453886 0.0454634986818
|
||||
4 0.26472094655 0.0454634986818
|
||||
kids 0
|
||||
OBJECT poly
|
||||
name "Pitch.trim"
|
||||
data 8
|
||||
Cube.001
|
||||
|
@ -203,6 +256,25 @@ refs 4
|
|||
4 0.230187892914 0.757982492447
|
||||
kids 0
|
||||
OBJECT poly
|
||||
name "Plane.002"
|
||||
data 9
|
||||
Plane.001
|
||||
crease 30.000000
|
||||
numvert 4
|
||||
0 0.033054 -0.072306
|
||||
0 -0.033054 -0.072306
|
||||
0 -0.033054 0.072306
|
||||
0 0.033054 0.072306
|
||||
numsurf 1
|
||||
SURF 0x20
|
||||
mat 0
|
||||
refs 4
|
||||
0 0 0
|
||||
3 0 0
|
||||
2 0 0
|
||||
1 0 0
|
||||
kids 0
|
||||
OBJECT poly
|
||||
name "Roll.trim"
|
||||
data 8
|
||||
Cylinder
|
||||
|
@ -339,8 +411,8 @@ refs 4
|
|||
kids 0
|
||||
OBJECT poly
|
||||
name "YD-on"
|
||||
data 5
|
||||
Plane
|
||||
data 9
|
||||
Plane.002
|
||||
texture "AP.rgb"
|
||||
texrep 1 1
|
||||
crease 30.000000
|
||||
|
@ -357,36 +429,36 @@ numsurf 5
|
|||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
0 0.266209185123 0.155132696033
|
||||
3 0.153918191791 0.155132696033
|
||||
2 0.153918191791 0.0410949513316
|
||||
1 0.266209185123 0.0410949513316
|
||||
0 0.134209290147 0.155132696033
|
||||
3 0.021918296814 0.155132696033
|
||||
2 0.021918296814 0.0410949513316
|
||||
1 0.134209290147 0.0410949513316
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
3 0.266209185123 0.155132696033
|
||||
0 0.153918191791 0.155132696033
|
||||
4 0.153918191791 0.0410949513316
|
||||
5 0.266209185123 0.0410949513316
|
||||
3 0.134209290147 0.155132696033
|
||||
0 0.021918296814 0.155132696033
|
||||
4 0.021918296814 0.0410949513316
|
||||
5 0.134209290147 0.0410949513316
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
2 0.266209185123 0.155132696033
|
||||
3 0.153918191791 0.155132696033
|
||||
5 0.153918191791 0.0410949513316
|
||||
6 0.266209185123 0.0410949513316
|
||||
2 0.134209290147 0.155132696033
|
||||
3 0.021918296814 0.155132696033
|
||||
5 0.021918296814 0.0410949513316
|
||||
6 0.134209290147 0.0410949513316
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
1 0.266209185123 0.155132696033
|
||||
2 0.153918191791 0.155132696033
|
||||
6 0.153918191791 0.0410949513316
|
||||
7 0.266209185123 0.0410949513316
|
||||
1 0.134209290147 0.155132696033
|
||||
2 0.021918296814 0.155132696033
|
||||
6 0.021918296814 0.0410949513316
|
||||
7 0.134209290147 0.0410949513316
|
||||
SURF 0x00
|
||||
mat 1
|
||||
refs 4
|
||||
0 0.266209185123 0.155132696033
|
||||
1 0.153918191791 0.155132696033
|
||||
7 0.153918191791 0.0410949513316
|
||||
4 0.266209185123 0.0410949513316
|
||||
0 0.134209290147 0.155132696033
|
||||
1 0.021918296814 0.155132696033
|
||||
7 0.021918296814 0.0410949513316
|
||||
4 0.134209290147 0.0410949513316
|
||||
kids 0
|
||||
|
|
|
@ -24,4 +24,15 @@ Primus 1000 Autopilot Controller
|
|||
</condition>
|
||||
</animation>
|
||||
|
||||
</PropertyList>
|
||||
<animation>
|
||||
<type>select</type>
|
||||
<object-name>Low-on</object-name>
|
||||
<condition>
|
||||
<equals>
|
||||
<property>autopilot/settings/low-bank-deg</property>
|
||||
<value>14</value>
|
||||
</equals>
|
||||
</condition>
|
||||
</animation>
|
||||
|
||||
</PropertyList>
|
|
@ -1,6 +1,30 @@
|
|||
<!--
|
||||
Syd Adams
|
||||
P1000 AP controller hotspots
|
||||
Defaults to : Pitch and Hdg mode if no FD input
|
||||
|
||||
Pitch Wheel:
|
||||
Change pitch attitude
|
||||
Cancels ALT or ASEL
|
||||
No effect with GS hold captured
|
||||
|
||||
Low Bank switch:
|
||||
Limits bank to 14 degrees in HDG mode
|
||||
No op in NAV mode
|
||||
Returns to normal bank (27 degrees)
|
||||
Low bank is automatic above 34.000 ft MSL
|
||||
|
||||
AP button :
|
||||
Engages AP and Yaw Damper
|
||||
Disengages AP only
|
||||
|
||||
YD button :
|
||||
Engages Yaw Damper
|
||||
Disengages AP and YD
|
||||
|
||||
TURN knob :
|
||||
Commands roll - max 30 degrees
|
||||
Cancels other lateral modes
|
||||
-->
|
||||
|
||||
<PropertyList>
|
||||
|
@ -39,13 +63,36 @@ P1000 AP controller hotspots
|
|||
</and>
|
||||
</condition>
|
||||
<binding>
|
||||
<command>property-toggle</command>
|
||||
<property>autopilot/locks/passive-mode</property>
|
||||
<command>nasal</command>
|
||||
<script>
|
||||
if(getprop("autopilot/locks/passive-mode")==1){
|
||||
setprop("autopilot/locks/passive-mode",0);
|
||||
setprop("controls/flight/yaw-damper",1);
|
||||
}else{
|
||||
setprop("autopilot/locks/passive-mode",1);
|
||||
}
|
||||
</script>
|
||||
</binding>
|
||||
</action>
|
||||
|
||||
<action>
|
||||
<name>Low Bank</name>
|
||||
<button>0</button>
|
||||
<x>-24</x>
|
||||
<y>10</y>
|
||||
<w>18</w>
|
||||
<h>10</h>
|
||||
<binding>
|
||||
<property>autopilot/locks/passive-mode</property>
|
||||
<property>controls/flight/yaw-damper</property>
|
||||
</binding>
|
||||
<command>nasal</command>
|
||||
<script>
|
||||
var LB =getprop("autopilot/settings/low-bank-deg");
|
||||
if(LB ==27 or LB == nil){
|
||||
setprop("autopilot/settings/low-bank-deg",14);
|
||||
}else{
|
||||
setprop("autopilot/settings/low-bank-deg",27);
|
||||
}
|
||||
</script>
|
||||
</binding>
|
||||
</action>
|
||||
|
||||
<action>
|
||||
|
@ -56,9 +103,17 @@ P1000 AP controller hotspots
|
|||
<w>16</w>
|
||||
<h>10</h>
|
||||
<binding>
|
||||
<command>property-toggle</command>
|
||||
<property>controls/flight/yaw-damper</property>
|
||||
</binding>
|
||||
<command>nasal</command>
|
||||
<script>
|
||||
var YD=getprop("controls/flight/yaw-damper");
|
||||
if(YD==0 or YD == nil){
|
||||
setprop("controls/flight/yaw-damper",1);
|
||||
}else{
|
||||
setprop("autopilot/locks/passive-mode",1);
|
||||
setprop("controls/flight/yaw-damper",0);
|
||||
}
|
||||
</script>
|
||||
</binding>
|
||||
</action>
|
||||
|
||||
<action>
|
||||
|
@ -105,7 +160,7 @@ P1000 AP controller hotspots
|
|||
<binding>
|
||||
<command>property-adjust</command>
|
||||
<property>autopilot/settings/target-roll-deg</property>
|
||||
<step>-0.010000</step>
|
||||
<step>-0.10000</step>
|
||||
<min>-30</min>
|
||||
<max>30</max>
|
||||
<wrap>0</wrap>
|
||||
|
@ -122,7 +177,7 @@ P1000 AP controller hotspots
|
|||
<binding>
|
||||
<command>property-adjust</command>
|
||||
<property>autopilot/settings/target-roll-deg</property>
|
||||
<step>0.010000</step>
|
||||
<step>0.10000</step>
|
||||
<min>-30</min>
|
||||
<max>30</max>
|
||||
<wrap>0</wrap>
|
||||
|
@ -131,4 +186,4 @@ P1000 AP controller hotspots
|
|||
|
||||
</actions>
|
||||
|
||||
</PropertyList>
|
||||
</PropertyList>
|
Binary file not shown.
|
@ -8,31 +8,36 @@ var RAmode=props.globals.getNode("/instrumentation/primus1000/ra-mode",1);
|
|||
var DC550 = props.globals.getNode("/instrumentation/primus1000/dc550",1);
|
||||
var fms_enabled =0;
|
||||
|
||||
NavDist=props.globals.getNode("/instrumentation/primus1000/nav-dist-nm",1);
|
||||
NavType=props.globals.getNode("/instrumentation/primus1000/nav-type",1);
|
||||
NavString=props.globals.getNode("/instrumentation/primus1000/nav-string",1);
|
||||
NavID=props.globals.getNode("/instrumentation/primus1000/nav-id",1);
|
||||
FMSMode=props.globals.getNode("/instrumentation/primus1000/fms-mode",1);
|
||||
APoff=props.globals.getNode("/autopilot/locks/passive-mode",1);
|
||||
Hyd1=props.globals.getNode("systems/hydraulic/pump-psi[0]",1);
|
||||
Hyd2=props.globals.getNode("systems/hydraulic/pump-psi[1]",1);
|
||||
FuelPph1=props.globals.getNode("engines/engine[0]/fuel-flow_pph",1);
|
||||
FuelPph2=props.globals.getNode("engines/engine[1]/fuel-flow_pph",1);
|
||||
FuelDensity = 6.0;
|
||||
FMS_VNAV =["VNV","FMS"];
|
||||
NAV_SRC = ["VOR1","VOR2","ILS1","ILS2","FMS"];
|
||||
var NavDist=props.globals.getNode("/instrumentation/primus1000/nav-dist-nm",1);
|
||||
var NavType=props.globals.getNode("/instrumentation/primus1000/nav-type",1);
|
||||
var NavString=props.globals.getNode("/instrumentation/primus1000/nav-string",1);
|
||||
var NavID=props.globals.getNode("/instrumentation/primus1000/nav-id",1);
|
||||
var FMSMode=props.globals.getNode("/instrumentation/primus1000/fms-mode",1);
|
||||
var APoff=props.globals.getNode("/autopilot/locks/passive-mode",1);
|
||||
var Hyd1=props.globals.getNode("systems/hydraulic/pump-psi[0]",1);
|
||||
var Hyd2=props.globals.getNode("systems/hydraulic/pump-psi[1]",1);
|
||||
var FuelPph1=props.globals.getNode("engines/engine[0]/fuel-flow_pph",1);
|
||||
var FuelPph2=props.globals.getNode("engines/engine[1]/fuel-flow_pph",1);
|
||||
var FuelDensity = 6.0;
|
||||
var FMS_VNAV =["VNV","FMS"];
|
||||
var NAV_SRC = ["VOR1","VOR2","ILS1","ILS2","FMS"];
|
||||
var ET = aircraft.timer.new("/instrumentation/primus1000/pfd/ET-sec", 5,0);
|
||||
var ETmin = props.globals.getNode("/instrumentation/primus1000/pfd/ET-min",1);
|
||||
var EThour = props.globals.getNode("/instrumentation/primus1000/pfd/ET-hour",1);
|
||||
|
||||
get_pointer_offset = func{
|
||||
var get_pointer_offset = func{
|
||||
var test=arg[0];
|
||||
var src =arg[1];
|
||||
var offset = 0;
|
||||
var hdg = getprop("/orientation/heading-magnetic-deg");
|
||||
if(test==0 or test == nil){return 0.0;}
|
||||
|
||||
if(test == 1){
|
||||
if(src == 1){
|
||||
offset=getprop("/instrumentation/nav[1]/heading-deg");
|
||||
}else{
|
||||
offset=getprop("/instrumentation/nav/heading-deg");
|
||||
}
|
||||
if(offset == nil){offset=0.0;}
|
||||
offset -= hdg;
|
||||
if(offset < -180){offset += 360;}
|
||||
|
@ -45,10 +50,10 @@ get_pointer_offset = func{
|
|||
return offset;
|
||||
}
|
||||
|
||||
update_pfd = func{
|
||||
var update_pfd = func{
|
||||
|
||||
NavPtr1_offset.setValue(get_pointer_offset(NavPtr1.getValue()));
|
||||
NavPtr2_offset.setValue(get_pointer_offset(NavPtr2.getValue()));
|
||||
NavPtr1_offset.setValue(get_pointer_offset(NavPtr1.getValue(),0));
|
||||
NavPtr2_offset.setValue(get_pointer_offset(NavPtr2.getValue(),1));
|
||||
var id = " ";
|
||||
var GSPDstring = "";
|
||||
var nm_calc=0.0;
|
||||
|
@ -88,12 +93,12 @@ update_pfd = func{
|
|||
|
||||
|
||||
|
||||
update_mfd = func{
|
||||
var update_mfd = func{
|
||||
}
|
||||
|
||||
update_fuel = func{
|
||||
var total_fuel = 0;
|
||||
if(getprop("/sim/flight-model")=="yasim"){
|
||||
var update_fuel = func{
|
||||
var total_fuel = 0;
|
||||
if(getprop("/sim/flight-model")=="yasim"){
|
||||
FuelDensity=props.globals.getNode("consumables/fuel/tank[0]/density-ppg",1).getValue();
|
||||
var pph=getprop("/engines/engine[0]/fuel-flow-gph");
|
||||
if(pph == nil){pph = 0.0};
|
||||
|
@ -107,7 +112,7 @@ if(getprop("/sim/flight-model")=="yasim"){
|
|||
}
|
||||
}
|
||||
|
||||
update_eicas = func{
|
||||
var update_eicas = func{
|
||||
var hpsi = getprop("/engines/engine[0]/n2");
|
||||
if(hpsi == nil){hpsi=0.0;}
|
||||
hpsi = hpsi * 100;
|
||||
|
@ -121,8 +126,8 @@ update_eicas = func{
|
|||
update_fuel();
|
||||
}
|
||||
|
||||
setlistener("/instrumentation/primus1000/dc550/fms", func {
|
||||
var mode = cmdarg().getValue();
|
||||
setlistener("/instrumentation/primus1000/dc550/fms", func(md){
|
||||
var mode = md.getValue();
|
||||
FMSMode.setValue(FMS_VNAV[mode]);
|
||||
if(mode){NavType.setValue(4);
|
||||
fms_enabled=1;
|
||||
|
@ -130,11 +135,11 @@ var mode = cmdarg().getValue();
|
|||
NavType.setValue(0);
|
||||
fms_enabled=0;
|
||||
}
|
||||
});
|
||||
},0,0);
|
||||
|
||||
|
||||
|
||||
update_p1000 = func {
|
||||
var update_p1000 = func {
|
||||
update_pfd();
|
||||
update_mfd();
|
||||
update_eicas();
|
||||
|
|
|
@ -2,6 +2,36 @@
|
|||
<!--
|
||||
Author : Syd Adams
|
||||
Flight Mode Control
|
||||
|
||||
HDG:
|
||||
Heading Bug hold - Low Bank can be selected
|
||||
|
||||
NAV:
|
||||
Arm & Capture VOR , LOC or FMS
|
||||
|
||||
APR : (ILS approach)
|
||||
Arm & Capture VOR APR , LOC or BC
|
||||
Also arm and capture GS
|
||||
|
||||
BC :
|
||||
Arm & capture localizer backcourse
|
||||
Nav also illuminates
|
||||
|
||||
VNAV:
|
||||
Arm and capture VOR/DME or FMS vertical profile
|
||||
profile entered in MFD VNAV menu
|
||||
|
||||
ALT:
|
||||
Hold current Altitude or PFD preset altitude
|
||||
|
||||
VS:
|
||||
Hold current vertical speed ...
|
||||
adjustable with pitch wheel
|
||||
|
||||
SPD :
|
||||
Hold current speed
|
||||
adjustable with pitch wheel
|
||||
|
||||
-->
|
||||
<PropertyList>
|
||||
|
||||
|
@ -11,9 +41,9 @@ Flight Mode Control
|
|||
<type>material</type>
|
||||
<object-name>FD.btns</object-name>
|
||||
<emission>
|
||||
<red>0.025</red>
|
||||
<green>0.015</green>
|
||||
<blue>0.010</blue>
|
||||
<red>0.035</red>
|
||||
<green>0.025</green>
|
||||
<blue>0.015</blue>
|
||||
<factor-prop>systems/electrical/outputs/instrument-lights</factor-prop>
|
||||
</emission>
|
||||
</animation>
|
||||
|
@ -33,10 +63,10 @@ Flight Mode Control
|
|||
<type>select</type>
|
||||
<object-name>FD.nav</object-name>
|
||||
<condition>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/lnav</property>
|
||||
<value>2</value>
|
||||
</equals>
|
||||
<greater-than>
|
||||
<property>instrumentation/flightdirector/lnav</property>
|
||||
<value>1</value>
|
||||
</greater-than>
|
||||
</condition>
|
||||
</animation>
|
||||
|
||||
|
@ -44,10 +74,16 @@ Flight Mode Control
|
|||
<type>select</type>
|
||||
<object-name>FD.apr</object-name>
|
||||
<condition>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/lnav</property>
|
||||
<value>3</value>
|
||||
</equals>
|
||||
<and>
|
||||
<greater-than>
|
||||
<property>instrumentation/flightdirector/lnav</property>
|
||||
<value>3</value>
|
||||
</greater-than>
|
||||
<less-than>
|
||||
<property>instrumentation/flightdirector/lnav</property>
|
||||
<value>6</value>
|
||||
</less-than>
|
||||
</and>
|
||||
</condition>
|
||||
</animation>
|
||||
|
||||
|
@ -55,10 +91,10 @@ Flight Mode Control
|
|||
<type>select</type>
|
||||
<object-name>FD.bc</object-name>
|
||||
<condition>
|
||||
<equals>
|
||||
<greater-than>
|
||||
<property>instrumentation/flightdirector/lnav</property>
|
||||
<value>4</value>
|
||||
</equals>
|
||||
<value>5</value>
|
||||
</greater-than>
|
||||
</condition>
|
||||
</animation>
|
||||
|
||||
|
@ -66,10 +102,20 @@ Flight Mode Control
|
|||
<type>select</type>
|
||||
<object-name>FD.vnav</object-name>
|
||||
<condition>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>7</value>
|
||||
</equals>
|
||||
<or>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>1</value>
|
||||
</equals>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>2</value>
|
||||
</equals>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>6</value>
|
||||
</equals>
|
||||
</or>
|
||||
</condition>
|
||||
</animation>
|
||||
|
||||
|
@ -77,10 +123,16 @@ Flight Mode Control
|
|||
<type>select</type>
|
||||
<object-name>FD.alt</object-name>
|
||||
<condition>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>2</value>
|
||||
</equals>
|
||||
<or>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>3</value>
|
||||
</equals>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>4</value>
|
||||
</equals>
|
||||
</or>
|
||||
</condition>
|
||||
</animation>
|
||||
|
||||
|
@ -90,7 +142,7 @@ Flight Mode Control
|
|||
<condition>
|
||||
<equals>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>3</value>
|
||||
<value>5</value>
|
||||
</equals>
|
||||
</condition>
|
||||
</animation>
|
||||
|
|
|
@ -31,7 +31,16 @@ Primus 1000 Primary Flight Display
|
|||
<type>select</type>
|
||||
<object-name>FDbars</object-name>
|
||||
<condition>
|
||||
<property>instrumentation/primus1000/fdmode</property>
|
||||
<or>
|
||||
<greater-than>
|
||||
<property>instrumentation/flightdirector/lnav</property>
|
||||
<value>0</value>
|
||||
</greater-than>
|
||||
<greater-than>
|
||||
<property>instrumentation/flightdirector/vnav</property>
|
||||
<value>0</value>
|
||||
</greater-than>
|
||||
</or>
|
||||
</condition>
|
||||
</animation>
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue