01234567890123456789012345678901234567890123456789012345678901234567890123456789
848849850851852853854855856857858859860861862863864865866867 868869870871872873874875876877878879880881882883884885886887888889 | <----SKIPPED LINES----> if flight: if current_angles: (azimuth, altitude) = current_angles line1 = 'AZM%s' % FloatToAlphanumericStr(azimuth, 1, 6, True) line1_decimal_mask = '00000010' line2 = 'ALT%s' % FloatToAlphanumericStr(altitude, 1, 6, True) line2_decimal_mask = '00000010' else: line1 = KEY_NOT_PRESENT_STRING line2 = KEY_NOT_PRESENT_STRING elif display_mode == DISP_FLIGHT_COUNT_LAST_SEEN: # 18 TODAY / T+ 14H flight_count_today = additional_attr.get('flight_count_today', 0) flight_count_today = ('%2d' % flight_count_today).ljust(3) line1 = '%sTODAY' % flight_count_today elapsed_time_str = 'UNK' if flight_last_seen: elapsed_time_str, partial_dec_mask = SecondsToShortString( GetNow(json_desc_dict, additional_attr) - flight_last_seen) line2 = 'T+ %s' % elapsed_time_str line2_decimal_mask = '000' + partial_dec_mask + '00' elif display_mode == DISP_RADIO_RANGE: # RNG 87MI / 9 PLANES radio_range = json_desc_dict.get('radio_range_miles') radio_range_str = KEY_NOT_PRESENT_STRING if radio_range is not None: radio_range_str = '%2dMI' % round(radio_range) line1 = 'RNG %s' % radio_range_str radio_range_flights = json_desc_dict.get('radio_range_flights', 0) plural = '' if radio_range_flights != 1: plural = 'S' line2 = '%d PLANE%s' % (radio_range_flights, plural) d = {} setting_screen_enabled = False if 'setting_screen_enabled' in configuration: setting_screen_enabled = True d['setting_screen_enabled'] = setting_screen_enabled d['setting_max_distance'] = configuration['setting_max_distance'] <----SKIPPED LINES----> |
01234567890123456789012345678901234567890123456789012345678901234567890123456789
848849850851852853854855856857858859860861862863864865866867868869 870871872873874875876877878879880881882883884885886887888889 | <----SKIPPED LINES----> if flight: if current_angles: (azimuth, altitude) = current_angles line1 = 'AZM%s' % FloatToAlphanumericStr(azimuth, 1, 6, True) line1_decimal_mask = '00000010' line2 = 'ALT%s' % FloatToAlphanumericStr(altitude, 1, 6, True) line2_decimal_mask = '00000010' else: line1 = KEY_NOT_PRESENT_STRING line2 = KEY_NOT_PRESENT_STRING elif display_mode == DISP_FLIGHT_COUNT_LAST_SEEN: # 18 TODAY / T+ 14H flight_count_today = additional_attr.get('flight_count_today', 0) flight_count_today = ('%2d' % flight_count_today).ljust(3) line1 = '%sTODAY' % flight_count_today elapsed_time_str = 'UNK' if flight_last_seen: elapsed_time_str, partial_dec_mask = SecondsToShortString( GetNow(json_desc_dict, additional_attr) - flight_last_seen) line2_decimal_mask = '000' + partial_dec_mask + '00' line2 = 'T+ %s' % elapsed_time_str elif display_mode == DISP_RADIO_RANGE: # RNG 87MI / 9 PLANES radio_range = json_desc_dict.get('radio_range_miles') radio_range_str = KEY_NOT_PRESENT_STRING if radio_range is not None: radio_range_str = '%2dMI' % round(radio_range) line1 = 'RNG %s' % radio_range_str radio_range_flights = json_desc_dict.get('radio_range_flights', 0) plural = '' if radio_range_flights != 1: plural = 'S' line2 = '%d PLANE%s' % (radio_range_flights, plural) d = {} setting_screen_enabled = False if 'setting_screen_enabled' in configuration: setting_screen_enabled = True d['setting_screen_enabled'] = setting_screen_enabled d['setting_max_distance'] = configuration['setting_max_distance'] <----SKIPPED LINES----> |