Merge branch 'dev' into 3D
This commit is contained in:
commit
e7d83eac33
13 changed files with 204 additions and 127 deletions
|
@ -4788,7 +4788,6 @@
|
|||
<file>Aircraft/A320-family/Nasal/MCDU/PERFTO.nas</file>
|
||||
<file>Aircraft/A320-family/Nasal/MCDU/RADNAV.nas</file>
|
||||
<file>Aircraft/A320-family/Nasal/MCDU/DATA.nas</file>
|
||||
<file>Aircraft/A320-family/Nasal/MCDU/DATA2.nas</file>
|
||||
<file>Aircraft/A320-family/Nasal/MCDU/STATUS.nas</file>
|
||||
</mcdu>
|
||||
<!-- Traffic layer from E-jet -->
|
||||
|
|
|
@ -225,7 +225,7 @@ canvas.NavDisplay.newMFD = func(canvas_group, parent=nil, nd_options=nil, update
|
|||
# anything that needs updatecenter called, should be added to the vector here
|
||||
#
|
||||
foreach(var element; ["staFromL2","staToL2","staFromR2","staToR2",
|
||||
"hdgTrk","trkInd","hdgBug","HdgBugCRT","TrkBugLCD","HdgBugLCD","curHdgPtr",
|
||||
"hdgTrk","hdgBug","HdgBugCRT","TrkBugLCD","HdgBugLCD","curHdgPtr",
|
||||
"HdgBugCRT2","TrkBugLCD2","HdgBugLCD2","hdgBug2","selHdgLine","selHdgLine2","curHdgPtr2",
|
||||
"staToL","staFromL","staToR","staFromR"] )
|
||||
me.symbols[element] = me.nd.getElementById(element).updateCenter();
|
||||
|
@ -613,13 +613,11 @@ canvas.NavDisplay.update = func() # FIXME: This stuff is still too aircraft spec
|
|||
if((me.in_mode("toggle_display_mode", ["MAP"]) and me.get_switch("toggle_display_type") == "CRT")
|
||||
or (me.get_switch("toggle_track_heading") and me.get_switch("toggle_display_type") == "LCD"))
|
||||
{
|
||||
me.symbols.trkInd.setRotation(0);
|
||||
me.symbols.curHdgPtr.setRotation((userHdg-userTrk)*D2R);
|
||||
me.symbols.curHdgPtr2.setRotation((userHdg-userTrk)*D2R);
|
||||
}
|
||||
else
|
||||
{
|
||||
me.symbols.trkInd.setRotation((userTrk-userHdg)*D2R);
|
||||
me.symbols.curHdgPtr.setRotation(0);
|
||||
me.symbols.curHdgPtr2.setRotation(0);
|
||||
}
|
||||
|
@ -656,10 +654,6 @@ canvas.NavDisplay.update = func() # FIXME: This stuff is still too aircraft spec
|
|||
var adf0hdg = getprop("/instrumentation/adf/indicated-bearing-deg");
|
||||
var adf1hdg = getprop("/instrumentation/adf[1]/indicated-bearing-deg");
|
||||
if(!me.get_switch("toggle_centered")) {
|
||||
if(me.in_mode("toggle_display_mode", ["PLAN"]) or (me.adirs_property.getValue() != 1 or (me.change_phase == 1) and (adirs_3.getValue() != 1 or att_switch.getValue() != me.attitude_heading_setting)))
|
||||
me.symbols.trkInd.hide();
|
||||
else
|
||||
me.symbols.trkInd.show();
|
||||
if((getprop("/instrumentation/nav[2]/in-range") and me.get_switch("toggle_lh_vor_adf") == 1)) {
|
||||
me.symbols.staToL.setColor(0.195,0.96,0.097);
|
||||
me.symbols.staFromL.setColor(0.195,0.96,0.097);
|
||||
|
@ -713,7 +707,6 @@ canvas.NavDisplay.update = func() # FIXME: This stuff is still too aircraft spec
|
|||
}
|
||||
me.symbols.selHdgLine.setVisible(staPtrVis and hdg_bug_active);
|
||||
} else {
|
||||
me.symbols.trkInd.hide();
|
||||
if((getprop("/instrumentation/nav[2]/in-range") and me.get_switch("toggle_lh_vor_adf") == 1)) {
|
||||
me.symbols.staFromL2.setColor(0.195,0.96,0.097);
|
||||
me.symbols.staToL2.setColor(0.195,0.96,0.097);
|
||||
|
|
|
@ -23,8 +23,7 @@ var init = func {
|
|||
var draw = func{
|
||||
if(me.decel_grp != nil){
|
||||
var spd_ctrl = getprop(me.options.spd_ctrl);
|
||||
var spd_managed = (spd_ctrl == me.options.managed_val);
|
||||
if(spd_managed)
|
||||
if(spd_ctrl)
|
||||
me.decel_grp.setColor(me.style.managed_color);
|
||||
else
|
||||
me.decel_grp.setColor(me.style.selected_color);
|
||||
|
|
|
@ -82,7 +82,7 @@ var draw = func{
|
|||
var wp_group = me.element;
|
||||
var alt = me.model.alt;
|
||||
var i = me.model.idx;
|
||||
var vnav_actv = getprop(me.options.ver_ctrl) == me.options.managed_val;
|
||||
var vnav_actv = getprop(me.options.spd_ctrl) == 1;
|
||||
var curwp = getprop(me.options.current_wp);
|
||||
if(alt > 0){
|
||||
var wp_d = me.model.wp.distance_along_route;
|
||||
|
|
|
@ -1183,25 +1183,23 @@
|
|||
x="198.86594"
|
||||
y="648.10144">99</tspan></text>
|
||||
|
||||
<g
|
||||
id="trkInd"
|
||||
inkscape:label="#g3107"
|
||||
inkscape:transform-center-y="-318.607"
|
||||
inkscape:transform-center-x="-0.165"><path
|
||||
inkscape:transform-center-y="-715.775"
|
||||
inkscape:label="#path3882"
|
||||
sodipodi:nodetypes="cccc"
|
||||
inkscape:connector-curvature="0"
|
||||
id="curTrkPtr"
|
||||
d="M 494.187,150.9257 512.25,179.3894 530.312,150.9257 512.25,122.462 Z"
|
||||
style="display:inline;fill:none;stroke:#0dc04b;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /><path
|
||||
inkscape:label="#path6714"
|
||||
inkscape:transform-center-y="-436.38973"
|
||||
style="fill:none;stroke:#66b266;stroke-width:5.12176;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="M 512,179.04645 V 777.94594"
|
||||
id="trkline"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="cc" /><path
|
||||
<path
|
||||
style="display:inline;fill:none;stroke:#0dc04b;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="M 494.187,150.9257 512.25,179.3894 530.312,150.9257 512.25,122.462 Z"
|
||||
id="curTrkPtr"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="cccc"
|
||||
inkscape:label="#path3882"
|
||||
inkscape:transform-center-y="-673.07581"
|
||||
inkscape:transform-center-x="-0.25" /><path
|
||||
sodipodi:nodetypes="cc"
|
||||
inkscape:connector-curvature="0"
|
||||
id="trkline"
|
||||
d="M 512,179.04645 V 777.94594"
|
||||
style="fill:none;stroke:#66b266;stroke-width:5.12175989;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
inkscape:transform-center-y="-345.50518"
|
||||
inkscape:label="#path6714"
|
||||
inkscape:transform-center-x="-0.001953124" /><path
|
||||
style="fill:none;stroke:#ededed;stroke-width:5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="m 497.671,651.001 h 27.578"
|
||||
id="path3823"
|
||||
|
@ -1219,7 +1217,7 @@
|
|||
id="altArc"
|
||||
d="m 351.124,888.591 c 0,0 72.1,-39.455 161.041,-39.455 88.941,0 161.041,39.455 161.041,39.455 v 0"
|
||||
style="fill:none;stroke:#00ff00;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0"
|
||||
inkscape:label="#path3888-1" /></g>
|
||||
inkscape:label="#path3888-1" />
|
||||
<g
|
||||
inkscape:transform-center-x="-0.198874"
|
||||
inkscape:transform-center-y="4.4952743"
|
||||
|
@ -1614,22 +1612,24 @@
|
|||
inkscape:connector-curvature="0"
|
||||
id="path4921"
|
||||
d="m 97.36195,-183.49186 34.40958,0.79658 v 0"
|
||||
style="fill:none;stroke:#ff00ff;stroke-width:6.72142;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /></g><g
|
||||
id="trkInd2"
|
||||
inkscape:transform-center-y="-221.51123"><path
|
||||
id="curTrkPtr2"
|
||||
d="M 494.187,114.9257 512.25,143.3894 530.312,114.9257 512.25,86.462 Z"
|
||||
style="display:inline;fill:none;stroke:#0dc04b;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="cccccccc"
|
||||
inkscape:label="#path3998" /><path
|
||||
sodipodi:nodetypes="cc"
|
||||
inkscape:connector-curvature="0"
|
||||
id="trkline2"
|
||||
d="M 512,143.84995 V 525.93899"
|
||||
style="fill:none;stroke:#66b266;stroke-width:4.09095;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
inkscape:transform-center-y="-278.41021"
|
||||
inkscape:label="#path6714" /></g><path
|
||||
style="fill:none;stroke:#ff00ff;stroke-width:6.72142;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /></g>
|
||||
<path
|
||||
id="curTrkPtr2"
|
||||
d="M 494.187,114.9257 512.25,143.3894 530.312,114.9257 512.25,86.462 Z"
|
||||
style="display:inline;fill:none;stroke:#0dc04b;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="cccccccc"
|
||||
inkscape:label="#path3998"
|
||||
inkscape:transform-center-x="-0.28439381"
|
||||
inkscape:transform-center-y="-400.24318" /><path
|
||||
inkscape:label="#path6714"
|
||||
inkscape:transform-center-y="-195.62267"
|
||||
style="fill:none;stroke:#66b266;stroke-width:4.09095001;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="M 512,143.84995 V 525.93899"
|
||||
id="trkline2"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="cc"
|
||||
inkscape:transform-center-x="-0.16436971" /><path
|
||||
id="aplSymVor"
|
||||
style="fill:none;stroke:#ededed;stroke-width:5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="m 523.994,501.789 v 58 h 51.042 m -51.042,0 v 57 h 18.782 m -43.653,-115 v 58 h -50.158 m 50.158,0 v 57 h -19.136"
|
||||
|
|
Before Width: | Height: | Size: 150 KiB After Width: | Height: | Size: 150 KiB |
|
@ -529,7 +529,7 @@ canvas.NDStyles["Airbus"] = {
|
|||
var lat_ctrl = getprop(me.options.lat_ctrl);
|
||||
var is_managed = (lat_ctrl == me.options.managed_val);
|
||||
var is_active = getprop(me.options.fplan_active);
|
||||
(is_managed and is_active ? [] : [32, 16]);
|
||||
(is_managed and is_active ? [] : [12, 12]);
|
||||
},
|
||||
line_dash_alternate_active: [32,16],
|
||||
line_dash_temporary: [32,16],
|
||||
|
@ -561,6 +561,7 @@ canvas.NDStyles["Airbus"] = {
|
|||
"fplan_active",
|
||||
"lat_ctrl",
|
||||
"ver_ctrl",
|
||||
"spd_ctrl",
|
||||
"current_wp",
|
||||
"wp_count",
|
||||
"dep_rwy",
|
||||
|
@ -758,21 +759,14 @@ canvas.NDStyles["Airbus"] = {
|
|||
id: "tas",
|
||||
impl: {
|
||||
init: func(nd,symbol),
|
||||
predicate: func(nd) nd.aircraft_source.get_spd() > 100,
|
||||
predicate: func(nd) getprop("/instrumentation/airspeed-indicator/true-speed-kt") >= 60,
|
||||
is_true: func(nd) {
|
||||
nd.symbols.tas.setText(sprintf("%3.0f",getprop("/velocities/TAS") ));
|
||||
nd.symbols.tas.setText(sprintf("%3.0f",getprop("/instrumentation/airspeed-indicator/true-speed-kt")));
|
||||
nd.symbols.tas.show();
|
||||
},
|
||||
is_false: func(nd) nd.symbols.tas.hide(),
|
||||
},
|
||||
},
|
||||
{
|
||||
id: "tasLbl",
|
||||
impl: {
|
||||
init: func(nd,symbol),
|
||||
predicate: func(nd) nd.aircraft_source.get_spd() > 100,
|
||||
is_true: func(nd) nd.symbols.tasLbl.show(),
|
||||
is_false: func(nd) nd.symbols.tasLbl.hide(),
|
||||
is_false: func(nd){
|
||||
nd.symbols.tas.setText("---");
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
|
@ -1006,12 +1000,6 @@ canvas.NDStyles["Airbus"] = {
|
|||
impl: {
|
||||
init: func(nd,symbol),
|
||||
common: func(nd) nd.symbols.gs.setText(sprintf("%3.0f",nd.aircraft_source.get_gnd_spd() )),
|
||||
predicate: func(nd) nd.aircraft_source.get_gnd_spd() >= 30,
|
||||
is_true: func(nd) {
|
||||
#nd.symbols.gs.show();
|
||||
nd.symbols.gs.setFontSize(36);
|
||||
},
|
||||
is_false: func(nd) {},#nd.symbols.gs.hide(),
|
||||
},
|
||||
},
|
||||
{
|
||||
|
@ -1333,36 +1321,47 @@ canvas.NDStyles["Airbus"] = {
|
|||
is_false: func(nd) nd.symbols.dme.hide(),
|
||||
},
|
||||
},
|
||||
{
|
||||
id:"curTrkPtr",
|
||||
impl: {
|
||||
init: func(nd,symbol),
|
||||
predicate: func(nd) (nd.in_mode("toggle_display_mode", ["APP","VOR","MAP"]) and !nd.get_switch("toggle_centered")
|
||||
and (nd.adirs_property.getValue() == 1 or (adirs_3.getValue() == 1 and att_switch.getValue() == nd.attitude_heading_setting))
|
||||
and abs(nd.aircraft_source.get_trk_mag() - nd.aircraft_source.get_hdg_mag()) <= 42),
|
||||
is_true: func(nd) {
|
||||
nd.symbols.curTrkPtr.setRotation((nd.aircraft_source.get_trk_mag()-nd.aircraft_source.get_hdg_mag())*D2R);
|
||||
nd.symbols.curTrkPtr.show();
|
||||
},
|
||||
is_false: func(nd) nd.symbols.curTrkPtr.hide(),
|
||||
},
|
||||
},
|
||||
{
|
||||
id:"trkline",
|
||||
impl: {
|
||||
init: func(nd,symbol),
|
||||
predicate: func(nd){
|
||||
nd.get_switch("toggle_display_mode") == "MAP" and !nd.get_switch("toggle_centered")
|
||||
and (nd.change_phase != 1)
|
||||
and (
|
||||
getprop(nd.options.defaults.lat_ctrl) != nd.options.defaults.managed_val or
|
||||
nd.get_switch("toggle_trk_line")
|
||||
)
|
||||
},
|
||||
predicate: func(nd) (nd.get_switch("toggle_display_mode") == "MAP" and
|
||||
!nd.get_switch("toggle_centered") and (nd.change_phase != 1) and
|
||||
getprop(nd.options.defaults.lat_ctrl) == 0 and abs(nd.aircraft_source.get_trk_mag() - nd.aircraft_source.get_hdg_mag()) <= 42 and
|
||||
(nd.adirs_property.getValue() == 1 or (adirs_3.getValue() == 1 and att_switch.getValue() == nd.attitude_heading_setting))),
|
||||
is_true: func(nd) {
|
||||
nd.symbols.trkline.setRotation((nd.aircraft_source.get_trk_mag()-nd.aircraft_source.get_hdg_mag())*D2R);
|
||||
nd.symbols.trkline.show();
|
||||
},
|
||||
is_false: func(nd) nd.symbols.trkline.hide(),
|
||||
},
|
||||
},
|
||||
{
|
||||
id:"trkInd2",
|
||||
id:"curTrkPtr2",
|
||||
impl: {
|
||||
init: func(nd,symbol),
|
||||
predicate: func(nd) (nd.in_mode("toggle_display_mode", ["APP","VOR","MAP"]) and nd.get_switch("toggle_centered")
|
||||
and (nd.change_phase != 1)
|
||||
and (nd.adirs_property.getValue() == 1 or (adirs_3.getValue() == 1 and att_switch.getValue() == nd.attitude_heading_setting))),
|
||||
and (nd.adirs_property.getValue() == 1 or (adirs_3.getValue() == 1 and att_switch.getValue() == nd.attitude_heading_setting))
|
||||
and abs(nd.aircraft_source.get_trk_mag() - nd.aircraft_source.get_hdg_mag()) <= 42),
|
||||
is_true: func(nd) {
|
||||
nd.symbols.trkInd2.show();
|
||||
nd.symbols.trkInd2.setRotation((nd.aircraft_source.get_trk_mag()-nd.aircraft_source.get_hdg_mag())*D2R);
|
||||
nd.symbols.curTrkPtr2.setRotation((nd.aircraft_source.get_trk_mag()-nd.aircraft_source.get_hdg_mag())*D2R);
|
||||
nd.symbols.curTrkPtr2.show();
|
||||
},
|
||||
is_false: func(nd) nd.symbols.trkInd2.hide(),
|
||||
is_false: func(nd) nd.symbols.curTrkPtr2.hide(),
|
||||
},
|
||||
},
|
||||
{
|
||||
|
@ -1371,9 +1370,10 @@ canvas.NDStyles["Airbus"] = {
|
|||
init: func(nd,symbol),
|
||||
predicate: func(nd) (nd.get_switch("toggle_display_mode") == "MAP" and
|
||||
nd.get_switch("toggle_centered") and (nd.change_phase != 1) and
|
||||
getprop(nd.options.defaults.lat_ctrl) != nd.options.defaults.managed_val and
|
||||
(nd.adirs_property.getValue() == 1 or (adirs_3.getValue() == 1 and att_switch.getValue() == nd.attitude_heading_setting))),
|
||||
getprop(nd.options.defaults.lat_ctrl) == 0 and abs(nd.aircraft_source.get_trk_mag() - nd.aircraft_source.get_hdg_mag()) <= 42 and
|
||||
(nd.adirs_property.getValue() == 1 or (adirs_3.getValue() == 1 and att_switch.getValue() == nd.attitude_heading_setting))),
|
||||
is_true: func(nd) {
|
||||
nd.symbols.trkline2.setRotation((nd.aircraft_source.get_trk_mag()-nd.aircraft_source.get_hdg_mag())*D2R);
|
||||
nd.symbols.trkline2.show();
|
||||
},
|
||||
is_false: func(nd) nd.symbols.trkline2.hide(),
|
||||
|
@ -1530,35 +1530,24 @@ canvas.NDStyles["Airbus"] = {
|
|||
id:"wind",
|
||||
impl: {
|
||||
init: func(nd,symbol),
|
||||
predicate: ALWAYS,
|
||||
predicate: func(nd) (getprop("/instrumentation/airspeed-indicator/true-speed-kt") >= 100),
|
||||
is_true: func(nd) {
|
||||
var windDir = getprop("environment/wind-from-heading-deg");
|
||||
if(!nd.get_switch("toggle_true_north"))
|
||||
windDir = windDir + getprop("environment/magnetic-variation-deg");
|
||||
nd.symbols.wind.setText(sprintf("%03.0f / %02.0f",windDir,getprop("environment/wind-speed-kt")));
|
||||
var windDir = pts.Instrumentation.PFD.windDirection.getValue() or 0;
|
||||
nd.symbols.wind.setText(sprintf("%03.0f / %02.0f",windDir,pts.Instrumentation.PFD.windSpeed.getValue() or 0));
|
||||
},
|
||||
is_false: NOTHING,
|
||||
is_false: func(nd) {
|
||||
nd.symbols.wind.setText("---/--");
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
id:"windArrow",
|
||||
impl: {
|
||||
init: func(nd,symbol),
|
||||
predicate: func(nd) (!(nd.in_mode("toggle_display_mode", ["PLAN"]) and (nd.get_switch("toggle_display_type") == "LCD"))),
|
||||
predicate: func(nd) (!(nd.in_mode("toggle_display_mode", ["PLAN"]) and (nd.get_switch("toggle_display_type") == "LCD")) and (pts.Instrumentation.PFD.windSpeed.getValue() or 0) >= 2 and getprop("/instrumentation/airspeed-indicator/true-speed-kt") >= 100),
|
||||
is_true: func(nd) {
|
||||
nd.symbols.windArrow.show();
|
||||
var windArrowRot = getprop("environment/wind-from-heading-deg");
|
||||
if(nd.in_mode("toggle_display_mode", ["MAP","PLAN"])) {
|
||||
if(nd.get_switch("toggle_true_north"))
|
||||
windArrowRot = windArrowRot - nd.aircraft_source.get_trk_tru();
|
||||
else
|
||||
windArrowRot = windArrowRot - nd.aircraft_source.get_trk_mag();
|
||||
} else {
|
||||
if(nd.get_switch("toggle_true_north"))
|
||||
windArrowRot = windArrowRot - nd.aircraft_source.get_hdg_tru();
|
||||
else
|
||||
windArrowRot = windArrowRot - nd.aircraft_source.get_hdg_mag();
|
||||
}
|
||||
var windArrowRot = (pts.Instrumentation.PFD.windDirection.getValue() or 0) - nd.aircraft_source.get_hdg_tru();
|
||||
nd.symbols.windArrow.setRotation(windArrowRot*D2R);
|
||||
},
|
||||
is_false: func(nd) nd.symbols.windArrow.hide(),
|
||||
|
|
|
@ -213,7 +213,7 @@ var Instrumentation = {
|
|||
MKVII: {
|
||||
Inputs: {
|
||||
Discretes: {
|
||||
flap3Override: props.globals.getNode("/instrumentation/mk-viii/inputs/discretes/momentary-flap3-override"),
|
||||
flap3Override: props.globals.getNode("/instrumentation/mk-viii/inputs/discretes/momentary-flap-3-override"),
|
||||
},
|
||||
},
|
||||
},
|
||||
|
@ -221,6 +221,10 @@ var Instrumentation = {
|
|||
gsDeflection: props.globals.getNode("/instrumentation/nav[0]/gs-needle-deflection-norm"),
|
||||
locDeflection: props.globals.getNode("/instrumentation/nav[0]/heading-needle-deflection-norm"),
|
||||
},
|
||||
PFD: {
|
||||
windDirection: props.globals.getNode("/instrumentation/pfd/wind-direction"),
|
||||
windSpeed: props.globals.getNode("/instrumentation/pfd/wind-speed"),
|
||||
},
|
||||
TCAS: {
|
||||
servicable: props.globals.getNode("/instrumentation/tcas/serviceable"),
|
||||
Inputs: {
|
||||
|
|
|
@ -60,3 +60,15 @@ var printInput2 = func(key, i) {
|
|||
setprop("FMGC/print/mcdu/page2/R4req", 1);
|
||||
}
|
||||
}
|
||||
|
||||
var data2Input = func(key, i) {
|
||||
if (key == "L5") {
|
||||
if (canvas_mcdu.myCLBWIND[i] == nil) {
|
||||
canvas_mcdu.myCLBWIND[i] = windCLBPage.new(i);
|
||||
} else {
|
||||
canvas_mcdu.myCLBWIND[i].reload();
|
||||
}
|
||||
fmgc.windController.accessPage[i] = "DATA2";
|
||||
setprop("MCDU[" ~ i ~ "]/page", "WINDCLB");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,15 +0,0 @@
|
|||
# A3XX mCDU by Joshua Davidson (Octal450), Jonathan Redpath, and Matthew Maring (mattmaring)
|
||||
|
||||
# Copyright (c) 2020 Matthew Maring (mattmaring)
|
||||
|
||||
var data2Input = func(key, i) {
|
||||
if (key == "L5") {
|
||||
if (canvas_mcdu.myCLBWIND[i] == nil) {
|
||||
canvas_mcdu.myCLBWIND[i] = windCLBPage.new(i);
|
||||
} else {
|
||||
canvas_mcdu.myCLBWIND[i].reload();
|
||||
}
|
||||
fmgc.windController.accessPage[i] = "DATA2";
|
||||
setprop("MCDU[" ~ i ~ "]/page", "WINDCLB");
|
||||
}
|
||||
}
|
|
@ -168,6 +168,7 @@ var MCDU_reset = func(i) {
|
|||
setprop("/FMGC/internal/eng-out-reduc", "1500");
|
||||
setprop("/MCDUC/reducacc-set", 0);
|
||||
fmgc.FMGCInternal.transAlt = 18000;
|
||||
fmgc.FMGCInternal.transAltSet = 0;
|
||||
|
||||
# CLB PERF
|
||||
setprop("/FMGC/internal/activate-once", 0);
|
||||
|
|
|
@ -530,7 +530,7 @@
|
|||
<property>/systems/navigation/probes/tat-1/tat</property>
|
||||
<quotient>
|
||||
<pow>
|
||||
<property>/velocities/TAS</property>
|
||||
<property>/instrumentation/airspeed-indicator/true-speed-kt</property>
|
||||
<value>2</value>
|
||||
</pow>
|
||||
<value>7569</value>
|
||||
|
|
|
@ -577,14 +577,6 @@
|
|||
<output>/systems/pressurization/targetvs</output>
|
||||
</filter>
|
||||
|
||||
<filter>
|
||||
<name>TAS</name>
|
||||
<type>gain</type>
|
||||
<gain>1.0</gain>
|
||||
<input>/instrumentation/airspeed-indicator/true-speed-kt</input>
|
||||
<output>/velocities/TAS</output>
|
||||
</filter>
|
||||
|
||||
<filter>
|
||||
<name>LBtoKG</name>
|
||||
<type>gain</type>
|
||||
|
|
103
Systems/pfd.xml
103
Systems/pfd.xml
|
@ -573,5 +573,108 @@
|
|||
</input>
|
||||
<output>/instrumentation/iesi/pitch-deg</output>
|
||||
</filter>
|
||||
|
||||
<filter>
|
||||
<name>Wind East</name>
|
||||
<type>gain</type>
|
||||
<gain>1.0</gain>
|
||||
<input>
|
||||
<expression>
|
||||
<difference>
|
||||
<product>
|
||||
<property>/velocities/speed-east-fps</property>
|
||||
<value>0.592484</value> <!-- fps to kt -->
|
||||
</product>
|
||||
<product>
|
||||
<cos><deg2rad><property>/orientation/pitch-deg</property></deg2rad></cos>
|
||||
<sin><deg2rad><property>/orientation/heading-deg</property></deg2rad></sin>
|
||||
<!--<floor>-->
|
||||
<property>/systems/navigation/adr/output/tas-3</property>
|
||||
<!--<value>100</value>
|
||||
</floor>-->
|
||||
</product>
|
||||
</difference>
|
||||
</expression>
|
||||
</input>
|
||||
<output>/instrumentation/pfd/wind-speed-east</output>
|
||||
<min>-4096</min>
|
||||
<max>4096</max>
|
||||
</filter>
|
||||
|
||||
<filter>
|
||||
<name>Wind North</name>
|
||||
<type>gain</type>
|
||||
<gain>1.0</gain>
|
||||
<input>
|
||||
<expression>
|
||||
<difference>
|
||||
<product>
|
||||
<property>/velocities/speed-north-fps</property>
|
||||
<value>0.592484</value> <!-- fps to kt -->
|
||||
</product>
|
||||
<product>
|
||||
<cos><deg2rad><property>/orientation/pitch-deg</property></deg2rad></cos>
|
||||
<cos><deg2rad><property>/orientation/heading-deg</property></deg2rad></cos>
|
||||
<!--<floor>-->
|
||||
<property>/systems/navigation/adr/output/tas-3</property>
|
||||
<!--<value>100</value>
|
||||
</floor>-->
|
||||
</product>
|
||||
</difference>
|
||||
</expression>
|
||||
</input>
|
||||
<output>/instrumentation/pfd/wind-speed-north</output>
|
||||
<min>-4096</min>
|
||||
<max>4096</max>
|
||||
</filter>
|
||||
|
||||
<filter>
|
||||
<name>Wind Direction</name>
|
||||
<type>exponential</type>
|
||||
<filter-time>1.28</filter-time>
|
||||
<input>
|
||||
<expression>
|
||||
<sum>
|
||||
<rad2deg>
|
||||
<atan2>
|
||||
<property>/instrumentation/pfd/wind-speed-east</property>
|
||||
<property>/instrumentation/pfd/wind-speed-north</property>
|
||||
</atan2>
|
||||
</rad2deg>
|
||||
<value>180</value>
|
||||
</sum>
|
||||
</expression>
|
||||
</input>
|
||||
<output>/instrumentation/pfd/wind-direction</output>
|
||||
<period>
|
||||
<min>0</min>
|
||||
<max>360</max>
|
||||
</period>
|
||||
</filter>
|
||||
|
||||
<filter>
|
||||
<name>Wind Speed</name>
|
||||
<type>exponential</type>
|
||||
<filter-time>1.28</filter-time>
|
||||
<input>
|
||||
<expression>
|
||||
<sqrt>
|
||||
<sum>
|
||||
<pow>
|
||||
<property>/instrumentation/pfd/wind-speed-east</property>
|
||||
<value>2</value>
|
||||
</pow>
|
||||
<pow>
|
||||
<property>/instrumentation/pfd/wind-speed-north</property>
|
||||
<value>2</value>
|
||||
</pow>
|
||||
</sum>
|
||||
</sqrt>
|
||||
</expression>
|
||||
</input>
|
||||
<output>/instrumentation/pfd/wind-speed</output>
|
||||
<min>0</min>
|
||||
<max>256</max>
|
||||
</filter>
|
||||
|
||||
</PropertyList>
|
||||
|
|
Loading…
Add table
Reference in a new issue