Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(a380x/fma): disconnect ap for ldg message #9606

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

BravoMike99
Copy link
Contributor

@BravoMike99 BravoMike99 commented Nov 29, 2024

Fixes #[issue_no]

Summary of Changes

Adds the "DISCONNECT AP FOR LDG" FMA message on PFD.

Screenshots (if necessary)

image
image

References

Additional context

Discord username (if different from GitHub):
bruno_pt99

Testing instructions

  1. Go to or below 150FT RA with one AP engaged with any of the following modes:
  2. DES, OP DES, V/S or FPA (with 0 or negative value). The DISCONNECT AP FOR LDG message should appear on the PFD.
  3. Fail the 3 RA systems through the EFB and make sure you have a landing airport inserted on the FMS.
  4. Go to an altitude which is less or equal to the destination landing elevation +150FT with any of the modes mentioned in nr2. DISCONNECT AP FOR LDG message should appear once again (this one is easier to test with altimeter setting manipulation rather than having to fly close to the ground 😅 )
  5. Disconnect autopilot after the FMA message is visible and it should disappear.
  6. Fly an ILS approach and let the autopilot Autoland, the message should not appear.

How to download the PR for QA

Every new commit to this PR will cause new A32NX and A380X artifacts to be created, built, and uploaded.

  1. Make sure you are signed in to GitHub
  2. Click on the Checks tab on the PR
  3. On the left side, find and click on the PR Build tab
  4. Click on either flybywire-aircraft-a320-neo, flybywire-aircraft-a380-842 (4K) or flybywire-aircraft-a380-842 (8K) download link at the bottom of the page

@BravoMike99 BravoMike99 added the A380X Related to the A380X aircraft label Nov 29, 2024
Comment on lines +74 to +96
private readonly radioHeightConsumer = ConsumerSubject.create(this.sub.on('chosenRa'), Arinc429Word.empty());

private readonly altitudeConsumer = ConsumerSubject.create(this.sub.on('altitudeAr'), Arinc429Word.empty());

private readonly landingElevation = ConsumerSubject.create(
this.sub.on('landingElevation').whenChanged(),
Arinc429Word.empty(),
);

private readonly ap1Consumer = ConsumerSubject.create(this.sub.on('ap1Active').whenChanged(), false);

private readonly ap2Consumer = ConsumerSubject.create(this.sub.on('ap2Active').whenChanged(), false);

private readonly verticalModeConsumer = ConsumerSubject.create(this.sub.on('activeVerticalMode').whenChanged(), 0);

private readonly selectedVerticalSpeed = ConsumerSubject.create(this.sub.on('apVsSelected').whenChanged(), null);

private readonly selectedFpa = ConsumerSubject.create(this.sub.on('selectedFpa').whenChanged(), null);

private readonly approachCapabilityConsumer = ConsumerSubject.create(
this.sub.on('approachCapability').whenChanged(),
0,
);
Copy link
Member

@tracernz tracernz Dec 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.whenChanged is redundant, and we don't do Hungarian notation (that's the part I request mandatory changes for). I suggest some names like the following (also for additional clarity).

Suggested change
private readonly radioHeightConsumer = ConsumerSubject.create(this.sub.on('chosenRa'), Arinc429Word.empty());
private readonly altitudeConsumer = ConsumerSubject.create(this.sub.on('altitudeAr'), Arinc429Word.empty());
private readonly landingElevation = ConsumerSubject.create(
this.sub.on('landingElevation').whenChanged(),
Arinc429Word.empty(),
);
private readonly ap1Consumer = ConsumerSubject.create(this.sub.on('ap1Active').whenChanged(), false);
private readonly ap2Consumer = ConsumerSubject.create(this.sub.on('ap2Active').whenChanged(), false);
private readonly verticalModeConsumer = ConsumerSubject.create(this.sub.on('activeVerticalMode').whenChanged(), 0);
private readonly selectedVerticalSpeed = ConsumerSubject.create(this.sub.on('apVsSelected').whenChanged(), null);
private readonly selectedFpa = ConsumerSubject.create(this.sub.on('selectedFpa').whenChanged(), null);
private readonly approachCapabilityConsumer = ConsumerSubject.create(
this.sub.on('approachCapability').whenChanged(),
0,
);
private readonly radioHeight = ConsumerSubject.create(this.sub.on('chosenRa'), Arinc429Word.empty());
private readonly altitude = ConsumerSubject.create(this.sub.on('altitudeAr'), Arinc429Word.empty());
private readonly landingElevation = ConsumerSubject.create(
this.sub.on('landingElevation'),
Arinc429Word.empty(),
);
private readonly ap1Active = ConsumerSubject.create(this.sub.on('ap1Active'), false);
private readonly ap2Active = ConsumerSubject.create(this.sub.on('ap2Active'), false);
private readonly activeVerticalMode = ConsumerSubject.create(this.sub.on('activeVerticalMode'), 0);
private readonly selectedVerticalSpeed = ConsumerSubject.create(this.sub.on('apVsSelected'), null);
private readonly selectedFpa = ConsumerSubject.create(this.sub.on('selectedFpa'), null);
private readonly approachCapability = ConsumerSubject.create(
this.sub.on('approachCapability'),
0,
);

@Saschl Saschl self-assigned this Dec 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A380X Related to the A380X aircraft
Projects
Status: 🔴 Code Review: In progress
Development

Successfully merging this pull request may close these issues.

4 participants