Merge branch 'dev' of https://github.com/vezza/A320-family into vezza-dev
This commit is contained in:
commit
fe39d698a3
3 changed files with 88 additions and 80 deletions
|
@ -125615,66 +125615,66 @@ numsurf 9
|
|||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
10 0.47656 0.391728
|
||||
3 0.486374 0.402462
|
||||
1 0.486374 0.503675
|
||||
5 0.47656 0.514408
|
||||
10 0.481443 0.383916
|
||||
3 0.491257 0.39465
|
||||
1 0.491257 0.495862
|
||||
5 0.481443 0.506595
|
||||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
5 0.47656 0.514408
|
||||
1 0.486374 0.503675
|
||||
2 0.58962 0.503675
|
||||
7 0.599434 0.514408
|
||||
5 0.481443 0.506595
|
||||
1 0.491257 0.495862
|
||||
2 0.594503 0.495862
|
||||
7 0.604317 0.506595
|
||||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
2 0.58962 0.503675
|
||||
0 0.58962 0.402462
|
||||
8 0.599434 0.391728
|
||||
7 0.599434 0.514408
|
||||
2 0.594503 0.495862
|
||||
0 0.594503 0.39465
|
||||
8 0.604317 0.383916
|
||||
7 0.604317 0.506595
|
||||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
6 0.47656 0.514408
|
||||
5 0.47656 0.514408
|
||||
7 0.599434 0.514408
|
||||
4 0.599434 0.514408
|
||||
6 0.481443 0.506595
|
||||
5 0.481443 0.506595
|
||||
7 0.604317 0.506595
|
||||
4 0.604317 0.506595
|
||||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
9 0.47656 0.391728
|
||||
10 0.47656 0.391728
|
||||
5 0.47656 0.514408
|
||||
6 0.47656 0.514408
|
||||
9 0.481443 0.383916
|
||||
10 0.481443 0.383916
|
||||
5 0.481443 0.506595
|
||||
6 0.481443 0.506595
|
||||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
0 0.58962 0.402462
|
||||
3 0.486374 0.402462
|
||||
10 0.47656 0.391728
|
||||
8 0.599434 0.391728
|
||||
0 0.594503 0.39465
|
||||
3 0.491257 0.39465
|
||||
10 0.481443 0.383916
|
||||
8 0.604317 0.383916
|
||||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
10 0.47656 0.391728
|
||||
9 0.47656 0.391728
|
||||
11 0.599434 0.391728
|
||||
8 0.599434 0.391728
|
||||
10 0.481443 0.383916
|
||||
9 0.481443 0.383916
|
||||
11 0.604317 0.383916
|
||||
8 0.604317 0.383916
|
||||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
7 0.599434 0.514408
|
||||
8 0.599434 0.391728
|
||||
11 0.599434 0.391728
|
||||
4 0.599434 0.514408
|
||||
7 0.604317 0.506595
|
||||
8 0.604317 0.383916
|
||||
11 0.604317 0.383916
|
||||
4 0.604317 0.506595
|
||||
SURF 0X0
|
||||
mat 23
|
||||
refs 4
|
||||
2 0.58962 0.503675
|
||||
1 0.486374 0.503675
|
||||
3 0.486374 0.402462
|
||||
0 0.58962 0.402462
|
||||
2 0.594503 0.495862
|
||||
1 0.491257 0.495862
|
||||
3 0.491257 0.39465
|
||||
0 0.594503 0.39465
|
||||
kids 0
|
||||
OBJECT poly
|
||||
name "brk_fan_on"
|
||||
|
@ -125693,12 +125693,12 @@ numsurf 1
|
|||
SURF 0X0
|
||||
mat 23
|
||||
refs 6
|
||||
5 0.538342 0.33137
|
||||
2 0.487204 0.33137
|
||||
0 0.487204 0.280682
|
||||
4 0.538342 0.280682
|
||||
1 0.58948 0.280682
|
||||
3 0.58948 0.33137
|
||||
5 0.542737 0.322093
|
||||
2 0.491599 0.322093
|
||||
0 0.491599 0.271405
|
||||
4 0.542737 0.271405
|
||||
1 0.593875 0.271405
|
||||
3 0.593875 0.322093
|
||||
kids 0
|
||||
OBJECT poly
|
||||
name "brk_hot_on"
|
||||
|
@ -125717,12 +125717,12 @@ numsurf 1
|
|||
SURF 0X0
|
||||
mat 23
|
||||
refs 6
|
||||
5 0.486738 0.395321
|
||||
3 0.486738 0.344632
|
||||
0 0.537876 0.344632
|
||||
2 0.589014 0.344632
|
||||
4 0.589014 0.395321
|
||||
1 0.537876 0.395321
|
||||
5 0.489179 0.378231
|
||||
3 0.489179 0.327542
|
||||
0 0.540317 0.327542
|
||||
2 0.591455 0.327542
|
||||
4 0.591455 0.378231
|
||||
1 0.540317 0.378231
|
||||
kids 0
|
||||
OBJECT poly
|
||||
name "dec_low_on"
|
||||
|
@ -321079,13 +321079,13 @@ refs 2
|
|||
SURF 0X12
|
||||
mat 1
|
||||
refs 2
|
||||
327 0 0
|
||||
328 0 0
|
||||
673 0 0
|
||||
674 0 0
|
||||
SURF 0X12
|
||||
mat 1
|
||||
refs 2
|
||||
673 0 0
|
||||
674 0 0
|
||||
327 0 0
|
||||
328 0 0
|
||||
kids 0
|
||||
OBJECT poly
|
||||
name "pedals_indicator_1"
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 106 KiB After Width: | Height: | Size: 101 KiB |
|
@ -33,13 +33,14 @@ var BrakeSystem =
|
|||
# deceleration caused by brakes alone (knots/s2)
|
||||
m.BrakeDecel = 1.0; # kt/s^2
|
||||
# Higher value means quicker cooling
|
||||
m.CoolingFactor = 0.005;
|
||||
m.CoolingFactor = 0.0005;
|
||||
# Scaling divisor. Use this to scale the energy output.
|
||||
# Manually tune this value: a total energy output
|
||||
# at "/gear/brake-thermal-energy" > 1.0 means overheated brakes,
|
||||
# anything below <= 1.0 means energy absorbed by brakes is OK.
|
||||
#m.ScalingDivisor= 700000*450.0;
|
||||
m.ScalingDivisor = 200000000;
|
||||
|
||||
m.ScalingDivisor = 0.000000007;
|
||||
|
||||
m.LSmokeActive = 0;
|
||||
m.LSmokeToggle = 0;
|
||||
|
@ -72,15 +73,15 @@ var BrakeSystem =
|
|||
#Introducing a random error on the brakes temp sensors
|
||||
if (rand() > 0.5)
|
||||
{
|
||||
setprop("gear/gear[1]/L1error_temp_degc", math.round(rand()*10));
|
||||
setprop("gear/gear[1]/L2error_temp_degc", math.round(rand()*10));
|
||||
setprop("gear/gear[2]/R3error_temp_degc", math.round(rand()*10));
|
||||
setprop("gear/gear[2]/R4error_temp_degc", math.round(rand()*10));
|
||||
setprop("gear/gear[1]/L1error_temp_degc", math.round(rand()*5));
|
||||
setprop("gear/gear[1]/L2error_temp_degc", math.round(rand()*5));
|
||||
setprop("gear/gear[2]/R3error_temp_degc", math.round(rand()*5));
|
||||
setprop("gear/gear[2]/R4error_temp_degc", math.round(rand()*5));
|
||||
} else {
|
||||
setprop("gear/gear[1]/L1error_temp_degc", math.round(rand()*(-10)));
|
||||
setprop("gear/gear[1]/L2error_temp_degc", math.round(rand()*(-10)));
|
||||
setprop("gear/gear[2]/R3error_temp_degc", math.round(rand()*(-10)));
|
||||
setprop("gear/gear[2]/R4error_temp_degc", math.round(rand()*(-10)));
|
||||
setprop("gear/gear[1]/L1error_temp_degc", math.round(rand()*(-5)));
|
||||
setprop("gear/gear[1]/L2error_temp_degc", math.round(rand()*(-5)));
|
||||
setprop("gear/gear[2]/R3error_temp_degc", math.round(rand()*(-5)));
|
||||
setprop("gear/gear[2]/R4error_temp_degc", math.round(rand()*(-5)));
|
||||
}
|
||||
setprop("sim/animation/fire-services",0);
|
||||
me.LastSimTime = 0.0;
|
||||
|
@ -94,12 +95,12 @@ var BrakeSystem =
|
|||
|
||||
if (dt<1.0)
|
||||
{
|
||||
#cooling effect: adjust cooling factor by a value proportional to the environment temp (m.CoolingFactor + environment temp-degf * 0.0001)
|
||||
var CoolingRatio = me.CoolingFactor+(getprop("environment/temperature-degf")*0.0001);
|
||||
#cooling effect: adjust cooling factor by a value proportional to the environment temp (m.CoolingFactor + environment temp-degf * 0.00001)
|
||||
var CoolingRatio = me.CoolingFactor+(getprop("environment/temperature-degf")*0.00001);
|
||||
if (getprop("controls/gear/brake-fans"))
|
||||
{
|
||||
#increase CoolingRatio if Brake Fans are active
|
||||
CoolingRatio = CoolingRatio * 2;
|
||||
CoolingRatio = CoolingRatio * 3;
|
||||
}
|
||||
|
||||
var nCoolFactor = math.ln(1-CoolingRatio);
|
||||
|
@ -108,36 +109,43 @@ var BrakeSystem =
|
|||
var LThermalEnergy = getprop("gear/gear[1]/Lbrake-thermal-energy");
|
||||
var RThermalEnergy = getprop("gear/gear[2]/Rbrake-thermal-energy");
|
||||
|
||||
if (getprop("controls/gear/brake-parking"))
|
||||
{
|
||||
var LBrakeLevel=1.0;
|
||||
var RBrakeLevel=1.0;
|
||||
}
|
||||
else
|
||||
{
|
||||
var LBrakeLevel = getprop("fdm/jsbsim/fcs/left-brake-cmd-norm");
|
||||
var RBrakeLevel = getprop("fdm/jsbsim/fcs/right-brake-cmd-norm");
|
||||
}
|
||||
var LBrakeLevel = getprop("fdm/jsbsim/fcs/left-brake-cmd-norm");
|
||||
var RBrakeLevel = getprop("fdm/jsbsim/fcs/right-brake-cmd-norm");
|
||||
#}
|
||||
var BrakeLevel = (LBrakeLevel + RBrakeLevel)/2;
|
||||
if ((OnGround)and(BrakeLevel>0))
|
||||
{
|
||||
# absorb more energy
|
||||
var V1 = getprop("velocities/groundspeed-kt");
|
||||
var Mass = getprop("fdm/jsbsim/inertia/weight-lbs")/(me.ScalingDivisor);
|
||||
var Mass = getprop("fdm/jsbsim/inertia/weight-lbs")*(me.ScalingDivisor);
|
||||
# absorb some kinetic energy:
|
||||
# dE= 1/2 * m * V1^2 - 1/2 * m * V2^2)
|
||||
var V2_L = V1 - me.BrakeDecel * dt * LBrakeLevel;
|
||||
var V2_R = V1 - me.BrakeDecel * dt * RBrakeLevel;
|
||||
# do not absorb more energy when plane is (almost) stopped
|
||||
# Thermal energy computation
|
||||
if (V2_L>0)
|
||||
{
|
||||
LThermalEnergy += Mass * (V1*V1 - V2_L*V2_L)/2;
|
||||
# cooling effect: reduce thermal energy by (nCoolFactor)^dt
|
||||
LThermalEnergy = LThermalEnergy * math.exp(nCoolFactor * dt);
|
||||
} else {
|
||||
# cooling effect: reduced cooling when speed = 0 and brakes on
|
||||
LThermalEnergy = LThermalEnergy * math.exp(nCoolFactor * 0.3 * dt);
|
||||
}
|
||||
if (V2_R>0)
|
||||
{
|
||||
RThermalEnergy += Mass * (V1*V1 - V2_R*V2_R)/2;
|
||||
# cooling effect: reduce thermal energy by (nCoolFactor)^dt
|
||||
RThermalEnergy = RThermalEnergy * math.exp(nCoolFactor * dt);
|
||||
} else {
|
||||
# cooling effect: reduced cooling when speed = 0 and brakes on
|
||||
RThermalEnergy = RThermalEnergy * math.exp(nCoolFactor * 0.3 * dt);
|
||||
}
|
||||
} else {
|
||||
LThermalEnergy = LThermalEnergy * math.exp(nCoolFactor * dt);
|
||||
RThermalEnergy = RThermalEnergy * math.exp(nCoolFactor * dt);
|
||||
}
|
||||
|
||||
# cooling effect: reduce thermal energy by factor (nCoolFactor)^dt
|
||||
LThermalEnergy = LThermalEnergy * math.exp(nCoolFactor * dt);
|
||||
RThermalEnergy = RThermalEnergy * math.exp(nCoolFactor * dt);
|
||||
|
||||
setprop("gear/gear[1]/Lbrake-thermal-energy",LThermalEnergy);
|
||||
setprop("gear/gear[2]/Rbrake-thermal-energy",RThermalEnergy);
|
||||
|
|
Loading…
Add table
Reference in a new issue