Ignore:
Timestamp:
04/03/22 14:32:40 (2 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
python3
Phase:
public
Message:

Unreadable N1 values are handled better (re #359)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/checks.py

    r919 r1043  
    977977        be on."""
    978978        if state.n1 is not None:
    979             return max(state.n1)>5
     979            for n1 in state.n1:
     980                if n1 is not None and n1>5:
     981                    return True
     982            return False
    980983        elif state.rpm is not None:
    981984            return max(state.rpm)>0
     
    15901593    def isCondition(self, flight, aircraft, oldState, state):
    15911594        """Check if the fault condition holds."""
    1592         return flight.stage==const.STAGE_TAKEOFF and \
    1593                state.n1 is not None and max(state.n1)>97
     1595        if flight.stage==const.STAGE_TAKEOFF and state.n1 is not None:
     1596            for n1 in state.n1:
     1597                if n1 is not None and n1>97:
     1598                    return True
     1599        return False
    15941600
    15951601    def logFault(self, flight, aircraft, logger, oldState, state):
Note: See TracChangeset for help on using the changeset viewer.