01234567890123456789012345678901234567890123456789012345678901234567890123456789
54145415541654175418541954205421542254235424542554265427542854295430543154325433 54345435543654375438543954405441544254435444544554465447544854495450545154525453 | <----SKIPPED LINES----> if messageboard_flight_index is not None: message_queue = [m for m in message_queue if m[0] != FLAG_MSG_INSIGHT] flight_message = CreateMessageAboutFlight(flights[messageboard_flight_index]) message_queue = [(FLAG_MSG_FLIGHT, flight_message)] next_message_time = time.time() elif command == 'histogram': if not flights: Log('Histogram requested by remote %s but no flights in memory' % str(args)) else: histogram_type, histogram_history = args message_queue.extend(MessageboardHistograms( flights, histogram_type, histogram_history, '_1', False)) elif command == 'update_configuration': updated_settings = args[0] configuration.update(updated_settings) if 'setting_screen_enabled' not in updated_settings: configuration.pop('setting_screen_enabled') WriteFile(CONFIG_FILE, configuration) else: Log('Improper command from arduinos: %s / %s' % (command, args)) return message_queue, next_message_time def PublishMessage( s, subscription_id='12fd73cd-75ef-4cae-bbbf-29b2678692c1', key='c5f62d44-e30d-4c43-a43e-d4f65f4eb399', secret='b00aeb24-72f3-467c-aad2-82ba5e5266ca', timeout=3): """Publishes a text string to a Vestaboard. The message is pushed to the vestaboard splitflap display by way of its web services; <----SKIPPED LINES----> |
01234567890123456789012345678901234567890123456789012345678901234567890123456789
54145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454 | <----SKIPPED LINES----> if messageboard_flight_index is not None: message_queue = [m for m in message_queue if m[0] != FLAG_MSG_INSIGHT] flight_message = CreateMessageAboutFlight(flights[messageboard_flight_index]) message_queue = [(FLAG_MSG_FLIGHT, flight_message)] next_message_time = time.time() elif command == 'histogram': if not flights: Log('Histogram requested by remote %s but no flights in memory' % str(args)) else: histogram_type, histogram_history = args message_queue.extend(MessageboardHistograms( flights, histogram_type, histogram_history, '_1', False)) elif command == 'update_configuration': updated_settings = args[0] Log('Updated settings received from arduino: %s' % str(updated_settings)) configuration.update(updated_settings) if 'setting_screen_enabled' not in updated_settings: configuration.pop('setting_screen_enabled') WriteFile(CONFIG_FILE, configuration) else: Log('Improper command from arduinos: %s / %s' % (command, args)) return message_queue, next_message_time def PublishMessage( s, subscription_id='12fd73cd-75ef-4cae-bbbf-29b2678692c1', key='c5f62d44-e30d-4c43-a43e-d4f65f4eb399', secret='b00aeb24-72f3-467c-aad2-82ba5e5266ca', timeout=3): """Publishes a text string to a Vestaboard. The message is pushed to the vestaboard splitflap display by way of its web services; <----SKIPPED LINES----> |