]> git.mxchange.org Git - flightgear.git/blobdiff - src/Instrumentation/navradio.hxx
Merge branch 'ehofman/rename'
[flightgear.git] / src / Instrumentation / navradio.hxx
index 116a90ce7ef43c553cf526778c18eb787a4e6442..88f67685a1f5b77f348c28d2cdb72a2309bc8d62 100644 (file)
@@ -35,6 +35,7 @@
 // forward decls
 class SGInterpTable;
 
+class SGSampleGroup;
 class FGNavRecord;
 typedef SGSharedPtr<FGNavRecord> FGNavRecordPtr;
 
@@ -66,7 +67,8 @@ class FGNavRadio : public SGSubsystem
     SGPropertyNode_ptr cdi_serviceable_node;
     SGPropertyNode_ptr gs_serviceable_node;
     SGPropertyNode_ptr tofrom_serviceable_node;
-
+    SGPropertyNode_ptr dme_serviceable_node;
+    
     // property outputs
     SGPropertyNode_ptr fmt_freq_node;     // formated frequency
     SGPropertyNode_ptr fmt_alt_freq_node; // formated alternate frequency
@@ -101,6 +103,7 @@ class FGNavRadio : public SGSubsystem
     SGPropertyNode_ptr gs_deflection_norm_node;
     SGPropertyNode_ptr gs_rate_of_climb_node;
     SGPropertyNode_ptr gs_dist_node;
+    SGPropertyNode_ptr gs_inrange_node;
     SGPropertyNode_ptr nav_id_node;
     SGPropertyNode_ptr id_c1_node;
     SGPropertyNode_ptr id_c2_node;
@@ -113,7 +116,10 @@ class FGNavRadio : public SGSubsystem
     SGPropertyNode_ptr gps_to_flag_node;
     SGPropertyNode_ptr gps_from_flag_node;
     SGPropertyNode_ptr gps_has_gs_node;
-
+    SGPropertyNode_ptr gps_course_node;
+    SGPropertyNode_ptr gps_xtrack_error_nm_node;
+    SGPropertyNode_ptr _magvarNode;
+    
     // internal (private) values
 
     int play_count;
@@ -124,7 +130,6 @@ class FGNavRadio : public SGSubsystem
     string nav_fx_name;
     string dme_fx_name;
 
-    bool has_dme;
     double target_radial;
     SGTimeStamp prev_time;
     SGTimeStamp curr_time;
@@ -135,6 +140,7 @@ class FGNavRadio : public SGSubsystem
     double last_x;
     double last_loc_dist;
     double last_xtrack_error;
+    double xrate_ms;
     double _localizerWidth; // cached localizer width in degrees
     
     string _name;
@@ -145,6 +151,9 @@ class FGNavRadio : public SGSubsystem
 
     SGVec3d _gsCart, _gsAxis, _gsVertical;
 
+    FGNavRecordPtr _dme;
+    bool _dmeInRange;
+    
     // CDI properties
     bool _toFlag, _fromFlag;
     double _cdiDeflection;
@@ -152,6 +161,11 @@ class FGNavRadio : public SGSubsystem
     double _gsNeedleDeflection;
     double _gsNeedleDeflectionNorm;
     
+    // realism setting, are false courses and GS lobes enabled?
+    bool _falseCoursesEnabled;
+
+    SGSharedPtr<SGSampleGroup> _sgr;
+    
     bool updateWithPower(double aDt);
 
     // model standard VOR/DME/TACAN service volumes as per AIM 1-1-8
@@ -166,6 +180,7 @@ class FGNavRadio : public SGSubsystem
     void audioNavidChanged();
 
     void updateReceiver(double dt);
+    void updateDME(const SGVec3d& aircraft);
     void updateGlideSlope(double dt, const SGVec3d& aircraft, double signal_quality_norm);
     void updateGPSSlaved();
     void updateCDI(double dt);