Skip to main content

G3000 PFD Plugins

Introduction

G3000 PFD plugins allow you to register display panes to the PFD, register custom softkey menus, and render arbitrary components to the main PFD instruments display. PFD plugins must implement the G3000PfdPlugin interface.

For convenience, you may elect to have PFD plugins extend the AbstractG3000PfdPlugin abstract class. This class defines no-op versions of all methods required by the PFD plugin interface. Simply override the methods required for the functionality you wish to add without having to worry about the others.

Importing Libraries

PFD plugins can import and use code from the following framework libraries:

  • @microsoft/msfs-sdk
  • @microsoft/msfs-garminsdk
  • @microsoft/msfs-wtg3000-common
  • @microsoft/msfs-wtg3000-pfd

When building your plugin, you should configure your build tools to consume the above libraries as global externals.

Binder

In addition to the references passed to all G3000 plugins, PFD plugins are given the following additional references through binder:

  • The instrument configuration object specific to the PFD instance.
  • A collection of navigation indicators (used by various PFD components such as the HSI, bearing pointers, etc).
  • The flight plan store.
  • The CAS system.

Display Panes

The G3000 PFD supports two display panes. One pane is reserved for the primary instruments display. The other pane is a controllable pane that is visible as a half-size pane in PFD Split mode. For more information on display panes, please refer to the G3000 Display Panes page.

You can register your own display pane views to be displayed on the PFD using the PFD plugin's registerDisplayPaneViews() method. This method is guaranteed to be called after the base G3000 has registered all of its display pane views. Therefore, you may replace views registered by the base G3000 by registering your own view under the same key.

warning

The PFD half-size display pane does not have the same dimensions as the MFD half-size display panes. The PFD version is slightly larger in both dimensions (508px by 778px vs. 495px by 748px). Keep this in mind when designing panes that can appear on both the PFD and MFD.

tip

Because the primary instruments display is a display pane view, you can replace the default with your own custom version just like with any other view.

Softkey Menus

The G3000 PFD supports a softkey menu bar at the bottom of the display on certain installations. For these installations, you can register your own softkey menus using the PFD plugin's registerSoftkeyMenus() method. This method is guaranteed to be called after the base G3000 has registered all of its menus. Therefore, you may replace menus registered by the base G3000 by registering your own menu under the same key.

More information about the softkey menu API can be found in the Garmin API reference documentation.

PFD Instruments Display

You can render additional components to the PFD's primary instrument display using the PFD plugin's renderToPfdInstruments() method. There are no limits to the number or types of components that can be rendered.

All components will be rendered into the DOM after all base G3000 components. Therefore, these additional components will by default appear on top of any overlapping base G3000 components.

warning

When positioning components within the primary instrument display, remember that the display changes size when switching the PFD between Full to Split modes. Additionally, certain base G3000 components in the display may change their size, visibility, and/or positioning between Full and Split modes.

Weight and Balance Pane

The Weight and Balance pane is available to be displayed when the weight and balance feature is enabled. Certain aspects of the pane can be customized using plugins. Customization is defined using an instance of WeightBalancePaneViewModule returned by the PFD plugin's getWeightBalancePaneViewModule() method. For more information on how to use WeightBalancePaneViewModule to customize the pane, please refer to the G3000 Weight and Balance page.

info

Because the Weight and Balance pane can be displayed on both the PFD and MFD, an instance of WeightBalancePaneViewModule should also be returned by a MFD plugin.

If multiple PFD plugins are loaded, then the return value of getWeightBalancePaneViewModule() is evaluated for each plugin. The plugins are evaluated in reverse loading order (the last-loaded plugin is evaluated first and the first-loaded plugin is evaluated last). If getWeightBalancePaneViewModule() is undefined or returns undefined, then the next plugin is evaluated. If the method returns an instance of WeightBalancePaneViewModule, then evaluation stops and the returned instance is used to customize the Weight and Balance pane. If all plugins have been evaluated and none of them returned an instance of WeightBalancePaneViewModule, then no customization is applied.