def can_operate(cls, available): pilot_flying = all_of(( 'Pilot Flying', 'Landing', ), available) controls = all_of(( 'Pitch (Capt)', 'Pitch (FO)', 'Roll (Capt)', 'Roll (FO)', 'Landing', ), available) forces = all_of(( 'Control Column Force (Capt)', 'Control Column Force (FO)', 'Landing', ), available) autopilot = all_of( ( 'AP (1) Engaged', 'AP (2) Engaged', 'Touchdown', # Optional: 'AP (3) Engaged' ), available) return pilot_flying or controls or forces or autopilot
def can_operate(cls, available): pilot_flying = all_of(( 'Pilot Flying', 'Takeoff', ), available) controls = all_of(( 'Pitch (Capt)', 'Pitch (FO)', 'Roll (Capt)', 'Roll (FO)', 'Takeoff', ), available) forces = all_of(( 'Control Column Force (Capt)', 'Control Column Force (FO)', 'Takeoff', ), available) autopilot = all_of( ( 'AP (1) Engaged', 'AP (2) Engaged', 'Liftoff', # Optional: 'AP (3) Engaged' ), available) return 'AFR Takeoff Pilot' in available or pilot_flying or controls or forces or autopilot
def can_operate(cls, available, ac_type=A('Aircraft Type')): if ac_type and ac_type.value == 'helicopter': return False else: if 'Acceleration Longitudinal' in available: return all_of(('Airspeed', 'Takeoff', 'Acceleration Longitudinal Offset Removed'), available) else: return all_of(('Airspeed', 'Takeoff'), available)
def can_operate(cls, available, manufacturer=A('Manufacturer')): baro_setting_sel = True if manufacturer and manufacturer.value == 'Airbus': baro_setting_sel = any( (any_of(('Baro Setting Selection', 'Baro Correction (ISIS)'), available), all_of(('Baro Setting Selection (Capt)', 'Baro Setting Selection (FO)'), available))) two_baro = all_of(('Baro Correction (Capt)', 'Baro Correction (FO)'), available) return two_baro and baro_setting_sel
def can_operate(cls, available, eng_type=A('Engine Propulsion')): spd_sel = 'Airspeed Selected' in available spd = all_of(('Airspeed', 'Flap Lever Set'), available) jet = (eng_type and eng_type.value == 'JET' and 'Throttle Levers' in available) prop = (eng_type and eng_type.value == 'PROP' and 'Eng (*) Np Max' in available) alt = all_of(('Engine Propulsion', 'Altitude AAL For Flight Phases'), available) return all_of(('Initial Climb', 'Altitude When Climbing'), available) and \ (spd_sel or spd or jet or prop or alt) and \ not (eng_type and eng_type.value == 'ROTOR')
def can_operate(cls, available, eng_type=A('Engine Propulsion'), ac_type=A('Aircraft Type')): if eng_type and eng_type.value == 'PROP': return all_of( ('Takeoff Acceleration Start', 'Liftoff', 'Eng (*) Np Avg', 'Engine Propulsion', 'HDF Duration'), available) elif ac_type == helicopter: return all_of(('Liftoff', 'HDF Duration'), available) else: return all_of(('Takeoff Acceleration Start', 'HDF Duration'), available)
def can_operate(cls, available, ac_type=A('Aircraft Type')): gog_available = any_of(('Gear (L) On Ground', 'Gear (R) On Ground'), available) if gog_available: return True elif all_of(('Vertical Speed', 'Eng (*) Torque Avg'), available): return True else: return False
def can_operate(cls, available): if ('Training Mode' in available) and \ not(any_of(('Eng (1) Training Mode', 'Eng (2) Training Mode'), available)): return True elif all_of(('Eng (1) Training Mode', 'Eng (2) Training Mode'), available) and \ ('Training Mode' not in available) : return True else: return False
def can_operate(cls, available): controls = library.all_of(( 'Pitch (Capt)', 'Pitch (FO)', 'Roll (Capt)', 'Roll (FO)', 'Landing', ), available) autopilot = library.all_of(( 'AP (1) Engaged', 'AP (2) Engaged', 'Touchdown', # Optional: 'AP (3) Engaged' ), available) key_vhf = library.all_of(('Key VHF (1)', 'Key VHF (2)', 'Landing'), available) return controls or autopilot or key_vhf
def can_operate(cls, available, ac_type=A('Aircraft Type')): required = ['Approach And Landing'] required.append('Altitude AGL' if ac_type == helicopter else 'Altitude AAL') # Force both Latitude and Longitude to be available if one is available if 'Latitude Prepared' in available and not 'Longitude Prepared' in available: return False elif 'Longitude Prepared' in available and not 'Latitude Prepared' in available: return False return all_of(required, available)
def can_operate(cls, available): pilot_flying = all_of(( 'Pilot Flying', 'Landing', ), available) controls = all_of(( 'Pitch (Capt)', 'Pitch (FO)', 'Roll (Capt)', 'Roll (FO)', 'Landing', ), available) autopilot = all_of(( 'AP (1) Engaged', 'AP (2) Engaged', 'Touchdown', # Optional: 'AP (3) Engaged' ), available) return pilot_flying or controls or autopilot
def can_operate(cls, available): pilot_flying = all_of(( 'Pilot Flying', 'Takeoff', ), available) controls = all_of(( 'Pitch (Capt)', 'Pitch (FO)', 'Roll (Capt)', 'Roll (FO)', 'Takeoff', ), available) autopilot = all_of(( 'AP (1) Engaged', 'AP (2) Engaged', 'Liftoff', # Optional: 'AP (3) Engaged' ), available) return pilot_flying or controls or autopilot
def can_operate(cls, available, seg_type=A('Segment Type')): req = all_of(('Acceleration Longitudinal Offset Removed', 'Eng (*) All Running', 'Grounded', 'Segment Type'), available) if seg_type and seg_type.value == 'START_AND_STOP': return req and 'Takeoff Runway Heading' in available elif seg_type and seg_type.value == 'GROUND_ONLY': return req else: return False
def can_operate(cls, available, ac_type=A('Aircraft Type'), seg_type=A('Segment Type')): if seg_type and seg_type.value in ('GROUND_ONLY', 'NO_MOVEMENT', 'STOP_ONLY'): return False else: return all_of( ('Heading Continuous', 'Altitude AAL For Flight Phases', 'Fast', 'Airborne'), available)
def can_operate(cls, available, ac_type=A('Aircraft Type'), seg_type=A('Segment Type')): if seg_type and seg_type.value in ('GROUND_ONLY', 'NO_MOVEMENT'): return False elif ac_type == helicopter: return all_of(('Altitude AGL', 'Collective', 'Airborne'), available) else: return 'Altitude AAL For Flight Phases' in available
def can_operate(cls, available, ac_type=A('Aircraft Type'), seg_type=A('Segment Type')): if seg_type and seg_type.value in ('GROUND_ONLY', 'NO_MOVEMENT', 'START_ONLY'): return False elif ac_type == helicopter: return all_of(('Approach', 'Landing'), available) else: return 'Altitude AAL For Flight Phases' in available
def can_operate(cls, available): pilot_flying = all_of(( 'Pilot Flying', 'Takeoff', ), available) controls = all_of(( 'Pitch (Capt)', 'Pitch (FO)', 'Roll (Capt)', 'Roll (FO)', 'Takeoff', ), available) autopilot = all_of(( 'AP (1) Engaged', 'AP (2) Engaged', 'Liftoff', # Optional: 'AP (3) Engaged' ), available) key_vhf = all_of(('Key VHF (1)', 'Key VHF (2)', 'Takeoff'), available) return pilot_flying or controls or autopilot or key_vhf
def can_operate(cls, available, ac_type=A('Aircraft Type'), seg_type=A('Segment Type')): if seg_type and seg_type.value == 'GROUND_ONLY': return False required = ['Approach And Landing', 'Takeoff', 'Touchdown'] required.append('Altitude AGL' if ac_type == helicopter else 'Altitude AAL') lat = 'Latitude Prepared' in available lon = 'Longitude Prepared' in available # Force both Latitude and Longitude to be available if one is available if lat != lon: return False return all_of(required, available)
def can_operate(cls, available, ac_type=A('Aircraft Type'), seg_type=A('Segment Type')): if 'Acceleration Longitudinal' in available and \ 'Acceleration Longitudinal Offset Removed' not in available: return False if ac_type and ac_type.value == 'helicopter': return 'Airborne' in available elif seg_type and seg_type.value in ('GROUND_ONLY', 'NO_MOVEMENT', 'MID_FLIGHT', 'START_ONLY'): return False else: return all_of(('Altitude AAL', 'Landing'), available)
def can_operate(cls, available): pilot_flying = all_of(( 'Pilot Flying', 'Takeoff', ), available) controls = all_of(( 'Pitch (Capt)', 'Pitch (FO)', 'Roll (Capt)', 'Roll (FO)', 'Takeoff', ), available) forces = all_of(( 'Control Column Force (Capt)', 'Control Column Force (FO)', 'Takeoff', ), available) autopilot = all_of(( 'AP (1) Engaged', 'AP (2) Engaged', 'Liftoff', # Optional: 'AP (3) Engaged' ), available) return pilot_flying or controls or forces or autopilot
def can_operate(cls, available, ac_type=A('Aircraft Type')): if ac_type == helicopter: return all_of(('Airborne', 'Takeoff 5 Min Rating'), available) else: return all_deps(cls, available)
def can_operate(cls, available, ac_type=A('Aircraft Type')): if ac_type == helicopter: return all_of(('Airborne', 'Airspeed'), available) else: return 'HDF Duration' in available
def can_operate(cls, available, ac_type=A('Aircraft Type')): required = ['Approach And Landing', 'Fast'] required.append('Altitude AGL' if ac_type == helicopter else 'Altitude AAL') return all_of(required, available)
def can_operate(cls, available, ac_type=A('Aircraft Type')): if ac_type == helicopter: return all_of(('Altitude Radio', 'Altitude STD Smoothed', 'Gear On Ground'), available) or \ ('Altitude Radio' not in available and 'Altitude AAL' in available) else: return False
def can_operate(cls, available, ac_type=A('Aircraft Type')): return ac_type == aeroplane and \ all_of(('Altitude AAL For Flight Phases', 'Airborne'), available)
def can_operate(cls, available, seg_type=A('Segment Type')): default = all_of(('Mobile', 'Takeoff', 'Landing', 'Airborne'), available) ground_only = seg_type and seg_type.value == 'GROUND_ONLY' and \ 'Mobile' in available return default or ground_only
def can_operate(cls, available, seg_type=A('Segment Type')): if seg_type and seg_type.value in ('GROUND_ONLY', 'NO_MOVEMENT'): return False return all_of(('Gear On Ground', ), available)
def can_operate(cls, available, ac_type=A('Aircraft Type')): helicopter_with_grounded = ac_type == helicopter and 'Grounded' in available required_deps = all_of( ('Pitch', 'Roll'), available) or 'Offshore' in available return helicopter_with_grounded and required_deps
def can_operate(cls, available, seg_type=A('Segment Type')): if seg_type and seg_type.value in ('GROUND_ONLY', 'NO_MOVEMENT'): return False return all_of(('Gear On Ground',), available)
def can_operate(cls, available, eng_type=A('Engine Propulsion')): if eng_type and eng_type.value == 'PROP': return all_of(('Go Around', 'Eng (*) Np Avg', 'HDF Duration', 'Engine Propulsion'), available) else: return all_of(('Go Around', 'HDF Duration'), available)
def can_operate(cls, available, family=A('Family')): return family and family.value == 'H175' and all_of(('Pitch', 'Initial Climb'), available)
def can_operate(cls, available): return all_of(('Takeoff', 'Takeoff Acceleration Start'), available)
def can_operate(cls, available, seg_type=A('Segment Type')): if seg_type and seg_type.value in ('GROUND_ONLY', 'NO_MOVEMENT', 'STOP_ONLY'): return False else: return all_of(('Altitude AGL', 'Liftoff'), available)
def can_operate(cls, available, ac_type=A('Aircraft Type')): return ac_type == helicopter and \ all_of(('Altitude AGL', 'Airborne', 'Hover'), available)
def can_operate(cls, available): return all_of(('Mobile', 'Takeoff'), available)
def can_operate(cls, available): return all_of(('TCAS Combined Control', 'TCAS Operational'), available) or \ all_of(('TCAS RA', 'TCAS Operational'), available)