Skip to content

Commit

Permalink
independant ECC pids for GE/PW/RR
Browse files Browse the repository at this point in the history
  • Loading branch information
mSparks43 committed Dec 27, 2022
1 parent 9977cea commit e61e52c
Show file tree
Hide file tree
Showing 11 changed files with 215 additions and 58 deletions.
86 changes: 75 additions & 11 deletions 747-400.acf
Original file line number Diff line number Diff line change
Expand Up @@ -120117,9 +120117,9 @@ GROUP Upper EICAS

END_GROUP
END_GROUP
GROUP EPR Thrust Command
GROUP Thrust Command EPR RR
SHOW_LESS 1.000000 sim/cockpit2/annunciators/reverser_deployed
SHOW_EQUAL 0.000000 laminar/B747/engines/thrust_ref
SHOW_EQUAL 2.000000 laminar/B747/engines/type
gen_pointer Engine 4
POS 1748.500000 942.000000
IMAGE CRT Displays/EICAS Upper/N1_thrust
Expand Down Expand Up @@ -120173,6 +120173,62 @@ GROUP Upper EICAS
OFFSET 0.000000

END_GROUP
GROUP Thrust Command EPR PW
SHOW_LESS 1.000000 sim/cockpit2/annunciators/reverser_deployed
SHOW_EQUAL 0.000000 laminar/B747/engines/type
gen_pointer Engine 4
POS 1748.500000 942.000000
IMAGE CRT Displays/EICAS Upper/N1_thrust
DATAREF laminar/B747/engines/TRA[3]
LIGHT_MODE GLASS_AUTO
LIGHT_RHEOSTAT 10
BUS_SRC 2
KEY_FRAME 0.850000 -67.000000 1.000000
KEY_FRAME 1.750000 67.000000
IS_DRAGGABLE 0
IS_VERTICAL 1
OFFSET 0.000000

gen_pointer Engine 3
POS 1642.500000 942.000000
IMAGE CRT Displays/EICAS Upper/N1_thrust
DATAREF laminar/B747/engines/TRA[2]
LIGHT_MODE GLASS_AUTO
LIGHT_RHEOSTAT 10
BUS_SRC 2
KEY_FRAME 0.850000 -67.000000 1.000000
KEY_FRAME 1.750000 67.000000
IS_DRAGGABLE 0
IS_VERTICAL 1
OFFSET 0.000000

gen_pointer Engine 2
POS 1536.500000 942.000000
IMAGE CRT Displays/EICAS Upper/N1_thrust
DATAREF laminar/B747/engines/TRA[1]
LIGHT_MODE GLASS_AUTO
LIGHT_RHEOSTAT 10
BUS_SRC 2
KEY_FRAME 0.850000 -67.000000 1.000000
KEY_FRAME 1.750000 67.000000
IS_DRAGGABLE 0
IS_VERTICAL 1
OFFSET 0.000000

gen_pointer Engine 1
POS 1430.500000 942.000000
IMAGE CRT Displays/EICAS Upper/N1_thrust
DATAREF laminar/B747/engines/TRA[0]
LIGHT_MODE GLASS_AUTO
LIGHT_RHEOSTAT 10
BUS_SRC 2
KEY_FRAME 0.850000 -67.000000 1.000000
KEY_FRAME 1.750000 67.000000
IS_DRAGGABLE 0
IS_VERTICAL 1
OFFSET 0.000000

END_GROUP
END_GROUP
GROUP N1
GROUP N1 Tape
Expand Down Expand Up @@ -121308,7 +121364,7 @@ GROUP Upper EICAS
LED_ROWS 4

END_GROUP
GROUP N1 Thrust Command G
GROUP Thrust Command N1 GE
SHOW_LESS 1.000000 sim/cockpit2/annunciators/reverser_deployed
SHOW_EQUAL 1.000000 laminar/B747/engines/type
gen_pointer Engine 4
Expand All @@ -121319,8 +121375,10 @@ GROUP Upper EICAS
LIGHT_MODE GLASS_AUTO
LIGHT_RHEOSTAT 10
BUS_SRC 2
KEY_FRAME 0.850000 -67.000000 1.000000
KEY_FRAME 1.950000 67.000000
KEY_FRAME -100.0000 -67.000000 1.000000
KEY_FRAME 31.0000 -67.000000 1.000000
KEY_FRAME 116.0000 102.000000
KEY_FRAME 200.0000 102.000000
IS_DRAGGABLE 0
IS_VERTICAL 1
OFFSET 0.000000
Expand All @@ -121333,8 +121391,10 @@ GROUP Upper EICAS
LIGHT_MODE GLASS_AUTO
LIGHT_RHEOSTAT 10
BUS_SRC 2
KEY_FRAME 0.850000 -67.000000 1.000000
KEY_FRAME 1.950000 67.000000
KEY_FRAME -100.0000 -67.000000 1.000000
KEY_FRAME 31.0000 -67.000000 1.000000
KEY_FRAME 116.0000 102.000000
KEY_FRAME 200.0000 102.000000
IS_DRAGGABLE 0
IS_VERTICAL 1
OFFSET 0.000000
Expand All @@ -121347,8 +121407,10 @@ GROUP Upper EICAS
LIGHT_MODE GLASS_AUTO
LIGHT_RHEOSTAT 10
BUS_SRC 2
KEY_FRAME 0.850000 -67.000000 1.000000
KEY_FRAME 1.950000 67.000000
KEY_FRAME -100.0000 -67.000000 1.000000
KEY_FRAME 31.0000 -67.000000 1.000000
KEY_FRAME 116.0000 102.000000
KEY_FRAME 200.0000 102.000000
IS_DRAGGABLE 0
IS_VERTICAL 1
OFFSET 0.000000
Expand All @@ -121361,8 +121423,10 @@ GROUP Upper EICAS
LIGHT_MODE GLASS_AUTO
LIGHT_RHEOSTAT 10
BUS_SRC 2
KEY_FRAME 0.850000 -67.000000 1.000000
KEY_FRAME 1.950000 67.000000
KEY_FRAME -100.0000 -67.000000 1.000000
KEY_FRAME 31.0000 -67.000000 1.000000
KEY_FRAME 116.0000 102.000000
KEY_FRAME 200.0000 102.000000
IS_DRAGGABLE 0
IS_VERTICAL 1
OFFSET 0.000000
Expand Down
Binary file modified README.pdf
Binary file not shown.
14 changes: 11 additions & 3 deletions plugins/xtlua/init/scripts/B747.42.EEC/B747.42.EEC.lua
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,15 @@ B747DR_throttle_resolver_angle = deferred_dataref("laminar/B747/engines/TRA", "
B747DR_log_level = deferred_dataref("laminar/B747/engines/logging", "number") --true / false

B747DR_pidthrottleP = deferred_dataref("laminar/B747/flt_ctrls/pid/throttle/p", "number")
B747DR_pidthrottleHP = deferred_dataref("laminar/B747/flt_ctrls/pid/throttle/highp", "number")
B747DR_pidthrottleLP = deferred_dataref("laminar/B747/flt_ctrls/pid/throttle/lowp", "number")
--B747DR_pidthrottleHP = deferred_dataref("laminar/B747/flt_ctrls/pid/throttle/highp", "number")
--B747DR_pidthrottleLP = deferred_dataref("laminar/B747/flt_ctrls/pid/throttle/lowp", "number")
B747DR_pidthrottleI = deferred_dataref("laminar/B747/flt_ctrls/pid/throttle/i", "number")
B747DR_pidthrottleD = deferred_dataref("laminar/B747/flt_ctrls/pid/throttle/d", "number")
B747DR_pidthrottleD = deferred_dataref("laminar/B747/flt_ctrls/pid/throttle/d", "number")

B747DR_pideccI = deferred_dataref("laminar/B747/flt_ctrls/pid/ecc/N1/i", "number")
B747DR_pideccD = deferred_dataref("laminar/B747/flt_ctrls/pid/ecc/N1/d", "number")
B747DR_pideccP = deferred_dataref("laminar/B747/flt_ctrls/pid/ecc/N1/p", "number")

B747DR_pidepr_eccI = deferred_dataref("laminar/B747/flt_ctrls/pid/ecc/epr/i", "number")
B747DR_pidepr_eccD = deferred_dataref("laminar/B747/flt_ctrls/pid/ecc/epr/d", "number")
B747DR_pidepr_eccP = deferred_dataref("laminar/B747/flt_ctrls/pid/ecc/epr/p", "number")
Original file line number Diff line number Diff line change
Expand Up @@ -2309,13 +2309,14 @@ function B747_throttle_animation()
B747DR_throttle[i]=B747_interpolate_value(B747DR_throttle[i],0,0,1,1)
else
B747DR_throttle_reversor[i]=B747_interpolate_value(B747DR_throttle_reversor[i],0,-1,0,1)
if B747DR_ap_FMA_autothrottle_mode==0 or B747DR_ap_FMA_autothrottle_mode==1 then
--[[ if B747DR_ap_FMA_autothrottle_mode==0 or B747DR_ap_FMA_autothrottle_mode==1 then
B747DR_throttle[i]=B747_interpolate_value(B747DR_throttle[i],simDR_engn_thro[i],0,1,0.5)
--print("manual speed throttle")
else
--print("auto speed throttle")
B747DR_throttle[i]=simDR_engn_thro[i] --B747_interpolate_value(B747DR_throttle[i],simDR_engn_thro[i],0,1,2)
end
end]]--
B747DR_throttle[i]=simDR_engn_thro[i]
end
end

Expand Down
1 change: 1 addition & 0 deletions plugins/xtlua/scripts/B747.05.xt.simconfig/version.lua
Original file line number Diff line number Diff line change
Expand Up @@ -149,3 +149,4 @@ fmcVersion="XP1150-2022/12/22 03:27"
fmcVersion="XP1150-2022/12/26 19:54"
fmcVersion="XP1150-2022/12/27 01:48"
fmcVersion="XP1150-2022/12/27 03:05"
fmcVersion="XP1150-2022/12/27 20:56"
7 changes: 4 additions & 3 deletions plugins/xtlua/scripts/B747.42.xt.EEC/B747.42.xt.EEC.GE.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@ function throttle_resolver_angle_GE(engine_in)

thrust_ratio_factor = B747DR_display_N1_max[engine_in] / 116.0 --117.5

throttle_angle = (3.022549485226715E-03 + 1.441727698320892E+00 * simDR_throttle_ratio[engine_in] + -9.568752920557220E-01 * simDR_throttle_ratio[engine_in]^2
+ 9.989724112918770E-01 * simDR_throttle_ratio[engine_in]^3 + -4.927345191979758E-01 * simDR_throttle_ratio[engine_in]^4) * thrust_ratio_factor
--throttle_angle = (3.022549485226715E-03 + 1.441727698320892E+00 * simDR_throttle_ratio[engine_in] + -9.568752920557220E-01 * simDR_throttle_ratio[engine_in]^2
-- + 9.989724112918770E-01 * simDR_throttle_ratio[engine_in]^3 + -4.927345191979758E-01 * simDR_throttle_ratio[engine_in]^4) * thrust_ratio_factor

local N1_target=B747_rescale(0.0, 0.75, 0.88, 2.05, throttle_angle)
--local N1_target=B747_rescale(0.0, 0, 1.0, 116.0, throttle_angle)
local N1_target=B747_rescale(0.0, 31.0, 1.0, 116.0, simDR_throttle_ratio[engine_in])
if B747DR_log_level == -1 then
print("Thrust Factor = ", thrust_ratio_factor)
print("TRA = ", throttle_angle)
Expand Down
2 changes: 1 addition & 1 deletion plugins/xtlua/scripts/B747.42.xt.EEC/B747.42.xt.EEC.RR.lua
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ function throttle_resolver_angle_RR(engine_in)
end
return EPR_actual]]--

local EPR_target=B747_rescale(0.0, 1.0, 1.0, B747DR_display_EPR_max[engine_in], simDR_throttle_ratio[engine_in])
local EPR_target=B747_rescale(0.0, 1.0, 0.9, B747DR_display_EPR_max[engine_in]*0.99, simDR_throttle_ratio[engine_in])
return EPR_target
end

Expand Down
Loading

0 comments on commit e61e52c

Please sign in to comment.