Skip to content

Commit

Permalink
Fix flap widget (#88)
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinwidjaja21 authored Dec 8, 2023
1 parent 8dfb218 commit f8dfa08
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 5 deletions.
8 changes: 4 additions & 4 deletions hdw-su95x/src/systems/instruments/src/EWD/PseudoFWC.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1307,10 +1307,10 @@ export class PseudoFWC {

// WARNING these vary for other variants... A320 CFM LEAP values here
// flap/slat internal signals
this.flapsInferiorToPositionA.set(flapsPos.isNormalOperation() && flapsPos.value < 65);
this.flapsSuperiorToPositionF.set(flapsPos.isNormalOperation() && flapsPos.value > 179);
this.slatsInferiorToPositionD.set(slatsPos.isNormalOperation() && slatsPos.value < 210.46);
this.slatsSuperiorToPositionG.set(slatsPos.isNormalOperation() && slatsPos.value > 309.53);
this.flapsInferiorToPositionA.set(flapsPos.isNormalOperation() && flapsPos.value < 119);
this.flapsSuperiorToPositionF.set(flapsPos.isNormalOperation() && flapsPos.value > 169);
this.slatsInferiorToPositionD.set(slatsPos.isNormalOperation() && slatsPos.value < 245.46);
this.slatsSuperiorToPositionG.set(slatsPos.isNormalOperation() && slatsPos.value > 336);

// flap, slat and speedbrake config warning logic
const flapsNotInToPos = this.flapsSuperiorToPositionF.get() || this.flapsInferiorToPositionA.get();
Expand Down
37 changes: 36 additions & 1 deletion hdw-su95x/src/systems/instruments/src/EWD/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,10 @@ animation: pulsingS 1s step-end infinite;
text-anchor: middle !important;
}

&.Pre {
white-space: pre;
}

&.End {
text-anchor: end !important;
}
Expand All @@ -117,7 +121,6 @@ animation: pulsingS 1s step-end infinite;
stroke: $display-grey;
stroke-width: 4;
fill: none;
stroke-linecap: round;
}

.AmberLine {
Expand Down Expand Up @@ -206,6 +209,18 @@ animation: pulsingS 1s step-end infinite;
stroke-width: 2;
}

.WhiteBox {
stroke: $display-white;
fill: none;
stroke-width: 2;
}

.GreenBox {
stroke: $display-green;
fill: none;
stroke-width: 2;
}

.AmberBox {
stroke: $display-amber;
fill: none;
Expand All @@ -215,6 +230,7 @@ animation: pulsingS 1s step-end infinite;
.LightGreyBox {
stroke: none;
fill: $display-grey;
opacity: 0.2
}

.SlatsSmallWhite, .FlapsSmallWhite {
Expand All @@ -223,10 +239,29 @@ animation: pulsingS 1s step-end infinite;
stroke-linejoin: bevel;
}

.DotsSmallWhite {
stroke: none;
fill: $display-white;
}

.SlatsSmallCyan, .FlapsSmallCyan {
stroke: $display-cyan;
stroke-width: 2px;
stroke-linejoin: bevel;
}

.SFInactive {
stroke: $display-white !important;
stroke-width: 2px;
fill: none;
stroke-linejoin: bevel !important;
}

.SFActive {
stroke: $display-green !important;
stroke-width: 2px;
fill: none;
stroke-linejoin: bevel !important;
}

.Slats, .Flaps {
Expand Down

0 comments on commit f8dfa08

Please sign in to comment.