1
0
Fork 0

The switch position was screwed up -- 2 means "hold last frequency",

not "off".
This commit is contained in:
david 2003-02-06 16:17:47 +00:00
parent 2a388d796e
commit fbfb499d49
2 changed files with 3 additions and 1 deletions

View file

@ -212,6 +212,8 @@ void FGDME::search()
freq = navcom2_freq->getDoubleValue();
need_update = true;
}
} else if ( switch_pos == 2 && has_power() ) {
// no-op
} else {
freq = 0;
inrange = false;

View file

@ -93,7 +93,7 @@ public:
// DME Accessors
inline bool has_power() const {
return (switch_pos == 1 || switch_pos == 3)
return (switch_pos > 0)
&& (bus_power->getDoubleValue() > 1.0);
}
inline bool navcom1_on() const {