X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FInstrumentation%2Fadf.hxx;h=2ac32fa9d10effff6a818382c77806c225e7e854;hb=68c71d5787f2a0309e35c3e05939950113618cb7;hp=fa17234f23a9342792c98ca1553e6da3f411adc9;hpb=3c764462e6bb3523159716953ccf81c0b7d3d47a;p=flightgear.git diff --git a/src/Instrumentation/adf.hxx b/src/Instrumentation/adf.hxx index fa17234f2..2ac32fa9d 100644 --- a/src/Instrumentation/adf.hxx +++ b/src/Instrumentation/adf.hxx @@ -13,13 +13,12 @@ #include -#include #include #include +#include -SG_USING_STD(string); - +class SGSampleGroup; /** * Model an ADF radio. @@ -35,6 +34,8 @@ SG_USING_STD(string); * /instrumentation/adf/error-deg * /instrumentation/adf/frequencies/selected-khz * /instrumentation/adf/mode + * /instrumentation/adf/ident-audible + * /instrumentation/adf/volume-norm * * Output properties: * @@ -47,7 +48,7 @@ class ADF : public SGSubsystem public: - ADF (); + ADF ( SGPropertyNode *node ); virtual ~ADF (); virtual void init (); @@ -57,12 +58,11 @@ private: void set_bearing (double delta_time_sec, double bearing); - void search (double frequency, double longitude_rad, - double latitude_rad, double altitude_m); + void search (double frequency, const SGGeod& pos); + + std::string _name; + unsigned int _num; - SGPropertyNode_ptr _longitude_node; - SGPropertyNode_ptr _latitude_node; - SGPropertyNode_ptr _altitude_node; SGPropertyNode_ptr _heading_node; SGPropertyNode_ptr _serviceable_node; SGPropertyNode_ptr _error_node; @@ -73,18 +73,26 @@ private: SGPropertyNode_ptr _in_range_node; SGPropertyNode_ptr _bearing_node; SGPropertyNode_ptr _ident_node; + SGPropertyNode_ptr _ident_audible_node; + SGPropertyNode_ptr _volume_node; + SGPropertyNode_ptr _power_btn_node; + SGPropertyNode_ptr _operable_node; double _time_before_search_sec; int _last_frequency_khz; bool _transmitter_valid; - string _last_ident; - Point3D _transmitter; - double _transmitter_lon_deg; - double _transmitter_lat_deg; - double _transmitter_elevation_ft; + std::string _last_ident; + SGGeod _transmitter_pos; + SGVec3d _transmitter_cart; double _transmitter_range_nm; + int _ident_count; + time_t _last_ident_time; + float _last_volume; + std::string _adf_ident; + + SGSharedPtr _sgr; };