Changes

Jump to navigation Jump to search
218 bytes added ,  20:09, 1 January 2019
Line 148: Line 148:  
=== Load and start the FG1000 system ===
 
=== Load and start the FG1000 system ===
   −
See FG1000/Nasal/FG1000.nas for full details,
+
A simple FG1000 using the generic EIS, and displaying PFD on device-number 1 and an MFD on device-number 2 is as follows:
including how to pass in the EIS. A simple FG1000 using the generic EIS, and
  −
displaying PFD on device-number 1 and an MFD on device-number 2 is as follows:
      
<syntaxhighlight lang="nasal">
 
<syntaxhighlight lang="nasal">
 
var nasal_dir = getprop("/sim/fg-root") ~ "/Aircraft/Instruments-3d/FG1000/Nasal/";
 
var nasal_dir = getprop("/sim/fg-root") ~ "/Aircraft/Instruments-3d/FG1000/Nasal/";
 
io.load_nasal(nasal_dir ~ 'FG1000.nas', "fg1000");
 
io.load_nasal(nasal_dir ~ 'FG1000.nas', "fg1000");
 +
io.load_nasal(nasal_dir ~ 'Interfaces/GenericInterfaceController.nas', "fg1000");
 +
 +
# Start the interface controller that maps from properties to Emesary messages that are then displayed
 +
var interfaceController = fg1000.GenericInterfaceController.getOrCreateInstance();
 +
interfaceController.start();
    
# Create the FG1000
 
# Create the FG1000

Navigation menu