]> git.mxchange.org Git - flightgear.git/blob - src/Instrumentation/airspeed_indicator.hxx
Roy Vegard Ovesen:
[flightgear.git] / src / Instrumentation / airspeed_indicator.hxx
1 // airspeed_indicator.hxx - a regular VSI tied to the static port.
2 // Written by David Megginson, started 2002.
3 //
4 // This file is in the Public Domain and comes with no warranty.
5
6
7 #ifndef __INSTRUMENTS_AIRSPEED_INDICATOR_HXX
8 #define __INSTRUMENTS_AIRSPEED_INDICATOR_HXX 1
9
10 #ifndef __cplusplus
11 # error This library requires C++
12 #endif
13
14 #include <simgear/props/props.hxx>
15 #include <simgear/structure/subsystem_mgr.hxx>
16
17
18 /**
19  * Model an airspeed indicator tied to the pitot and static ports.
20  *
21  * Input properties:
22  *
23  * /instrumentation/"name"/serviceable
24  * "pitot_port"/total-pressure-inhg
25  * "static_port"/pressure-inhg
26  * /environment/density-slugft3
27  *
28  * Output properties:
29  *
30  * /instrumentation/"name"/indicated-speed-kt
31  */
32 class AirspeedIndicator : public SGSubsystem
33 {
34
35 public:
36
37     AirspeedIndicator ( SGPropertyNode *node );
38     AirspeedIndicator ( int i);
39     virtual ~AirspeedIndicator ();
40
41     virtual void init ();
42     virtual void update (double dt);
43
44 private:
45
46     string name;
47     int num;
48     string pitot_port;
49     string static_port;
50     SGPropertyNode_ptr _serviceable_node;
51     SGPropertyNode_ptr _total_pressure_node;
52     SGPropertyNode_ptr _static_pressure_node;
53     SGPropertyNode_ptr _density_node;
54     SGPropertyNode_ptr _speed_node;
55     
56 };
57
58 #endif // __INSTRUMENTS_AIRSPEED_INDICATOR_HXX